content
large_stringlengths
0
6.46M
path
large_stringlengths
3
331
license_type
large_stringclasses
2 values
repo_name
large_stringlengths
5
125
language
large_stringclasses
1 value
is_vendor
bool
2 classes
is_generated
bool
2 classes
length_bytes
int64
4
6.46M
extension
large_stringclasses
75 values
text
stringlengths
0
6.46M
library(NLP) library(tm) library(stats) library(proxy) library(dplyr) library(readtext) library(jiebaRD) library(jiebaR) library(slam) library(Matrix) library(tidytext) rawData = readtext("*.txt") docs = Corpus(VectorSource(rawData$text)) # data clean toSpace <- content_transformer(function(x, pattern) { return (gsu...
/week_5/practice_week5/practice_week5.R
no_license
yitingpeng/datascience
R
false
false
3,048
r
library(NLP) library(tm) library(stats) library(proxy) library(dplyr) library(readtext) library(jiebaRD) library(jiebaR) library(slam) library(Matrix) library(tidytext) rawData = readtext("*.txt") docs = Corpus(VectorSource(rawData$text)) # data clean toSpace <- content_transformer(function(x, pattern) { return (gsu...
test_that("mdepriv: argument rhoH", { expect_equal( mdepriv(simul_data, c("y1", "y2"), method = "bv"), mdepriv(simul_data, c("y1", "y2"), method = "bv", rhoH = NULL) ) expect_equal( mdepriv(simul_data, c("y1", "y2"), method = "bv"), mdepriv(simul_data, c("y1", "y2"), method = "bv", rhoH = NA) )...
/tests/testthat/test-mdepriv_rhoH.R
no_license
a-benini/mdepriv
R
false
false
1,034
r
test_that("mdepriv: argument rhoH", { expect_equal( mdepriv(simul_data, c("y1", "y2"), method = "bv"), mdepriv(simul_data, c("y1", "y2"), method = "bv", rhoH = NULL) ) expect_equal( mdepriv(simul_data, c("y1", "y2"), method = "bv"), mdepriv(simul_data, c("y1", "y2"), method = "bv", rhoH = NA) )...
#' calc_footprint generates upstream influence footprint #' @author Ben Fasoli #' #' Aggregates the upstream particle trajectories into a time integrated #' footprint, expanding particle influence using variable 2d gaussian kernels #' with bandwidths proportional to the mean pairwise distance between all #' particles a...
/r/src/calc_trajectory.r
no_license
ddlddl58/stilt
R
false
false
6,045
r
#' calc_footprint generates upstream influence footprint #' @author Ben Fasoli #' #' Aggregates the upstream particle trajectories into a time integrated #' footprint, expanding particle influence using variable 2d gaussian kernels #' with bandwidths proportional to the mean pairwise distance between all #' particles a...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/utils.R \name{std_colnames} \alias{std_colnames} \title{Standardize column names to contain only low-case alphanumeric chars.} \usage{ std_colnames(names) } \arguments{ \item{names}{A vector of column names} } \value{ A vector of standardized...
/man/std_colnames.Rd
no_license
slonik-az/LRutil
R
false
true
508
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/utils.R \name{std_colnames} \alias{std_colnames} \title{Standardize column names to contain only low-case alphanumeric chars.} \usage{ std_colnames(names) } \arguments{ \item{names}{A vector of column names} } \value{ A vector of standardized...
% Generated by roxygen2 (4.1.1): do not edit by hand % Please edit documentation in R/make.R \name{make_full_citation_graph} \alias{full_citation_graph} \alias{graph.full.citation} \alias{make_full_citation_graph} \title{Create a complete (full) citation graph} \usage{ make_full_citation_graph(n, directed = TRUE) full...
/man/make_full_citation_graph.Rd
no_license
davidmaciel/rigraph
R
false
false
1,952
rd
% Generated by roxygen2 (4.1.1): do not edit by hand % Please edit documentation in R/make.R \name{make_full_citation_graph} \alias{full_citation_graph} \alias{graph.full.citation} \alias{make_full_citation_graph} \title{Create a complete (full) citation graph} \usage{ make_full_citation_graph(n, directed = TRUE) full...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/Yman2016.R \name{Yman2016} \alias{Yman2016} \title{Antibody acquisition models} \usage{ Yman2016(logAb, Age, type = "constant", print = TRUE) } \arguments{ \item{logAb}{Log antibody level (numeric)} \item{Age}{Age of the individual at the ti...
/man/Yman2016.Rd
no_license
ben-arnold/tmleAb
R
false
true
2,734
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/Yman2016.R \name{Yman2016} \alias{Yman2016} \title{Antibody acquisition models} \usage{ Yman2016(logAb, Age, type = "constant", print = TRUE) } \arguments{ \item{logAb}{Log antibody level (numeric)} \item{Age}{Age of the individual at the ti...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/lib_other.R \name{loc} \alias{loc} \title{shortcut for list_code_file and count_lines_of_code that defaults to including comments and excluding blanks} \usage{ loc(path) } \arguments{ \item{path}{root path of a project} } \value{ integer line...
/man/loc.Rd
permissive
jorritvm/jrutils
R
false
true
457
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/lib_other.R \name{loc} \alias{loc} \title{shortcut for list_code_file and count_lines_of_code that defaults to including comments and excluding blanks} \usage{ loc(path) } \arguments{ \item{path}{root path of a project} } \value{ integer line...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/get_playlist_tracks.R \name{get_playlist_tracks} \alias{get_playlist_tracks} \title{Get tracks from one or more playlists} \usage{ get_playlist_tracks(playlists, access_token = get_spotify_access_token()) } \arguments{ \item{playlists}{Datafr...
/man/get_playlist_tracks.Rd
no_license
yasinkutuk/spotifyr
R
false
true
854
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/get_playlist_tracks.R \name{get_playlist_tracks} \alias{get_playlist_tracks} \title{Get tracks from one or more playlists} \usage{ get_playlist_tracks(playlists, access_token = get_spotify_access_token()) } \arguments{ \item{playlists}{Datafr...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/Eq.r \docType{data} \name{geomtimeline} \alias{geomtimeline} \title{Geom for plotting timeline of earthquake data} \format{An object of class \code{geomtimeline} (inherits from \code{Geom}, \code{ggproto}) of length 6.} \usage{ geomtimeline }...
/man/geomtimeline.Rd
no_license
drsmd23/Eq
R
false
true
1,849
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/Eq.r \docType{data} \name{geomtimeline} \alias{geomtimeline} \title{Geom for plotting timeline of earthquake data} \format{An object of class \code{geomtimeline} (inherits from \code{Geom}, \code{ggproto}) of length 6.} \usage{ geomtimeline }...
# Project: GEOdb # # Author: Renaud Gaujoux # Created: Feb 25, 2014 ############################################################################### #' @include utils.R #' @include download.R #' @include url.R NULL .biocinstallRepos <- function(siteRepos = NULL, lib = NULL){ if( !requireNamespace('BiocInstaller',...
/R/api.R
no_license
renozao/repotools
R
false
false
37,886
r
# Project: GEOdb # # Author: Renaud Gaujoux # Created: Feb 25, 2014 ############################################################################### #' @include utils.R #' @include download.R #' @include url.R NULL .biocinstallRepos <- function(siteRepos = NULL, lib = NULL){ if( !requireNamespace('BiocInstaller',...
#' --- #' title: "EDB and interrupted time series models" #' author: "Andrew Heiss" #' date: "`r format(Sys.time(), '%B %e, %Y')`" #' output: #' html_document: #' css: html/fixes.css #' code_folding: hide #' toc: yes #' toc_float: true #' toc_depth: 4 #' highlight: pygments #' self_conta...
/Analysis/interrupted_time_series.R
no_license
sainiudit/global_assessment_power
R
false
false
79,020
r
#' --- #' title: "EDB and interrupted time series models" #' author: "Andrew Heiss" #' date: "`r format(Sys.time(), '%B %e, %Y')`" #' output: #' html_document: #' css: html/fixes.css #' code_folding: hide #' toc: yes #' toc_float: true #' toc_depth: 4 #' highlight: pygments #' self_conta...
#Aggregate climate data, only including months with mean min temperature > 0 #Output mean, sd, and instability of ppt and temperature by state and decade library(tidyverse) library(patchwork) library(usmap) #Load prepared input files: these are monthly average PRISM data that have been weighted by harvested area at t...
/Climate and irrigation aggregation/final_climate_aggregation.R
no_license
averydriscoll/Stability_Crop_Diversity
R
false
false
3,502
r
#Aggregate climate data, only including months with mean min temperature > 0 #Output mean, sd, and instability of ppt and temperature by state and decade library(tidyverse) library(patchwork) library(usmap) #Load prepared input files: these are monthly average PRISM data that have been weighted by harvested area at t...
/Analiza kursu dolara w złotówkach 2019-2020 z językiem R.R
no_license
PiotrDataSceince/Kod
R
false
false
3,345
r
\name{read.cmtkreg} \alias{read.cmtkreg} \title{Read a CMTK format registration} \usage{ read.cmtkreg(filename, ReturnRegistrationOnly = FALSE, ...) } \arguments{ \item{filename}{Path to a CMTK registration file} \item{ReturnRegistrationOnly}{When FALSE (default) will not attempt to extract the registration elem...
/man/read.cmtkreg.Rd
no_license
mmc46/nat
R
false
false
666
rd
\name{read.cmtkreg} \alias{read.cmtkreg} \title{Read a CMTK format registration} \usage{ read.cmtkreg(filename, ReturnRegistrationOnly = FALSE, ...) } \arguments{ \item{filename}{Path to a CMTK registration file} \item{ReturnRegistrationOnly}{When FALSE (default) will not attempt to extract the registration elem...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/permute.R \name{permu_test_mean} \alias{permu_test_mean} \title{Test for the difference in means within groups} \usage{ permu_test_mean(strata, prediction, treatment, response, iters = 1000, shift = 0) } \arguments{ \item{strata}{List outpu...
/ModelMatch/man/permu_test_mean.Rd
no_license
kellieotto/ModelMatch
R
false
true
961
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/permute.R \name{permu_test_mean} \alias{permu_test_mean} \title{Test for the difference in means within groups} \usage{ permu_test_mean(strata, prediction, treatment, response, iters = 1000, shift = 0) } \arguments{ \item{strata}{List outpu...
\name{snow integration} \alias{snow integration} \alias{parallel integration} \title{ bnlearn - snow/parallel package integration } \description{ How to use the \pkg{bnlearn} package with the parallel computing environment provided by the \pkg{snow} or \pkg{parallel} packages. } \section{Parallel computing fo...
/man/snow.Rd
no_license
gasse/bnlearn-clone-3.4
R
false
false
1,364
rd
\name{snow integration} \alias{snow integration} \alias{parallel integration} \title{ bnlearn - snow/parallel package integration } \description{ How to use the \pkg{bnlearn} package with the parallel computing environment provided by the \pkg{snow} or \pkg{parallel} packages. } \section{Parallel computing fo...
# R codes to nowcast 2010 Q1 to 2021 Q1 in a more streamlined manner # Packages required library(tidyverse);library(DMwR);library(jsonlite);library(tempdisagg);library(tsbox) library(tsoutliers);library(forecast);library(nowcasting);library(imputeTS) options(scipen=999) yoy_d4 <- function(x){ (x-lag(x,4))/l...
/gdpnowcast_2010Q1-2021Q1.R
no_license
cheongweisi/Nowcasting-SG-GDP-Medium-
R
false
false
24,726
r
# R codes to nowcast 2010 Q1 to 2021 Q1 in a more streamlined manner # Packages required library(tidyverse);library(DMwR);library(jsonlite);library(tempdisagg);library(tsbox) library(tsoutliers);library(forecast);library(nowcasting);library(imputeTS) options(scipen=999) yoy_d4 <- function(x){ (x-lag(x,4))/l...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/body.R \name{mj_text} \alias{mj_text} \title{Text} \usage{ mj_text(...) } \arguments{ \item{...}{Unnamed items that comprise this list of MJML tags.} } \description{ This tag allows you to display text in your email. } \examples{ mj_ml( mj_...
/man/mj_text.Rd
no_license
jimsforks/mjml
R
false
true
605
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/body.R \name{mj_text} \alias{mj_text} \title{Text} \usage{ mj_text(...) } \arguments{ \item{...}{Unnamed items that comprise this list of MJML tags.} } \description{ This tag allows you to display text in your email. } \examples{ mj_ml( mj_...
plot3 <- function() { plot.data <- read.table("household_power_consumption.txt",header=TRUE,sep=";",na.strings="?",colClasses=c("character","character","numeric","numeric","numeric","numeric","numeric","numeric","numeric")) plot.data[,1]<-as.Date(plot.data[,1],format='%d/%m/%Y') sub.data<-subset(plot.data,plot.dat...
/plot3.R
no_license
CourseWorkH/ExData_Plotting1
R
false
false
828
r
plot3 <- function() { plot.data <- read.table("household_power_consumption.txt",header=TRUE,sep=";",na.strings="?",colClasses=c("character","character","numeric","numeric","numeric","numeric","numeric","numeric","numeric")) plot.data[,1]<-as.Date(plot.data[,1],format='%d/%m/%Y') sub.data<-subset(plot.data,plot.dat...
for(k in 1:2){ library(testthat) library("GrowingNeuralGas") library(igraph) max_nodes <- 600 # Construct gng object gng <- GNG(dataset_type=gng.dataset.bagging.prob, max_nodes=max_nodes, dim=3, uniformgrid_optimization=FALSE, lazyheap_optimization=FALSE ) ...
/tests/testthat/test_gng_basic.R
no_license
Habeebah2013/Growing-Neural-Gas
R
false
false
1,732
r
for(k in 1:2){ library(testthat) library("GrowingNeuralGas") library(igraph) max_nodes <- 600 # Construct gng object gng <- GNG(dataset_type=gng.dataset.bagging.prob, max_nodes=max_nodes, dim=3, uniformgrid_optimization=FALSE, lazyheap_optimization=FALSE ) ...
testlist <- list(m = NULL, repetitions = 0L, in_m = structure(c(2.32784383492509e-308, 9.53818252170339e+295, 1.22810536108214e+146, 4.12396251261199e-221, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), .Dim = c(5L, 7L))) result <- do.call(CNull:::communities_individual...
/CNull/inst/testfiles/communities_individual_based_sampling_beta/AFL_communities_individual_based_sampling_beta/communities_individual_based_sampling_beta_valgrind_files/1615832627-test.R
no_license
akhikolla/updatedatatype-list2
R
false
false
362
r
testlist <- list(m = NULL, repetitions = 0L, in_m = structure(c(2.32784383492509e-308, 9.53818252170339e+295, 1.22810536108214e+146, 4.12396251261199e-221, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), .Dim = c(5L, 7L))) result <- do.call(CNull:::communities_individual...
#install Library library(rpart) library(randomForest) library(dplyr) library(ggplot2) library(funModeling) library(caret) library(corrplot) library(tree) library(caTools) library(devtools) library(car) library(modelr) #import the data and give the full input path house_data <-read.csv("C:\\Users\\aashi...
/Project_House_data.R
no_license
ashishmakhani/House-Price-Prediction-using-R
R
false
false
9,077
r
#install Library library(rpart) library(randomForest) library(dplyr) library(ggplot2) library(funModeling) library(caret) library(corrplot) library(tree) library(caTools) library(devtools) library(car) library(modelr) #import the data and give the full input path house_data <-read.csv("C:\\Users\\aashi...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/potential_univariate.R \name{potential_univariate} \alias{potential_univariate} \title{Potential Analysis for Univariate Data} \usage{ potential_univariate(x, std = 1, bw = "nrd", weights = c(), grid.size = NULL, detection.threshold = 1, bw...
/man/potential_univariate.Rd
permissive
digideskio/microbiome
R
false
true
2,843
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/potential_univariate.R \name{potential_univariate} \alias{potential_univariate} \title{Potential Analysis for Univariate Data} \usage{ potential_univariate(x, std = 1, bw = "nrd", weights = c(), grid.size = NULL, detection.threshold = 1, bw...
auto <- function(X) { ndim <- dim(X) m = ndim[1] meanx <- apply(X,2,mean) stdx <- apply(X,2,std) ONE <- matrix(1,m,1) ax <- (X - (ONE %*% meanx))/(ONE %*% stdx) return(ax) }
/Toolbox/scalings/auto.r
no_license
riviar/meat_adulteration_analysis
R
false
false
192
r
auto <- function(X) { ndim <- dim(X) m = ndim[1] meanx <- apply(X,2,mean) stdx <- apply(X,2,std) ONE <- matrix(1,m,1) ax <- (X - (ONE %*% meanx))/(ONE %*% stdx) return(ax) }
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/packages2.R \name{get_packages2} \alias{get_packages2} \title{Packages} \usage{ get_packages2(universe) } \arguments{ \item{universe}{universe to query} } \value{ A character vector. } \description{ Packages } \examples{ \dontrun{ get_package...
/man/get_packages2.Rd
permissive
sfr/applepie
R
false
true
339
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/packages2.R \name{get_packages2} \alias{get_packages2} \title{Packages} \usage{ get_packages2(universe) } \arguments{ \item{universe}{universe to query} } \value{ A character vector. } \description{ Packages } \examples{ \dontrun{ get_package...
library("tidyverse") setwd("~/github/practice-py/hamazaki1990/") freq_wf <- read_csv("allelefreqwf.csv") %>% dplyr::mutate(model = "wf") freq_wf freq_mo <- read_csv("allelefreqmo.csv") %>% dplyr::mutate(model = "moran") freq_mo freq <- dplyr::bind_rows(freq_wf, freq_mo) print(freq) freqplot <- ggplot(freq, aes(...
/hamazaki1990/visualize.r
permissive
hamazaki1990/practice-py
R
false
false
439
r
library("tidyverse") setwd("~/github/practice-py/hamazaki1990/") freq_wf <- read_csv("allelefreqwf.csv") %>% dplyr::mutate(model = "wf") freq_wf freq_mo <- read_csv("allelefreqmo.csv") %>% dplyr::mutate(model = "moran") freq_mo freq <- dplyr::bind_rows(freq_wf, freq_mo) print(freq) freqplot <- ggplot(freq, aes(...
names(data_study1) if(TRUE){#deal with the data round2 data_study1_round2<-read.csv("data_study1_round2.csv",stringsAsFactors = F) names(data_study1_round2) data_study1_round2<-data_study1_round2[c(1,10,12,13, 14:20,22:28,30:32,#knowledge ...
/study1_round2.R
no_license
zigner-song/my_study_OD
R
false
false
1,763
r
names(data_study1) if(TRUE){#deal with the data round2 data_study1_round2<-read.csv("data_study1_round2.csv",stringsAsFactors = F) names(data_study1_round2) data_study1_round2<-data_study1_round2[c(1,10,12,13, 14:20,22:28,30:32,#knowledge ...
####Conert graph file with selected genes to gene symbols or directly to top pathways?### source("http://bioconductor.org/biocLite.R") biocLite("clusterProfiler") library(clusterProfiler) graph = "C:/Users/vinee_000/Desktop/Gene-Selection/Interpretability_Results/GSE1456_WP/graph.txt" data = read.table(graph,sep="...
/source/convertSymbols.R
no_license
vineet1992/Gene-Selection
R
false
false
1,436
r
####Conert graph file with selected genes to gene symbols or directly to top pathways?### source("http://bioconductor.org/biocLite.R") biocLite("clusterProfiler") library(clusterProfiler) graph = "C:/Users/vinee_000/Desktop/Gene-Selection/Interpretability_Results/GSE1456_WP/graph.txt" data = read.table(graph,sep="...
## ----------------------------------------------------------- library(MASS) library(haven) library("tidyr") library("sp") library("spacetime") library(data.table) library("plyr") library("dplyr") options(dplyr.summarise.inform = FALSE) library("ggplot2") library("gstat") library("RColorBrewer") library("s...
/biomass_main.R
no_license
hxhjhy/Biomass-Demand-Analysis-model
R
false
false
6,017
r
## ----------------------------------------------------------- library(MASS) library(haven) library("tidyr") library("sp") library("spacetime") library(data.table) library("plyr") library("dplyr") options(dplyr.summarise.inform = FALSE) library("ggplot2") library("gstat") library("RColorBrewer") library("s...
######################################################################## # Using R Zonal Statistics, field observations, and LiDAR data to Identify Great Grey Owl Habitat # Jan 20, 2021 # Julian Scott (julian.a.scott@usda.gov) & Sarah Malick Wahls (sarah.malickwahls@usda.gov) # # code description... ###########...
/gitGreatGrayOwl_script.R
no_license
julianscott/gitGreatGrayOwl_Webinar
R
false
false
12,113
r
######################################################################## # Using R Zonal Statistics, field observations, and LiDAR data to Identify Great Grey Owl Habitat # Jan 20, 2021 # Julian Scott (julian.a.scott@usda.gov) & Sarah Malick Wahls (sarah.malickwahls@usda.gov) # # code description... ###########...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/shapeR.R \name{write.image.with.outline} \alias{write.image.with.outline} \title{Write outlines on top of the original images for quality checking} \usage{ write.image.with.outline(object, folder = NA, fname = NA, doProgress = TRUE) } \argume...
/man/write.image.with.outline.Rd
no_license
cran/shapeR
R
false
true
1,703
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/shapeR.R \name{write.image.with.outline} \alias{write.image.with.outline} \title{Write outlines on top of the original images for quality checking} \usage{ write.image.with.outline(object, folder = NA, fname = NA, doProgress = TRUE) } \argume...
#' Identify Records with Identical lat/lon #' #' Removes or flags records with equal latitude and longitude coordinates, either exact or #' absolute. Equal coordinates can often indicate data entry errors. #' #' #' @param test character string. Defines if coordinates are compared exactly #' (\dQuote{identical}) or o...
/R/cc_equ.R
no_license
gejielin/CoordinateCleaner
R
false
false
1,702
r
#' Identify Records with Identical lat/lon #' #' Removes or flags records with equal latitude and longitude coordinates, either exact or #' absolute. Equal coordinates can often indicate data entry errors. #' #' #' @param test character string. Defines if coordinates are compared exactly #' (\dQuote{identical}) or o...
dataPath <- "~/Desktop/" data <- read.csv(paste(dataPath,'GermanCredit.csv', sep = '/'), header=TRUE) data # Delete the column named "Class" df = subset(data, select = -c(Class,CheckingAccountStatus.none,CreditHistory.Critical, Purpose.Vacation, Purpose.Other, SavingsAccountBonds.Unknown...
/Data Mining HW1.R
no_license
renjiel0729/MSCA-Data-Mining
R
false
false
2,757
r
dataPath <- "~/Desktop/" data <- read.csv(paste(dataPath,'GermanCredit.csv', sep = '/'), header=TRUE) data # Delete the column named "Class" df = subset(data, select = -c(Class,CheckingAccountStatus.none,CreditHistory.Critical, Purpose.Vacation, Purpose.Other, SavingsAccountBonds.Unknown...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/mask_gd.R \name{mask_gd} \alias{mask_gd} \title{Mask moving window maps} \usage{ mask_gd(x, y, minval = NULL, maxval = NULL) } \arguments{ \item{x}{Raster object to mask} \item{y}{Raster object or Spatial object to use as mask} \item{minval...
/man/mask_gd.Rd
permissive
AnushaPB/wingen
R
false
true
804
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/mask_gd.R \name{mask_gd} \alias{mask_gd} \title{Mask moving window maps} \usage{ mask_gd(x, y, minval = NULL, maxval = NULL) } \arguments{ \item{x}{Raster object to mask} \item{y}{Raster object or Spatial object to use as mask} \item{minval...
library(forecast) library(vars) #################### Initial Reading #################### setwd('~/Downloads/Bankruptcy-Time-Series') train_in <- read.csv("train.csv", header=T) test_in <- read.csv("test.csv", header=T) train <- train_in[1:264,] valid <- train_in[265:288,] b_train <- ts(data=train$Bankruptcy_Rate, f...
/var_to_combine.R
no_license
chenxi-ge/Bankruptcy-Time-Series
R
false
false
11,345
r
library(forecast) library(vars) #################### Initial Reading #################### setwd('~/Downloads/Bankruptcy-Time-Series') train_in <- read.csv("train.csv", header=T) test_in <- read.csv("test.csv", header=T) train <- train_in[1:264,] valid <- train_in[265:288,] b_train <- ts(data=train$Bankruptcy_Rate, f...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/mi.R \name{plot_mi_check} \alias{plot_mi_check} \title{Visualize a topic's MI score in comparison to simulated values} \usage{ plot_mi_check(m, k, groups = NULL, n_reps = 20) } \arguments{ \item{m}{\code{mallet_model} object \emph{with sampli...
/man/plot_mi_check.Rd
permissive
regan008/dfrtopics
R
false
true
1,115
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/mi.R \name{plot_mi_check} \alias{plot_mi_check} \title{Visualize a topic's MI score in comparison to simulated values} \usage{ plot_mi_check(m, k, groups = NULL, n_reps = 20) } \arguments{ \item{m}{\code{mallet_model} object \emph{with sampli...
#' Computes a consensus matrix. #' #' @description Tallies characters at each position for a set of character vectors without any Bioconductor packages. #' #' @details #' Designed to function like consensusMatrix from Biostrings. #' #' This function can handle upper and lower case input, but will only produce upper cas...
/R/consensusMatrix.R
no_license
philliplab/yasss
R
false
false
1,480
r
#' Computes a consensus matrix. #' #' @description Tallies characters at each position for a set of character vectors without any Bioconductor packages. #' #' @details #' Designed to function like consensusMatrix from Biostrings. #' #' This function can handle upper and lower case input, but will only produce upper cas...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/module2_estimate_gpcm.R \name{estimate_gpcm} \alias{estimate_gpcm} \alias{model_gpcm_eap_scoring} \alias{model_gpcm_map_scoring} \alias{model_gpcm_dv_Pt} \alias{model_gpcm_dv_Pa} \alias{model_gpcm_dv_Pb} \alias{model_gpcm_dv_Pd} \alias{model_...
/man/estimate_gpcm.Rd
no_license
zjiang4/xxIRT
R
false
true
4,480
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/module2_estimate_gpcm.R \name{estimate_gpcm} \alias{estimate_gpcm} \alias{model_gpcm_eap_scoring} \alias{model_gpcm_map_scoring} \alias{model_gpcm_dv_Pt} \alias{model_gpcm_dv_Pa} \alias{model_gpcm_dv_Pb} \alias{model_gpcm_dv_Pd} \alias{model_...
\name{rp.var.get} \alias{rp.var.get} \title{Retrieves an object from the rpanel environment, usually from a panel.} \description{ The management of objects within the rpanel environment is usually handled `behind the scenes' but it can occasionally be useful to retrieve an object there explicitly. } \usage{ rp.var....
/man/rp.var.get.Rd
no_license
cran/rpanel
R
false
false
838
rd
\name{rp.var.get} \alias{rp.var.get} \title{Retrieves an object from the rpanel environment, usually from a panel.} \description{ The management of objects within the rpanel environment is usually handled `behind the scenes' but it can occasionally be useful to retrieve an object there explicitly. } \usage{ rp.var....
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/robust_DEG.RData.R \name{list.to.table} \alias{list.to.table} \title{unite list of deg table} \usage{ list.to.table(deg.table) } \arguments{ \item{deg.table}{deg table} } \value{ deg table united } \description{ better version volcano plot } ...
/man/list.to.table.Rd
no_license
GrigoriiNos/rimmi.rnaseq
R
false
true
398
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/robust_DEG.RData.R \name{list.to.table} \alias{list.to.table} \title{unite list of deg table} \usage{ list.to.table(deg.table) } \arguments{ \item{deg.table}{deg table} } \value{ deg table united } \description{ better version volcano plot } ...
# scrape player stats library(tidyverse) library(rvest) library(robotstxt) paths_allowed("https://www.basketball-reference.com") scrape_player_stats <- function(x){ y <- read_html(x) game_number <- y %>% html_nodes("tbody th") %>% html_text() %>% as.numeric() date <- y %>% html_nodes(".right+ .l...
/scraping_scripts/ScrapeDukePlayerStats.R
no_license
JackLich10/data_plus_basketball
R
false
false
5,267
r
# scrape player stats library(tidyverse) library(rvest) library(robotstxt) paths_allowed("https://www.basketball-reference.com") scrape_player_stats <- function(x){ y <- read_html(x) game_number <- y %>% html_nodes("tbody th") %>% html_text() %>% as.numeric() date <- y %>% html_nodes(".right+ .l...
# an R script x <- c(1,2,3,4) mean(x)
/fun/t.R
no_license
eolapade/svm
R
false
false
38
r
# an R script x <- c(1,2,3,4) mean(x)
to_biblatex <- function(object, ...) { format_bibentry1 <- function(object) { object <- unclass(object)[[1L]] rval <- paste0("@", attr(object, "bibtype"), "{", attr(object, "key"), ",") nl.ind <- which(names(object) %in% RefManageR:::.BibEntryNameList) for (i in nl.ind) object[i] <...
/biblatex_hacks.R
no_license
jacob-long/cv
R
false
false
2,329
r
to_biblatex <- function(object, ...) { format_bibentry1 <- function(object) { object <- unclass(object)[[1L]] rval <- paste0("@", attr(object, "bibtype"), "{", attr(object, "key"), ",") nl.ind <- which(names(object) %in% RefManageR:::.BibEntryNameList) for (i in nl.ind) object[i] <...
args <- commandArgs(TRUE) inputfilename=args[1] output_prot=args[2] output_pep=args[3] source("json_plot_venn_to_pallab.R") plotVennDiagram_json(inputfilename,output_prot,output_pep)
/peptidemapper/updatefile/pass_argument_to_r_function.R
permissive
uvic-proteincentre/MRMAssayDB
R
false
false
183
r
args <- commandArgs(TRUE) inputfilename=args[1] output_prot=args[2] output_pep=args[3] source("json_plot_venn_to_pallab.R") plotVennDiagram_json(inputfilename,output_prot,output_pep)
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/data-movie.R \docType{data} \name{movie_473} \alias{movie_473} \title{The Men Who Stare at Goats} \format{igraph object} \source{ https://dataverse.harvard.edu/dataset.xhtml?persistentId=doi:10.7910/DVN/T4HBA3 https://www.imdb.com/title/tt12...
/man/movie_473.Rd
permissive
kjhealy/networkdata
R
false
true
1,033
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/data-movie.R \docType{data} \name{movie_473} \alias{movie_473} \title{The Men Who Stare at Goats} \format{igraph object} \source{ https://dataverse.harvard.edu/dataset.xhtml?persistentId=doi:10.7910/DVN/T4HBA3 https://www.imdb.com/title/tt12...
\name{h2o.ls} \alias{h2o.ls} \title{Obtain a list of H2O keys from the running instance of H2O} \description{Allows users to access a list of object keys in the running instance of H2O} \usage{ h2o.ls(object, pattern) } \arguments{ \item{object}{An \code{H2OClient} object containing the IP address and port number of ...
/R/h2oRClient-package/man/h2o.ls.Rd
permissive
svaithianatha/h2o
R
false
false
1,039
rd
\name{h2o.ls} \alias{h2o.ls} \title{Obtain a list of H2O keys from the running instance of H2O} \description{Allows users to access a list of object keys in the running instance of H2O} \usage{ h2o.ls(object, pattern) } \arguments{ \item{object}{An \code{H2OClient} object containing the IP address and port number of ...
library(ICGE) ### Name: proxi ### Title: Proximity Function ### Aliases: proxi ### Keywords: multivariate ### ** Examples data(iris) d <- dist(iris[,1:4]) # xo contains a unit from one group, as for example group 1. x0 <- c(5.3, 3.6, 1.1, 0.1) # distances between x0 and the other units. dx0 <- rep(0,150) for (i i...
/data/genthat_extracted_code/ICGE/examples/proxi.Rd.R
no_license
surayaaramli/typeRrh
R
false
false
663
r
library(ICGE) ### Name: proxi ### Title: Proximity Function ### Aliases: proxi ### Keywords: multivariate ### ** Examples data(iris) d <- dist(iris[,1:4]) # xo contains a unit from one group, as for example group 1. x0 <- c(5.3, 3.6, 1.1, 0.1) # distances between x0 and the other units. dx0 <- rep(0,150) for (i i...
#' @import rJava .onLoad<-function(libname, pkgname){ .jpackage(pkgname, lib.loc = libname) }
/R/onLoad.R
no_license
palatej/rjdsa
R
false
false
99
r
#' @import rJava .onLoad<-function(libname, pkgname){ .jpackage(pkgname, lib.loc = libname) }
/man/pairwise.MVA.test.Rd
no_license
SeptiawanAjiP/RVAideMemoire
R
false
false
2,587
rd
# E02_Matrices.R - DESC # E02_Matrices.R # Copyright 2011-13 JRC FishReg. Distributed under the GPL 2 or later # Maintainer: FishReg, JRC # Introduction to R for Fisheries Science # Exercise 01 # 1. Create a matrix with 10 rows and 15 columns, containing random # numbers (choose your distribution) # 2. Subset the...
/Day01/E02_Matrices.R
no_license
ariffahmi7/RforFisheries
R
false
false
391
r
# E02_Matrices.R - DESC # E02_Matrices.R # Copyright 2011-13 JRC FishReg. Distributed under the GPL 2 or later # Maintainer: FishReg, JRC # Introduction to R for Fisheries Science # Exercise 01 # 1. Create a matrix with 10 rows and 15 columns, containing random # numbers (choose your distribution) # 2. Subset the...
#' @title Save ggplot-figure for print publication #' @name save_plot #' #' @description Convenient function to save the last ggplot-figure in #' high quality for publication. #' #' @param filename Name of the output file; filename must end with one #' of the following accepted file types: ".pn...
/R/save_plot.R
no_license
cran/sjPlot
R
false
false
3,869
r
#' @title Save ggplot-figure for print publication #' @name save_plot #' #' @description Convenient function to save the last ggplot-figure in #' high quality for publication. #' #' @param filename Name of the output file; filename must end with one #' of the following accepted file types: ".pn...
# Setting up working directory setwd('/Users/Miller/Desktop/ML/') #Importing training file with replacing blank with NA a=read.csv("pml-training.csv",na.strings=c('','NA')) b=a[,!apply(a,2,function(x) any(is.na(x)) )] #Removing variables from 1 to 7 c=b[,-c(1:7)] #Creating training and test data inTrain=createDataParti...
/Prediction Assignment Writeup.R
no_license
JamshidSod/ML
R
false
false
1,030
r
# Setting up working directory setwd('/Users/Miller/Desktop/ML/') #Importing training file with replacing blank with NA a=read.csv("pml-training.csv",na.strings=c('','NA')) b=a[,!apply(a,2,function(x) any(is.na(x)) )] #Removing variables from 1 to 7 c=b[,-c(1:7)] #Creating training and test data inTrain=createDataParti...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/pScore.R \name{pScore} \alias{pScore} \title{Transform p-values to a continuous score} \usage{ pScore(p, sign = 1) } \arguments{ \item{p}{\emph{p}-value between (0,1]} \item{sign}{Sign of the score, either positive (in case of positive numbe...
/ribiosUtils/man/pScore.Rd
no_license
RCBiczok/ribios
R
false
true
823
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/pScore.R \name{pScore} \alias{pScore} \title{Transform p-values to a continuous score} \usage{ pScore(p, sign = 1) } \arguments{ \item{p}{\emph{p}-value between (0,1]} \item{sign}{Sign of the score, either positive (in case of positive numbe...
#' Find occurrences. #' #' @usage occurrence(scientificname = NULL, taxonid = NULL, datasetid = NULL, #' nodeid = NULL, areaid = NULL, startdate = NULL, enddate = NULL, #' startdepth = NULL, enddepth = NULL, geometry = NULL, #' measurementtype = NULL, measurementtypeid = NULL, measurementvalue = NULL, #' measur...
/R/occurrence.R
permissive
howlerMoonkey/robis
R
false
false
6,340
r
#' Find occurrences. #' #' @usage occurrence(scientificname = NULL, taxonid = NULL, datasetid = NULL, #' nodeid = NULL, areaid = NULL, startdate = NULL, enddate = NULL, #' startdepth = NULL, enddepth = NULL, geometry = NULL, #' measurementtype = NULL, measurementtypeid = NULL, measurementvalue = NULL, #' measur...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/frame.R \name{h2o.listTimezones} \alias{h2o.listTimezones} \title{List all of the Time Zones Acceptable by the H2O cluster.} \usage{ h2o.listTimezones() } \description{ List all of the Time Zones Acceptable by the H2O cluster. }
/man/h2o.listTimezones.Rd
no_license
cran/h2o
R
false
true
307
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/frame.R \name{h2o.listTimezones} \alias{h2o.listTimezones} \title{List all of the Time Zones Acceptable by the H2O cluster.} \usage{ h2o.listTimezones() } \description{ List all of the Time Zones Acceptable by the H2O cluster. }
#------------------------------------------------------------------------------- # Copyright (c) 2012 University of Illinois, NCSA. # All rights reserved. This program and the accompanying materials # are made available under the terms of the # University of Illinois/NCSA Open Source License # which accompanies this d...
/models/template/tests/testthat.R
permissive
Amanskywalker/pecan
R
false
false
581
r
#------------------------------------------------------------------------------- # Copyright (c) 2012 University of Illinois, NCSA. # All rights reserved. This program and the accompanying materials # are made available under the terms of the # University of Illinois/NCSA Open Source License # which accompanies this d...
cr = 15 # number of cores # n *n_iter is the number of subsets to be generated per subset size n = 1000 n_iter = 2 library(reshape) library(abind) library(DESeq2) library(svMisc) library(openxlsx) library(RUVSeq) library(sva) library(BiocParallel) library(foreach) library(doSNOW) annot = read.csv('data/tmpsaveall_an...
/DE_reproducibility/Script_1: DE_subsample.r
no_license
hmbaghdassarian/freezethaw_effect
R
false
false
8,475
r
cr = 15 # number of cores # n *n_iter is the number of subsets to be generated per subset size n = 1000 n_iter = 2 library(reshape) library(abind) library(DESeq2) library(svMisc) library(openxlsx) library(RUVSeq) library(sva) library(BiocParallel) library(foreach) library(doSNOW) annot = read.csv('data/tmpsaveall_an...
test_that("nuclearPed() direct labelling works", { expect_identical(nuclearPed(1), nuclearPed(children='3')) expect_identical(nuclearPed(1, sex=2), nuclearPed(children='3', sex=2)) expect_identical(relabel(nuclearPed(1), letters[3:1]), nuclearPed(fa='c', mo='b', children='a')) expect_ide...
/tests/testthat/test-ped-basic.R
no_license
cran/pedtools
R
false
false
2,245
r
test_that("nuclearPed() direct labelling works", { expect_identical(nuclearPed(1), nuclearPed(children='3')) expect_identical(nuclearPed(1, sex=2), nuclearPed(children='3', sex=2)) expect_identical(relabel(nuclearPed(1), letters[3:1]), nuclearPed(fa='c', mo='b', children='a')) expect_ide...
#' @name chao #' @title The Chao lower bound estimate of pan-genome size #' #' @description Computes the Chao lower bound estimated number of gene clusters in a pan-genome. #' #' @param pan.matrix A \code{Panmat} object, see \code{\link{panMatrix}} for details. #' #' @details The size of a pan-genome is the n...
/R/powerlaw.R
no_license
rajaldebnath/micropan
R
false
false
5,523
r
#' @name chao #' @title The Chao lower bound estimate of pan-genome size #' #' @description Computes the Chao lower bound estimated number of gene clusters in a pan-genome. #' #' @param pan.matrix A \code{Panmat} object, see \code{\link{panMatrix}} for details. #' #' @details The size of a pan-genome is the n...
% Generated by roxygen2 (4.1.1): do not edit by hand % Please edit documentation in R/functions.R \name{dijkstra} \alias{dijkstra} \title{Dijkstra's algorithm} \usage{ dijkstra(graph, init_node) } \arguments{ \item{graph}{A graph that is defined by a data frame containing the three columns \code{v1}, \code{v2} and \cod...
/man/dijkstra.Rd
no_license
oscpe436/Laboration_3
R
false
false
1,217
rd
% Generated by roxygen2 (4.1.1): do not edit by hand % Please edit documentation in R/functions.R \name{dijkstra} \alias{dijkstra} \title{Dijkstra's algorithm} \usage{ dijkstra(graph, init_node) } \arguments{ \item{graph}{A graph that is defined by a data frame containing the three columns \code{v1}, \code{v2} and \cod...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/projects_and_repos.R \name{gl_new_project} \alias{gl_new_project} \alias{gl_edit_project} \alias{gl_delete_project} \title{Manage projects} \usage{ gl_new_project(name, path, ...) gl_edit_project(project, ...) gl_delete_project(project) } \...
/man/gl_new_project.Rd
no_license
cran/gitlabr
R
false
true
1,414
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/projects_and_repos.R \name{gl_new_project} \alias{gl_new_project} \alias{gl_edit_project} \alias{gl_delete_project} \title{Manage projects} \usage{ gl_new_project(name, path, ...) gl_edit_project(project, ...) gl_delete_project(project) } \...
########################################################### #### Stat 133 Midterm 4 # leave this here: set.seed(123456) #### Simulation # Write a function, [dice_sum()], that takes as input: # [k] : the number of dice rolled # [B] : the number of rolls # and returns: # [dsum] : a vector of length B where each elemen...
/midterm4/midterm4.R
no_license
snehapang/stat133
R
false
false
3,232
r
########################################################### #### Stat 133 Midterm 4 # leave this here: set.seed(123456) #### Simulation # Write a function, [dice_sum()], that takes as input: # [k] : the number of dice rolled # [B] : the number of rolls # and returns: # [dsum] : a vector of length B where each elemen...
### PLOT 3 ### library(data.table) ## Getting the entire dataset : Electric power consumption data_entire <- fread ("/Users/salimahmokhtar/household_power_consumption.txt", na.strings="?") ## Subsetting the data from the dates 2007-02-01 and 2007-02-02 data_entire$Date <- as.Date(data_entire$Date, format="%d/%m/%Y")...
/plot3.R
no_license
FarisJakpau/ExData_Plotting1
R
false
false
962
r
### PLOT 3 ### library(data.table) ## Getting the entire dataset : Electric power consumption data_entire <- fread ("/Users/salimahmokhtar/household_power_consumption.txt", na.strings="?") ## Subsetting the data from the dates 2007-02-01 and 2007-02-02 data_entire$Date <- as.Date(data_entire$Date, format="%d/%m/%Y")...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/data-movie.R \docType{data} \name{movie_730} \alias{movie_730} \title{The Usual Suspects} \format{igraph object} \source{ https://dataverse.harvard.edu/dataset.xhtml?persistentId=doi:10.7910/DVN/T4HBA3 https://www.imdb.com/title/tt0114814 } ...
/man/movie_730.Rd
permissive
kjhealy/networkdata
R
false
true
1,017
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/data-movie.R \docType{data} \name{movie_730} \alias{movie_730} \title{The Usual Suspects} \format{igraph object} \source{ https://dataverse.harvard.edu/dataset.xhtml?persistentId=doi:10.7910/DVN/T4HBA3 https://www.imdb.com/title/tt0114814 } ...
#Full factorial example #http://www.itl.nist.gov/div898/handbook/pri/section4/pri471.htm #R commands and output: ## Read data and save relevant variables. m = matrix(scan("ceramic.dat",skip=1),ncol=7,byrow=T) strength = m[,6] order = m[,7] ## Save variables as factors. speed = as.factor(m[,1]) rate = as.factor(m[,2])...
/NIST-Engineering-Handbook/pri471.r
no_license
matthewmaclennan/R-Hidden-codes
R
false
false
19,417
r
#Full factorial example #http://www.itl.nist.gov/div898/handbook/pri/section4/pri471.htm #R commands and output: ## Read data and save relevant variables. m = matrix(scan("ceramic.dat",skip=1),ncol=7,byrow=T) strength = m[,6] order = m[,7] ## Save variables as factors. speed = as.factor(m[,1]) rate = as.factor(m[,2])...
library(shiny) library(tidyverse) # Define UI for application that draws a histogram ui <- fluidPage( # Application title titlePanel(" "), # Sidebar with a slider input for number of bins sidebarLayout( sidebarPanel( numericInput(inputId = "loan_n", label = "Number of loans:...
/statistical programming - STA 523/1017/app.R
no_license
jaehyunlee1221/Duke-2019-Fall-code
R
false
false
2,378
r
library(shiny) library(tidyverse) # Define UI for application that draws a histogram ui <- fluidPage( # Application title titlePanel(" "), # Sidebar with a slider input for number of bins sidebarLayout( sidebarPanel( numericInput(inputId = "loan_n", label = "Number of loans:...
Sys.setlocale("LC_ALL", "C")
/scripts/setlocale.R
no_license
VadimMalykh/AnalyticsEdgeKaggle
R
false
false
29
r
Sys.setlocale("LC_ALL", "C")
#' @title Hyperbolic model equation #' #' @description This function sets up the hyperbolic model equation for use by #' \code{\link{fit_binding_model}}. If a Hill coefficient different from 1 #' is specified in the set of parameters, this equation will describe a Hill #' model. #' #' @param conc Ligand con...
/R/equations.R
permissive
tiana22/rfret
R
false
false
1,900
r
#' @title Hyperbolic model equation #' #' @description This function sets up the hyperbolic model equation for use by #' \code{\link{fit_binding_model}}. If a Hill coefficient different from 1 #' is specified in the set of parameters, this equation will describe a Hill #' model. #' #' @param conc Ligand con...
###Load Packages### ##always load plyr before dplyr## library(shiny) library(shinyjs) library(leaflet) library(shinythemes) library(rsconnect) ##source the global file with all the necessary data source("global.R") ##set up "water" for the water quality input select for data explorer tab gear<- c( "Large Otter Trawl...
/CatchApp2.0/app.R
no_license
aebarros/shiny-server
R
false
false
5,274
r
###Load Packages### ##always load plyr before dplyr## library(shiny) library(shinyjs) library(leaflet) library(shinythemes) library(rsconnect) ##source the global file with all the necessary data source("global.R") ##set up "water" for the water quality input select for data explorer tab gear<- c( "Large Otter Trawl...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/makeDTM.R \name{findAssocTwo} \alias{findAssocTwo} \title{findAssocTwo} \usage{ findAssocTwo(dtm, term1, term2) } \arguments{ \item{dtm}{matrix. Document Term Matrix} \item{term1}{character. keyword 1.} \item{term2}{character. ...
/man/findAssocTwo.Rd
no_license
SukjaeChoi/makeDTM
R
false
true
507
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/makeDTM.R \name{findAssocTwo} \alias{findAssocTwo} \title{findAssocTwo} \usage{ findAssocTwo(dtm, term1, term2) } \arguments{ \item{dtm}{matrix. Document Term Matrix} \item{term1}{character. keyword 1.} \item{term2}{character. ...
# instalacja pakietow w R # install.packages(c("WriteXLS", "dplyr", "reshape2"), repos = "https://cloud.r-project.org/") # uruchamianie programu w bashu (w katalogu, gdzie sa powtorzenia) # R -e 'source("process_penna.R")' library(dplyr) library(WriteXLS) library(reshape2) safe_as_numeric <- function(x) { x_num <-...
/process_penna.R
no_license
michbur/penna_model_analysis
R
false
false
16,746
r
# instalacja pakietow w R # install.packages(c("WriteXLS", "dplyr", "reshape2"), repos = "https://cloud.r-project.org/") # uruchamianie programu w bashu (w katalogu, gdzie sa powtorzenia) # R -e 'source("process_penna.R")' library(dplyr) library(WriteXLS) library(reshape2) safe_as_numeric <- function(x) { x_num <-...
# Swagger Petstore # # This is a sample server Petstore server. You can find out more about Swagger at [http://swagger.io](http://swagger.io) or on [irc.freenode.net, #swagger](http://swagger.io/irc/). For this sample, you can use the api key `special-key` to test the authorization filters. # # OpenAPI spec version...
/samples/client/petstore/R/R/Tag.r
permissive
swagger-api/swagger-codegen
R
false
false
1,930
r
# Swagger Petstore # # This is a sample server Petstore server. You can find out more about Swagger at [http://swagger.io](http://swagger.io) or on [irc.freenode.net, #swagger](http://swagger.io/irc/). For this sample, you can use the api key `special-key` to test the authorization filters. # # OpenAPI spec version...
% Generated by roxygen2 (4.1.0): do not edit by hand % Please edit documentation in R/data.R \docType{data} \name{socialcounts} \alias{socialcounts} \title{socialcounts data} \format{\Sexpr[results=rd]{bps6data:::doc_bps6_data("socialcounts") }} \source{ \url{ http://content.bfwpub.com/webroot_pubcontent/Content/BCS_5/...
/man/socialcounts.Rd
no_license
jrnold/bps6data
R
false
false
639
rd
% Generated by roxygen2 (4.1.0): do not edit by hand % Please edit documentation in R/data.R \docType{data} \name{socialcounts} \alias{socialcounts} \title{socialcounts data} \format{\Sexpr[results=rd]{bps6data:::doc_bps6_data("socialcounts") }} \source{ \url{ http://content.bfwpub.com/webroot_pubcontent/Content/BCS_5/...
#' Minimal doc #' @import gWidgets MASS Rcpp RGtk2 cairoDevice #' @description minimal documentation for roxygen purposes and could be added later #' @export options("guiToolkit"="RGtk2") #create the Main window. ELEFAN_gui <- function(){ my_path <- paste(.libPaths()[1],"/ELEFAN",sep="") size=1000 window = gwindo...
/R/Main_gui.R
no_license
AaronGreenberg/ELEFAN
R
false
false
30,120
r
#' Minimal doc #' @import gWidgets MASS Rcpp RGtk2 cairoDevice #' @description minimal documentation for roxygen purposes and could be added later #' @export options("guiToolkit"="RGtk2") #create the Main window. ELEFAN_gui <- function(){ my_path <- paste(.libPaths()[1],"/ELEFAN",sep="") size=1000 window = gwindo...
# Created: OB, 01.12.2019 # This script assesses and explains elastic net models by visualizing prediction activations and other analyses ## 0. Defines parameters --> lines 0-74 ## 1. Recalls models and the datasets (used in model training in a separate cluster) --> lines 75-539 ## 2. Plots lambda, cve and beta coeffi...
/scripts/R/4_AUC_and_model_assessment/DL_prediction_AUC_loop.R
no_license
obruck/MDS_HE_IA
R
false
false
84,574
r
# Created: OB, 01.12.2019 # This script assesses and explains elastic net models by visualizing prediction activations and other analyses ## 0. Defines parameters --> lines 0-74 ## 1. Recalls models and the datasets (used in model training in a separate cluster) --> lines 75-539 ## 2. Plots lambda, cve and beta coeffi...
nu<-4 for(kt in 1:KT){ curr.y<-y curr.y[missing]<-curr.missing[kt,] ############################ dstar ################################################ GT<-t(G)%*%curr.iT[kt,,] HRH<-icurr.ome[kt,,]%x%(GT%*%G) iVd<-HRH+icurr.sig[kt,,]%x%curr.iA[kt,,] Vd<-chol2inv(chol(iVd)) mud<-as.vector(Vd%*%matrix(...
/MCMC_B.R
no_license
amo105/chemicalkinetics
R
false
false
13,496
r
nu<-4 for(kt in 1:KT){ curr.y<-y curr.y[missing]<-curr.missing[kt,] ############################ dstar ################################################ GT<-t(G)%*%curr.iT[kt,,] HRH<-icurr.ome[kt,,]%x%(GT%*%G) iVd<-HRH+icurr.sig[kt,,]%x%curr.iA[kt,,] Vd<-chol2inv(chol(iVd)) mud<-as.vector(Vd%*%matrix(...
monthst = read.csv("monthst.csv") appday$daynum = ifelse(appday$day == "Mon", 1, ifelse(appday$day == "Tues", 2, ifelse(appday$day == "Wed", 3, ifelse(appday$day == "Thurs", 4, ifelse(appday$day == "Fri", 5, ...
/3-Codes/reorder.R
no_license
chloezhan/ShinyStar-LA311
R
false
false
1,425
r
monthst = read.csv("monthst.csv") appday$daynum = ifelse(appday$day == "Mon", 1, ifelse(appday$day == "Tues", 2, ifelse(appday$day == "Wed", 3, ifelse(appday$day == "Thurs", 4, ifelse(appday$day == "Fri", 5, ...
#' Data for Figure 3 #' #' The data, inspired from \insertCite{cl16}{superb}, is an example where the #' "stand-alone" 95\% confidence interval of the means returns #' a result in contradiction with the result of a statistical test. #' The paradoxical result is resolved by using adjusted confidence intervals, #' here t...
/R/dataFigure3.R
no_license
humanfactors/superb
R
false
false
2,137
r
#' Data for Figure 3 #' #' The data, inspired from \insertCite{cl16}{superb}, is an example where the #' "stand-alone" 95\% confidence interval of the means returns #' a result in contradiction with the result of a statistical test. #' The paradoxical result is resolved by using adjusted confidence intervals, #' here t...
# # Efficient reshaping with data.table # # https://rawgit.com/wiki/Rdatatable/data.table/vignettes/datatable-reshape.html # library(magrittr) library(data.table) # read the data DT <- fread("https://raw.githubusercontent.com/Rdatatable/data.table/master/vignettes/melt_default.csv") DT2 <- fread("https://raw.githubuse...
/datatableReshaping.R
no_license
raikhan/dataCampCourses
R
false
false
1,357
r
# # Efficient reshaping with data.table # # https://rawgit.com/wiki/Rdatatable/data.table/vignettes/datatable-reshape.html # library(magrittr) library(data.table) # read the data DT <- fread("https://raw.githubusercontent.com/Rdatatable/data.table/master/vignettes/melt_default.csv") DT2 <- fread("https://raw.githubuse...
#example install.packages("dplyr", lib = "libraryFolder") #The initial sets are independently generated (and saved) in each run args<-(commandArgs(TRUE)); if(length(args)==0){ print("No arguments supplied.") }else{ for(i in 1:length(args)){ eval(parse(text=args[[i]])) } print(args) } library(plyr) lib...
/mathematical-models/batch_fit_code/model_fit_latent_base_batch.R
no_license
bryanmayer/CMV-Primary-Infection
R
false
false
3,168
r
#example install.packages("dplyr", lib = "libraryFolder") #The initial sets are independently generated (and saved) in each run args<-(commandArgs(TRUE)); if(length(args)==0){ print("No arguments supplied.") }else{ for(i in 1:length(args)){ eval(parse(text=args[[i]])) } print(args) } library(plyr) lib...
write_quiz_html_ma= function(question) { return(write_quiz_html_mc(question, minimumcorrect = 1, maximumcorrect = (length(question$answer)-1) )) }
/engine/write_quiz_html_ma.R
no_license
alucas69/CanvasQuizR
R
false
false
149
r
write_quiz_html_ma= function(question) { return(write_quiz_html_mc(question, minimumcorrect = 1, maximumcorrect = (length(question$answer)-1) )) }
#' Filter by overlapping/non-overlapping ranges #' #' @param x,y Objects representing ranges #' @param maxgap The maximimum gap between intervals as a single #' integer greater than or equal to -1. If you modify this argument, #' `minoverlap` must be held fixed. #' @param minoverlap The minimum amount of overlap betw...
/R/ranges-overlap-filter.R
no_license
liupfskygre/plyranges
R
false
false
2,827
r
#' Filter by overlapping/non-overlapping ranges #' #' @param x,y Objects representing ranges #' @param maxgap The maximimum gap between intervals as a single #' integer greater than or equal to -1. If you modify this argument, #' `minoverlap` must be held fixed. #' @param minoverlap The minimum amount of overlap betw...
#' @include Classifier.R setClass("SelfLearning", representation(model="Classifier",n_iter="numeric",i_labels="list"), prototype(name="Self Learning"), contains="Classifier") #' Self Learning Semi-supervised Learning #' #' Use self learning to turn any supervised classifier into a semi-super...
/R/SelfLearning.R
no_license
luojiahuli/RSSL
R
false
false
4,761
r
#' @include Classifier.R setClass("SelfLearning", representation(model="Classifier",n_iter="numeric",i_labels="list"), prototype(name="Self Learning"), contains="Classifier") #' Self Learning Semi-supervised Learning #' #' Use self learning to turn any supervised classifier into a semi-super...
########################################################################################## # Designed and developed by Tinniam V Ganesh # Date : 30 Jun 2015 # Function: bowlerHistWickets # This function plots the a histogram of Wicket percentages versus wickets # ########################################################...
/R/bowlerHistWickets.R
no_license
tvganesh/ckt15
R
false
false
1,343
r
########################################################################################## # Designed and developed by Tinniam V Ganesh # Date : 30 Jun 2015 # Function: bowlerHistWickets # This function plots the a histogram of Wicket percentages versus wickets # ########################################################...
### R code from vignette source 'r3Cseq.Rnw' ################################################### ### code chunk number 1: setup ################################################### options(width = 60) olocale=Sys.setlocale(locale="C") ################################################### ### code chunk number 2: r3Cseq...
/inst/doc/r3Cseq.R
no_license
supatt-lab/r3Cseq
R
false
false
4,220
r
### R code from vignette source 'r3Cseq.Rnw' ################################################### ### code chunk number 1: setup ################################################### options(width = 60) olocale=Sys.setlocale(locale="C") ################################################### ### code chunk number 2: r3Cseq...
## Caching the Inverse of a Matrix ## Below are a pair of functions that are used to create an object that ## stores a matrix and caches its inverse. ## This function creates a matrix object that can cache its inverse. makeCacheMatrix <- function(x = matrix()) { inv <- NULL set <- function(a) { ...
/cachematrix.R
no_license
cbracale5/ProgrammingAssignment2
R
false
false
1,068
r
## Caching the Inverse of a Matrix ## Below are a pair of functions that are used to create an object that ## stores a matrix and caches its inverse. ## This function creates a matrix object that can cache its inverse. makeCacheMatrix <- function(x = matrix()) { inv <- NULL set <- function(a) { ...
/MODIS/MODIS_annual_EVI_boxplots.R
no_license
kublaj/R-codes
R
false
false
3,212
r
### ### This is step15_plot.metabolome.microbiome.functional.analysis.R, part of the Nature Protocol: ### 'A computational framework for conducting a three-pronged association study ### to integrate high-throughput ‘-omics’ datasets for the identification of ### potential mechanistic links'. ### 26/7-2018 ### ### ###...
/Rscripts/step15_plot.metabolome.microbiome.functional.analysis.R
no_license
gintian/microbiome_metabolome
R
false
false
4,626
r
### ### This is step15_plot.metabolome.microbiome.functional.analysis.R, part of the Nature Protocol: ### 'A computational framework for conducting a three-pronged association study ### to integrate high-throughput ‘-omics’ datasets for the identification of ### potential mechanistic links'. ### 26/7-2018 ### ### ###...
# $Id: qqnorm.aov.R 625 2005-06-09 14:20:30Z nj7w $ if(is.R()) qqnorm.aov <- function (y, full = FALSE, label = FALSE, omit = NULL, xlab = paste(if(full) "" else "Half", " Normal plot"), ylab = "Effects", ...) { r <- y$rank eff <- if (full) effects(y, set...
/R/qqnorm.aov.R
no_license
talgalili/gplots
R
false
false
1,004
r
# $Id: qqnorm.aov.R 625 2005-06-09 14:20:30Z nj7w $ if(is.R()) qqnorm.aov <- function (y, full = FALSE, label = FALSE, omit = NULL, xlab = paste(if(full) "" else "Half", " Normal plot"), ylab = "Effects", ...) { r <- y$rank eff <- if (full) effects(y, set...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/data.R \docType{data} \name{demo_fimo_granges} \alias{demo_fimo_granges} \title{a list of GRanges instances with TF FIMO scores returned by `fimo_granges`} \format{a list of GRanges instances} \usage{ demo_fimo_granges } \description{ a list ...
/man/demo_fimo_granges.Rd
no_license
vjcitn/TxRegInfraObsolete
R
false
true
454
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/data.R \docType{data} \name{demo_fimo_granges} \alias{demo_fimo_granges} \title{a list of GRanges instances with TF FIMO scores returned by `fimo_granges`} \format{a list of GRanges instances} \usage{ demo_fimo_granges } \description{ a list ...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/plotAlevinKneeNbrGenes.R \name{plotAlevinKneeNbrGenes} \alias{plotAlevinKneeNbrGenes} \title{Knee plot of the number of detected genes per cell} \usage{ plotAlevinKneeNbrGenes(cbTable) } \arguments{ \item{cbTable}{\code{data.frame} (such as t...
/man/plotAlevinKneeNbrGenes.Rd
permissive
PeteHaitch/alevinQC
R
false
true
794
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/plotAlevinKneeNbrGenes.R \name{plotAlevinKneeNbrGenes} \alias{plotAlevinKneeNbrGenes} \title{Knee plot of the number of detected genes per cell} \usage{ plotAlevinKneeNbrGenes(cbTable) } \arguments{ \item{cbTable}{\code{data.frame} (such as t...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/Classes.R \docType{class} \name{TCA-class} \alias{TCA} \alias{TCA-class} \alias{TCAFromSummarizedExperiment} \title{TCA class and constructor} \usage{ TCA(design, counts = matrix(0L, 0L, 0L), genomicFeature, zero.based = TRUE) TCA...
/man/TCA.Rd
no_license
MusculusMus/TCseq
R
false
true
4,281
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/Classes.R \docType{class} \name{TCA-class} \alias{TCA} \alias{TCA-class} \alias{TCAFromSummarizedExperiment} \title{TCA class and constructor} \usage{ TCA(design, counts = matrix(0L, 0L, 0L), genomicFeature, zero.based = TRUE) TCA...
#' Visual Map #' #' @inheritParams e_bar #' @param serie Column name of serie to scale against. #' @param calculable Whether show handles, which can be dragged to adjust "selected range". #' @param type One of \code{continuous} or \code{piecewise}. #' @param scale A function that takes a vector of \code{numeric} and r...
/R/opts.R
permissive
Hansz00/echarts4r
R
false
false
26,347
r
#' Visual Map #' #' @inheritParams e_bar #' @param serie Column name of serie to scale against. #' @param calculable Whether show handles, which can be dragged to adjust "selected range". #' @param type One of \code{continuous} or \code{piecewise}. #' @param scale A function that takes a vector of \code{numeric} and r...
data <- sec4_choice2 n <- nrow(data) m <- 3 alt <- c("A","B","C") data_long <- data.frame() for (i in 1:100) { datai <- data.frame(rep(i,m), rep(data$id[i],m), rep(data$Date[i],m), alt, (alt == data$Choice[i]), ...
/#Archive/x7141/2020/mixture_data.R
no_license
hsgws/hsgws.github.io
R
false
false
892
r
data <- sec4_choice2 n <- nrow(data) m <- 3 alt <- c("A","B","C") data_long <- data.frame() for (i in 1:100) { datai <- data.frame(rep(i,m), rep(data$id[i],m), rep(data$Date[i],m), alt, (alt == data$Choice[i]), ...
require(ggplot2, quietly=TRUE) require(scales) require(bdscale) nyse <- yahoo() set.seed(12345) df <- data.frame(date=nyse, price=cumsum(rnorm(length(nyse))) + 100) df <- subset(df, as.Date('2014-08-01') <= date & date <= as.Date('2014-10-08')) plot <- ggplot(df, aes(x=date, y=price)) + geom_step() + theme(axis....
/exec/example_scale_bd.R
no_license
dvmlls/bdscale
R
false
false
1,337
r
require(ggplot2, quietly=TRUE) require(scales) require(bdscale) nyse <- yahoo() set.seed(12345) df <- data.frame(date=nyse, price=cumsum(rnorm(length(nyse))) + 100) df <- subset(df, as.Date('2014-08-01') <= date & date <= as.Date('2014-10-08')) plot <- ggplot(df, aes(x=date, y=price)) + geom_step() + theme(axis....
testlist <- list(AgeVector = c(-4.73074171454048e-167, 2.2262381097027e-76, -9.12990429452974e-204, 5.97087417427845e-79, 4.7390525269307e-300, 6.58361441690132e-121, 3.58611068217862e-154, -2.94504776827523e-186, 2.62380314702636e-116, -6.78950518864266e+23, 6.99695749856012e-167, 86485.676793021, 1.11271562183704...
/myTAI/inst/testfiles/cpp_bootMatrix/AFL_cpp_bootMatrix/cpp_bootMatrix_valgrind_files/1615768299-test.R
no_license
akhikolla/updatedatatype-list3
R
false
false
1,803
r
testlist <- list(AgeVector = c(-4.73074171454048e-167, 2.2262381097027e-76, -9.12990429452974e-204, 5.97087417427845e-79, 4.7390525269307e-300, 6.58361441690132e-121, 3.58611068217862e-154, -2.94504776827523e-186, 2.62380314702636e-116, -6.78950518864266e+23, 6.99695749856012e-167, 86485.676793021, 1.11271562183704...
context("Comparative analysis") library(RNeXML) library(geiger) test_that("We can extract tree and trait data to run fitContinuous and fitDiscrete", { nexml <- read.nexml(system.file("examples", "comp_analysis.xml", package="RNeXML")) traits <- get_characters_list(nexml) tree <- get_tree(nexml) expect_is(tr...
/inst/tests/test_comp_analysis.R
permissive
nizamibilal/RNeXML
R
false
false
740
r
context("Comparative analysis") library(RNeXML) library(geiger) test_that("We can extract tree and trait data to run fitContinuous and fitDiscrete", { nexml <- read.nexml(system.file("examples", "comp_analysis.xml", package="RNeXML")) traits <- get_characters_list(nexml) tree <- get_tree(nexml) expect_is(tr...
## Put comments here that give an overall description of what your ## functions do ## Write a short comment describing this function # Function to generate list of functions to store a matrix and its # inverse in cache and retrive them makeCacheMatrix <- function(x = matrix()) { invMatrix <- NULL # Functio...
/cachematrix.R
no_license
e55k4y/ProgrammingAssignment2
R
false
false
1,713
r
## Put comments here that give an overall description of what your ## functions do ## Write a short comment describing this function # Function to generate list of functions to store a matrix and its # inverse in cache and retrive them makeCacheMatrix <- function(x = matrix()) { invMatrix <- NULL # Functio...
source("aperm.R") #* Seems to be some array stuff we want to support? source("append.R") #* Appending lists? I think we should source("apply.R") #* Appears to use some annoying reflection properties that are sketch source("array.R") #* Definitely want to support such an important function source("assign.R") #* Has an ...
/base/custom.R
no_license
gpfarina/sym-core-R
R
false
false
4,297
r
source("aperm.R") #* Seems to be some array stuff we want to support? source("append.R") #* Appending lists? I think we should source("apply.R") #* Appears to use some annoying reflection properties that are sketch source("array.R") #* Definitely want to support such an important function source("assign.R") #* Has an ...
library(magrittr) library(dplyr) library(stringr) library(ggplot2) training_set = read.csv('train.csv') test_set = read.csv('test.csv') test_set$Survived = rep(NA, nrow(test_set)) titanic_data = rbind(training_set, test_set) titanic_data$Survived = as.factor(titanic_data$Survived) #EXPLORATORY DATA ANALY...
/Titanic_Classification.R
no_license
svetrie/Titanic-Classification
R
false
false
4,566
r
library(magrittr) library(dplyr) library(stringr) library(ggplot2) training_set = read.csv('train.csv') test_set = read.csv('test.csv') test_set$Survived = rep(NA, nrow(test_set)) titanic_data = rbind(training_set, test_set) titanic_data$Survived = as.factor(titanic_data$Survived) #EXPLORATORY DATA ANALY...