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("foreign") setwd(paste(getwd(),"/daten",sep="")) Albus <- read.spss(file="ALLBUS2014.sav",to.data.frame = TRUE) #2.1 ctab <- table(Albus$V868,Albus$V418) ctab chisq.test(ctab) #data: ctab #X-squared = 353.28, df = 336, p-value = 0.2479 # p-value is indicating independence chisq.test(ctab, simulate.p.value =...
/Exercise 4/my-sol 4.R
no_license
digideskio/DA
R
false
false
2,242
r
library("foreign") setwd(paste(getwd(),"/daten",sep="")) Albus <- read.spss(file="ALLBUS2014.sav",to.data.frame = TRUE) #2.1 ctab <- table(Albus$V868,Albus$V418) ctab chisq.test(ctab) #data: ctab #X-squared = 353.28, df = 336, p-value = 0.2479 # p-value is indicating independence chisq.test(ctab, simulate.p.value =...
library(Sleuth2) ### Name: case2002 ### Title: Birdkeeping and Lung Cancer ### Aliases: case2002 ### Keywords: datasets ### ** Examples str(case2002)
/data/genthat_extracted_code/Sleuth2/examples/case2002.Rd.R
no_license
surayaaramli/typeRrh
R
false
false
157
r
library(Sleuth2) ### Name: case2002 ### Title: Birdkeeping and Lung Cancer ### Aliases: case2002 ### Keywords: datasets ### ** Examples str(case2002)
# this file defines the S4 classes related to 'antsImage' and their associated # methods #' An S4 class to hold a region of an antsImage #' #' @slot index indices of the region #' @slot size size of the region #' @useDynLib ANTsRCore #' @import Rcpp #' @import ITKR #' @import methods #' @import tools #' @import stats ...
/R/antsImage_class.R
permissive
Pe6r0/ANTsRCoreTest
R
false
false
24,408
r
# this file defines the S4 classes related to 'antsImage' and their associated # methods #' An S4 class to hold a region of an antsImage #' #' @slot index indices of the region #' @slot size size of the region #' @useDynLib ANTsRCore #' @import Rcpp #' @import ITKR #' @import methods #' @import tools #' @import stats ...
library(extrafont) loadfonts(device="win") library(ggplot2) #set plotting parameters windowsFonts(Times=windowsFont("TT Times New Roman")) theme_set(theme_bw(base_size=12, base_family='Times')+ theme(panel.grid.major = element_blank(), panel.grid.minor = element_blank())) library(tree)...
/code/c1_fig5.R
no_license
ben-williams/GOA_Pollock_Maturity_Williams_etal_2016
R
false
false
827
r
library(extrafont) loadfonts(device="win") library(ggplot2) #set plotting parameters windowsFonts(Times=windowsFont("TT Times New Roman")) theme_set(theme_bw(base_size=12, base_family='Times')+ theme(panel.grid.major = element_blank(), panel.grid.minor = element_blank())) library(tree)...
#Number 1: Unloading and Unzipping dataset if(!file.exists("./data")){dir.create("./data")} fileUrl <- "https://d396qusza40orc.cloudfront.net/getdata%2Fprojectfiles%2FUCI%20HAR%20Dataset.zip" download.file(fileUrl,destfile="./data/Dataset.zip") # Unzip dataSet to /data directory unzip(zipfile="./data/Dataset.zip...
/run_analysis.R
no_license
victorpauldelacruz/Peer-graded-Assignment-Getting-and-Cleaning-Data-Course-Project
R
false
false
2,479
r
#Number 1: Unloading and Unzipping dataset if(!file.exists("./data")){dir.create("./data")} fileUrl <- "https://d396qusza40orc.cloudfront.net/getdata%2Fprojectfiles%2FUCI%20HAR%20Dataset.zip" download.file(fileUrl,destfile="./data/Dataset.zip") # Unzip dataSet to /data directory unzip(zipfile="./data/Dataset.zip...
#################################################################### ########### R code for Simulation methods ########### #################################################################### #################################################################### ### Set-up for use ...
/case4_panel_GMMd_strat2.R
no_license
ppastory/myrepo
R
false
false
5,827
r
#################################################################### ########### R code for Simulation methods ########### #################################################################### #################################################################### ### Set-up for use ...
################################################################################################################ ## ## ## Domain : Telecom ...
/UpX Data Diggeres_Telecom Churn_Analysis.R
no_license
IamVicky/Telecom-Churn-Analysis
R
false
false
41,070
r
################################################################################################################ ## ## ## Domain : Telecom ...
% Generated by roxygen2 (4.1.1): do not edit by hand % Please edit documentation in R/custom-dims.R \name{get_custom_dimension} \alias{get_custom_dimension} \title{Gets a custom dimension to which the user has access to} \usage{ get_custom_dimension(account.id, webproperty.id, dimension.id, token) } \arguments{ \item{a...
/man/get_custom_dimension.Rd
no_license
jdeboer/RGA-1
R
false
false
2,437
rd
% Generated by roxygen2 (4.1.1): do not edit by hand % Please edit documentation in R/custom-dims.R \name{get_custom_dimension} \alias{get_custom_dimension} \title{Gets a custom dimension to which the user has access to} \usage{ get_custom_dimension(account.id, webproperty.id, dimension.id, token) } \arguments{ \item{a...
company<-read.csv("F:/Excelr/Assignments/dataset/decision tree/Company_Data.csv") library(C50) View(company) str(company) str(company) summary(company) sum(is.na(company)) High <- ifelse(company$Sales <= 8, "No", "Yes") company_1 <- data.frame(company, High) head(company_1) summary(company_1) str(compa...
/company.R
no_license
SaeeshaPednekar/Random-Forest
R
false
false
4,387
r
company<-read.csv("F:/Excelr/Assignments/dataset/decision tree/Company_Data.csv") library(C50) View(company) str(company) str(company) summary(company) sum(is.na(company)) High <- ifelse(company$Sales <= 8, "No", "Yes") company_1 <- data.frame(company, High) head(company_1) summary(company_1) str(compa...
#' Apply formatting to data.frame content #' @export format_data <- function(d, colFormats=NULL, typeFormats=NULL, useOptions=TRUE, na.rm=getOption("tblr.na.rm",TRUE)){ assign("fd", d) if(useOptions){ default_typeFormats <- getOption("tblr.typeFormats") default_colFormats <- getOption("tblr.col...
/R/tbl.R
no_license
mhpedersen/tblr
R
false
false
11,997
r
#' Apply formatting to data.frame content #' @export format_data <- function(d, colFormats=NULL, typeFormats=NULL, useOptions=TRUE, na.rm=getOption("tblr.na.rm",TRUE)){ assign("fd", d) if(useOptions){ default_typeFormats <- getOption("tblr.typeFormats") default_colFormats <- getOption("tblr.col...
context("resample") test_that("resample", { rin1 = makeResampleInstance(makeResampleDesc("Bootstrap", iters = 4), task = multiclass.task) rin2 = makeResampleInstance(makeResampleDesc("CV", iters = 7), task = multiclass.task) rin3 = makeResampleInstance(makeResampleDesc("Subsample", iters = 2), task = multiclass....
/tests/testthat/test_base_resample.R
no_license
HeidiSeibold/mlr
R
false
false
6,825
r
context("resample") test_that("resample", { rin1 = makeResampleInstance(makeResampleDesc("Bootstrap", iters = 4), task = multiclass.task) rin2 = makeResampleInstance(makeResampleDesc("CV", iters = 7), task = multiclass.task) rin3 = makeResampleInstance(makeResampleDesc("Subsample", iters = 2), task = multiclass....
heat_par <- function(ncat=10, beta.param=0.3){ # Defines classes for thermodynamic integration. # For details of the method see Xie et al 2011 Sys Bio. # # Args: # ncategories: number of classes that will be used in thermodynamic integration. # beta.param: parameter describing the shape of a beta distributio...
/R/utils.R
no_license
theogab/bite
R
false
false
586
r
heat_par <- function(ncat=10, beta.param=0.3){ # Defines classes for thermodynamic integration. # For details of the method see Xie et al 2011 Sys Bio. # # Args: # ncategories: number of classes that will be used in thermodynamic integration. # beta.param: parameter describing the shape of a beta distributio...
# Performs preprocessing of categorical (multiple) fields, namely: # 1) Reassigning values as specified in data coding file # 2) Generating binary variable for each category in field, restricting to correct set of participants as specified # in CAT_MULT_INDICATOR_FIELDS field of variable info file (either NO_NAN, ALL o...
/WAS/testCatMultiple.r
permissive
ericdunipace/PHESANT
R
false
false
6,962
r
# Performs preprocessing of categorical (multiple) fields, namely: # 1) Reassigning values as specified in data coding file # 2) Generating binary variable for each category in field, restricting to correct set of participants as specified # in CAT_MULT_INDICATOR_FIELDS field of variable info file (either NO_NAN, ALL o...
# Copyright Syncfusion Inc. 2001 - 2016. All rights reserved. # Use of this code is subject to the terms of our license. # A copy of the current license can be obtained at any time by e-mailing # licensing@syncfusion.com. Any infringement will be prosecuted under # applicable laws. # If you are not familiar with R y...
/common/Analytics/Multinomial Regression/Iris/Model/Iris.R
no_license
syncfusion/file-formats-windows-forms-demos
R
false
false
3,630
r
# Copyright Syncfusion Inc. 2001 - 2016. All rights reserved. # Use of this code is subject to the terms of our license. # A copy of the current license can be obtained at any time by e-mailing # licensing@syncfusion.com. Any infringement will be prosecuted under # applicable laws. # If you are not familiar with R y...
lagger <- function(data, by.var, lag.vars, num.lags, direction, freq = "daily") { if(class(data$date) != "Date"){ cat("date is not in Date format. No lagging operations performed.") retdat = NULL } if(class(data$date) == "Date"){ data$year = format(data$date, "%Y") data$month = format(data$...
/R/lagger.R
no_license
cran/tonymisc
R
false
false
1,978
r
lagger <- function(data, by.var, lag.vars, num.lags, direction, freq = "daily") { if(class(data$date) != "Date"){ cat("date is not in Date format. No lagging operations performed.") retdat = NULL } if(class(data$date) == "Date"){ data$year = format(data$date, "%Y") data$month = format(data$...
# File: server.R # Description: Data process for the Shiny app. # Author: Miguel Ángel García # Course: Coursera - Data Science Specialization - Final Project # Inits libraries needed require(shiny) require(quanteda) getPhraseAndWord <- function(text) { currentWord <- tolower(tail(unlist(strsplit(clean...
/server.R
no_license
miguel-angel-garcia/final-project
R
false
false
4,178
r
# File: server.R # Description: Data process for the Shiny app. # Author: Miguel Ángel García # Course: Coursera - Data Science Specialization - Final Project # Inits libraries needed require(shiny) require(quanteda) getPhraseAndWord <- function(text) { currentWord <- tolower(tail(unlist(strsplit(clean...
library(zoo) library(xts) library(PerformanceAnalytics) library(quantmod) asset_returns <- edhec rp <- readRDS("./data/rp_fi_lo_ret.rds") single_optimization <- function(asset_returns) { # Run a single period optimization using random portfolios as the optimization method opt <- optimize.portfolio(R = asset_r...
/applied_finance/intermediate_portfolio_analysis/2_portfolio_optimization_workflow/2_2_running_optimization.R
no_license
printfCRLF/rr
R
false
false
1,006
r
library(zoo) library(xts) library(PerformanceAnalytics) library(quantmod) asset_returns <- edhec rp <- readRDS("./data/rp_fi_lo_ret.rds") single_optimization <- function(asset_returns) { # Run a single period optimization using random portfolios as the optimization method opt <- optimize.portfolio(R = asset_r...
library(ape) library(tidyr) #set working directory to a location that has this gff file and the RNAseq results files setwd() #Load in the gff file GFF_table_Cvirginica <- read.gff("GCF_002022765.2_C_virginica-3.0_genomic.gff") #subset and keep mRNA sequences GFF_table_Cvirginica_mRNA <- subset(GFF_table_Cvirginica, ty...
/popstructureOutliers/data/gene_expression/RNAseq_mRNA_to_gene/mRNA_to_gene.R
permissive
amyzyck/OysterGenomeProject
R
false
false
8,420
r
library(ape) library(tidyr) #set working directory to a location that has this gff file and the RNAseq results files setwd() #Load in the gff file GFF_table_Cvirginica <- read.gff("GCF_002022765.2_C_virginica-3.0_genomic.gff") #subset and keep mRNA sequences GFF_table_Cvirginica_mRNA <- subset(GFF_table_Cvirginica, ty...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/plot_smd.R \name{plot_smd} \alias{plot_smd} \title{Function to produce plots of the distribution of the standardized mean difference} \usage{ plot_smd( d, df, lambda = NULL, sigma = NULL, smd_ci = c("goulet", "nct", "t", "z"), smd...
/man/plot_smd.Rd
no_license
cran/TOSTER
R
false
true
1,876
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/plot_smd.R \name{plot_smd} \alias{plot_smd} \title{Function to produce plots of the distribution of the standardized mean difference} \usage{ plot_smd( d, df, lambda = NULL, sigma = NULL, smd_ci = c("goulet", "nct", "t", "z"), smd...
## Functions that cache the inverse of a matrix . ## This function creates a special "matrix" object that can cache its inverse. makeCacheMatrix <- function(x = matrix()) { s <- NULL set <- function(y) { x <<- y s <<- NULL } get <- function() x setsolve <- function(solve) s <<- solve getsolve <- f...
/cachematrix.R
no_license
DenisMonets/ProgrammingAssignment2
R
false
false
903
r
## Functions that cache the inverse of a matrix . ## This function creates a special "matrix" object that can cache its inverse. makeCacheMatrix <- function(x = matrix()) { s <- NULL set <- function(y) { x <<- y s <<- NULL } get <- function() x setsolve <- function(solve) s <<- solve getsolve <- f...
################# # Code for Heffelfinger et al 2020: frontiers in E + E ################# # Load packages ################# library(lme4) library(glmmTMB) library(runjags) library(loo) library(survival) library(lubridate) library(caret) library(ranger) #library(buildmer) #library(ppmlasso) ######################...
/Levi_analysis_ch2_kts_v6.R
no_license
kevintshoemaker/desert_deer_rsf
R
false
false
71,572
r
################# # Code for Heffelfinger et al 2020: frontiers in E + E ################# # Load packages ################# library(lme4) library(glmmTMB) library(runjags) library(loo) library(survival) library(lubridate) library(caret) library(ranger) #library(buildmer) #library(ppmlasso) ######################...
library(BioInstaller) ### Name: docker.search ### Title: Search softwares docker infomation in BioInstaller docker ### database ### Aliases: docker.search ### ** Examples docker.search('bwa')
/data/genthat_extracted_code/BioInstaller/examples/docker.search.Rd.R
no_license
surayaaramli/typeRrh
R
false
false
201
r
library(BioInstaller) ### Name: docker.search ### Title: Search softwares docker infomation in BioInstaller docker ### database ### Aliases: docker.search ### ** Examples docker.search('bwa')
testlist <- list(m = NULL, repetitions = 0L, in_m = structure(c(2.31584307392677e+77, 9.53818252170339e+295, 1.19211398581285e+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/1615829089-test.R
no_license
akhikolla/updatedatatype-list2
R
false
false
361
r
testlist <- list(m = NULL, repetitions = 0L, in_m = structure(c(2.31584307392677e+77, 9.53818252170339e+295, 1.19211398581285e+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_...
# libraries library(tidyverse) library(vegan) library(mobr) # data cover <- read.csv("~/GRP GAZP Dropbox/Emma Ladouceur/_Projects/CCRScale/E14 _133/e014_e133_cleaned_1983-2016.csv",header=T,fill=TRUE,sep=",",na.strings=c(""," ","NA","NA ","na","NULL")) colnames(cover) head(cover) # Exp E14 & E133 cover %>% distinc...
/1_Data_wrangle.R
no_license
emma-ladouceur/CCRScale
R
false
false
10,283
r
# libraries library(tidyverse) library(vegan) library(mobr) # data cover <- read.csv("~/GRP GAZP Dropbox/Emma Ladouceur/_Projects/CCRScale/E14 _133/e014_e133_cleaned_1983-2016.csv",header=T,fill=TRUE,sep=",",na.strings=c(""," ","NA","NA ","na","NULL")) colnames(cover) head(cover) # Exp E14 & E133 cover %>% distinc...
/R Code/180412.r
no_license
Kim-Ayeong/Computational_Statistics2_with_R
R
false
false
1,092
r
# Venezuela National Parks interactive map tile<-'https://{s}.tile.opentopomap.org/{z}/{x}/{y}.png' ven_np_map <- ven_np_df %>% leaflet() %>% # Add a base layer addTiles(tile) %>% # add markers addAwesomeMarkers( # add popup with images and variables as text popup = paste(popupImage(np_img,...
/R/Data web products/Venezuela_National_parks/coding/np_map.R
no_license
CDopazo/Project_portfolio
R
false
false
618
r
# Venezuela National Parks interactive map tile<-'https://{s}.tile.opentopomap.org/{z}/{x}/{y}.png' ven_np_map <- ven_np_df %>% leaflet() %>% # Add a base layer addTiles(tile) %>% # add markers addAwesomeMarkers( # add popup with images and variables as text popup = paste(popupImage(np_img,...
# 관심군인 근로시간이 적은 군집 추출 indexcluster <- clu_best$cluster %in% c(3,4) #관심있는 군집 3, 4번(저근로군)을 의사결정나무를 통해 분류분석을 하기 위해 불러오기 df_Cluster <- df[indexcluster,] #Attribute 중 ID가 의사결정나무의 품질을 떨어뜨리기에 제외 dim(df_Cluster) #불러온 데이터가 잘 불러져 왔는지 (행X열)을 통해 확인 table(df_Cluster$mh_PHQ_S) #불러온 데이터 내 PHQ점수의 빈도 확인 # 관심있는 변수들에 대한 무응답을 NA처리 ...
/DM_DepressionAdults_4_data_preprocessing_for_DT.R
no_license
hongshi97/DM-Depression-in-Low-Working-Adult
R
false
false
30,619
r
# 관심군인 근로시간이 적은 군집 추출 indexcluster <- clu_best$cluster %in% c(3,4) #관심있는 군집 3, 4번(저근로군)을 의사결정나무를 통해 분류분석을 하기 위해 불러오기 df_Cluster <- df[indexcluster,] #Attribute 중 ID가 의사결정나무의 품질을 떨어뜨리기에 제외 dim(df_Cluster) #불러온 데이터가 잘 불러져 왔는지 (행X열)을 통해 확인 table(df_Cluster$mh_PHQ_S) #불러온 데이터 내 PHQ점수의 빈도 확인 # 관심있는 변수들에 대한 무응답을 NA처리 ...
test.text.vector <- c( "Can we have ice cream, please?", "Can we go to the lake on Saturday?", "Planets are full of mass", "Dinosaurs are full of other dinosaurs", "Obelisks are full of stars", "Planets are full of mass", "When in the course of human events, it becomes necessary for one peop...
/testdata.R
no_license
jleete97/data_science_capstone
R
false
false
887
r
test.text.vector <- c( "Can we have ice cream, please?", "Can we go to the lake on Saturday?", "Planets are full of mass", "Dinosaurs are full of other dinosaurs", "Obelisks are full of stars", "Planets are full of mass", "When in the course of human events, it becomes necessary for one peop...
library(ISLR) set.seed(1) dim(Wage) lmCrossVal <- function(data,x,y,modelfunc,cv,deg) { cv.vec <- sample(1:cv, nrow(data), replace=TRUE) results <- c() for(i in 1:cv){ funcstr <- sprintf("%s ~ poly(%s, %s)", y, x, deg) model <- modelfunc(funcstr, data[cv.vec != i,]) predictions <- predict(mod...
/ch7.r
no_license
rforgione/ISLR
R
false
false
823
r
library(ISLR) set.seed(1) dim(Wage) lmCrossVal <- function(data,x,y,modelfunc,cv,deg) { cv.vec <- sample(1:cv, nrow(data), replace=TRUE) results <- c() for(i in 1:cv){ funcstr <- sprintf("%s ~ poly(%s, %s)", y, x, deg) model <- modelfunc(funcstr, data[cv.vec != i,]) predictions <- predict(mod...
# # # # # # # # # # # # # # # # # # # # # # This script: # imports processed data # filters out people who are excluded from the main analysis # outputs inclusion/exclusions flowchart data # # # # # # # # # # # # # # # # # # # # # ## Import libraries ---- library('tidyverse') library('lubridate') library('here') libr...
/analysis/coverage/data_selection_coverage.R
permissive
opensafely/ckd-coverage-ve
R
false
false
5,969
r
# # # # # # # # # # # # # # # # # # # # # # This script: # imports processed data # filters out people who are excluded from the main analysis # outputs inclusion/exclusions flowchart data # # # # # # # # # # # # # # # # # # # # # ## Import libraries ---- library('tidyverse') library('lubridate') library('here') libr...
library(shiny) library(shiny.semantic) shinyApp( ui = semanticPage( selectInput("variable", "Variable:", c("Cylinders" = "cyl", "Transmission" = "am", "Gears" = "gear"), selectize = TRUE, multiple = TRUE, width = "300px"), actionButton("trig", "Cli", icon =...
/examples/shiny_syntax/selectInput.R
permissive
Appsilon/shiny.semantic
R
false
false
993
r
library(shiny) library(shiny.semantic) shinyApp( ui = semanticPage( selectInput("variable", "Variable:", c("Cylinders" = "cyl", "Transmission" = "am", "Gears" = "gear"), selectize = TRUE, multiple = TRUE, width = "300px"), actionButton("trig", "Cli", icon =...
#========================================= #---------- packages used ------------ #========================================= library(dplyr) library(lubridate) library(tidyverse) library(ggplot2) library(sqldf) library(chron) library(data.table) library(bda) #======================================...
/function_code.R
no_license
yliao2/caps-data-code
R
false
false
12,797
r
#========================================= #---------- packages used ------------ #========================================= library(dplyr) library(lubridate) library(tidyverse) library(ggplot2) library(sqldf) library(chron) library(data.table) library(bda) #======================================...
download.file("http://d396qusza40orc.cloudfront.net/exdata%2Fdata%2FNEI_data.zip","FNEI_data.zip") unzip("FNEI_data.zip") NEI <- readRDS("summarySCC_PM25.rds") SCC <- readRDS("Source_Classification_Code.rds") data <- merge(NEI, SCC, by="SCC") data <- data[order(data$year), ] data <- subset(data, select=c("year"...
/DataScience/4_ExploratoryDataAnalysis/peerAssessment/CourseProject_2/plot1.R
no_license
xhuljana1/CourseraCourses
R
false
false
795
r
download.file("http://d396qusza40orc.cloudfront.net/exdata%2Fdata%2FNEI_data.zip","FNEI_data.zip") unzip("FNEI_data.zip") NEI <- readRDS("summarySCC_PM25.rds") SCC <- readRDS("Source_Classification_Code.rds") data <- merge(NEI, SCC, by="SCC") data <- data[order(data$year), ] data <- subset(data, select=c("year"...
################################################################### # Complexity masures for regression problemas # # Proposed by Ana Carolina Lorena and Ivan Costa # # Implemented by Aron Ifanger Maciel and Ana Carolina Lorena # ################################################...
/measures.R
no_license
LuizHNLorena/BinderTestR
R
false
false
21,043
r
################################################################### # Complexity masures for regression problemas # # Proposed by Ana Carolina Lorena and Ivan Costa # # Implemented by Aron Ifanger Maciel and Ana Carolina Lorena # ################################################...
# FUnctions to plot some of the results from the VIT models # using the BUGS output # Plot the baseline hazard plot_baseline <- function(model, MainLab, offset, LWD, Ylim, Xlim, legendflag, Ylab, FmoTixs){ if(missing(MainLab)) {MainLab <- " "} if(missing(LWD)) {LWD <- 1} if(missing(Ylab)) {"Total hazard h(t)...
/Analysis/plot_VITresults_fxns.R
no_license
pcross-usgs/CauseSpecificSurvival
R
false
false
15,300
r
# FUnctions to plot some of the results from the VIT models # using the BUGS output # Plot the baseline hazard plot_baseline <- function(model, MainLab, offset, LWD, Ylim, Xlim, legendflag, Ylab, FmoTixs){ if(missing(MainLab)) {MainLab <- " "} if(missing(LWD)) {LWD <- 1} if(missing(Ylab)) {"Total hazard h(t)...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/PolynomF.R \name{plot.polylist} \alias{plot.polylist} \alias{plot.polynom} \alias{lines.polynom} \alias{points.polynom} \alias{lines.polylist} \alias{points.polylist} \title{Plot method for polynomials} \usage{ \method{plot}{polylist}( x, ...
/PolynomF/man/plot.polynom.Rd
no_license
akhikolla/TestedPackages-NoIssues
R
false
true
1,778
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/PolynomF.R \name{plot.polylist} \alias{plot.polylist} \alias{plot.polynom} \alias{lines.polynom} \alias{points.polynom} \alias{lines.polylist} \alias{points.polylist} \title{Plot method for polynomials} \usage{ \method{plot}{polylist}( x, ...
#' Generate List of Exploration \code{search_term} Function Calls #' #' The task of determining the regexes used to feed a \code{term_count} object's #' \code{term.list} requires careful exploration of term use in context. This #' function generates a list of function calls for \code{search_term} with a #' user prede...
/R/probe_list.R
no_license
data-steve/termco
R
false
false
2,038
r
#' Generate List of Exploration \code{search_term} Function Calls #' #' The task of determining the regexes used to feed a \code{term_count} object's #' \code{term.list} requires careful exploration of term use in context. This #' function generates a list of function calls for \code{search_term} with a #' user prede...
rm(list = ls()) setwd("~/Documents/GDB/UNLU/BOSQUE/Analisis/SMI/") # # m <- data.frame(id=1:180, # image_1=paste0("pch_",1:180,".png"), # image_2=paste0("pch_",1:180,"LR.png"), # image_3=paste0("pch_",1:180,"HD.png")) ########### list.files(pattern = "HD.png", path...
/code/manifiest.R
no_license
angelini75/Bosques
R
false
false
1,297
r
rm(list = ls()) setwd("~/Documents/GDB/UNLU/BOSQUE/Analisis/SMI/") # # m <- data.frame(id=1:180, # image_1=paste0("pch_",1:180,".png"), # image_2=paste0("pch_",1:180,"LR.png"), # image_3=paste0("pch_",1:180,"HD.png")) ########### list.files(pattern = "HD.png", path...
\name{NEWS} \title{dbarts News} \encoding{UTF-8} section{CHANGES IN VERSION 0.9-19}{ \subsection{USER-VISIBLE CHANGES}{ \itemize{ \item \code{varcount} for \code{bart} fits now has dimnames set. } } \subsection{BUG FIXES}{ \itemize{ \item Parallelization for \code{rbart} now creates the co...
/inst/NEWS.Rd
no_license
ZhilinJin/dbarts
R
false
false
12,694
rd
\name{NEWS} \title{dbarts News} \encoding{UTF-8} section{CHANGES IN VERSION 0.9-19}{ \subsection{USER-VISIBLE CHANGES}{ \itemize{ \item \code{varcount} for \code{bart} fits now has dimnames set. } } \subsection{BUG FIXES}{ \itemize{ \item Parallelization for \code{rbart} now creates the co...
library("ggplot2") library("forecast") library("tseries") myData <- read.csv(file = "C:\\Users\\wqu\\Desktop\\new.csv", header = TRUE, sep=",") myData$Date <- as.POSIXct(myData$Date, format="%Y-%m-%d %I-%p") ggplot(myData, aes(Date, Close)) + geom_line(na.rm=TRUE)
/Preprocessing/PA_project_Java/r.R
no_license
wqu1995/PA_Project
R
false
false
271
r
library("ggplot2") library("forecast") library("tseries") myData <- read.csv(file = "C:\\Users\\wqu\\Desktop\\new.csv", header = TRUE, sep=",") myData$Date <- as.POSIXct(myData$Date, format="%Y-%m-%d %I-%p") ggplot(myData, aes(Date, Close)) + geom_line(na.rm=TRUE)
library(data.table) # setup date formatting setClass("myDate") setAs("character", "myDate", function(from) as.Date(from, format="%d/%m/%Y")) # grab full file, separated by ';' and interpret '?' as NAs rawDF <- read.table("./data/household_power_consumption.txt", sep = ";", header=TRUE, na.strings="?", colClasses=c(D...
/plot3.R
no_license
agartzke/ExData_Plotting1
R
false
false
1,082
r
library(data.table) # setup date formatting setClass("myDate") setAs("character", "myDate", function(from) as.Date(from, format="%d/%m/%Y")) # grab full file, separated by ';' and interpret '?' as NAs rawDF <- read.table("./data/household_power_consumption.txt", sep = ";", header=TRUE, na.strings="?", colClasses=c(D...
/chloss3.R
no_license
hying99/teachers
R
false
false
4,067
r
#' Trip Speed #' #' Calculates speed of a cycling trip, based on following parameters:\cr #' 1. age: With two categories 16-59 and 60+ year olds\cr #' 2. gender: Male or Female\cr #' 3. bike_type: A boolean variable whether it's a pedal bike (0) or an ebike (1)\cr #' #' #' @param age Individual age: 16.59 or 60 plus #...
/R/functions.R
no_license
ITHIM/scenic
R
false
false
3,215
r
#' Trip Speed #' #' Calculates speed of a cycling trip, based on following parameters:\cr #' 1. age: With two categories 16-59 and 60+ year olds\cr #' 2. gender: Male or Female\cr #' 3. bike_type: A boolean variable whether it's a pedal bike (0) or an ebike (1)\cr #' #' #' @param age Individual age: 16.59 or 60 plus #...
f_solve <- function(one, thetitle, useexp, THELEFT, THERIGHT){ # EXPLANATION ------------------------------------------------------------- if (useexp){ it <- t_solve#_exp it <- # str_replace( # it, # "THEEXPLANATION", # wh...
/_f_solve.R
no_license
stenhaug/itempool-tst
R
false
false
2,089
r
f_solve <- function(one, thetitle, useexp, THELEFT, THERIGHT){ # EXPLANATION ------------------------------------------------------------- if (useexp){ it <- t_solve#_exp it <- # str_replace( # it, # "THEEXPLANATION", # wh...
sel.edit <- function (y, ypred, wgt=rep(1,nrow(as.matrix(y ))), tot=colSums(ypred * wgt), t.sel=0.01) { memo.y <- y y=as.matrix(y) id=1:nrow(y) ypred=as.matrix(ypred) n <- nrow(y) p <- ncol(y) if (ncol(ypred) > p) stop("Response variables (y) and their predicted values (y...
/R/sel.edit.r
no_license
cran/SeleMix
R
false
false
2,770
r
sel.edit <- function (y, ypred, wgt=rep(1,nrow(as.matrix(y ))), tot=colSums(ypred * wgt), t.sel=0.01) { memo.y <- y y=as.matrix(y) id=1:nrow(y) ypred=as.matrix(ypred) n <- nrow(y) p <- ncol(y) if (ncol(ypred) > p) stop("Response variables (y) and their predicted values (y...
rm(list=ls()) setwd('~/Documents/a-mmm-lab/a-ml/data') c.data = read.csv('6-beta.csv', header=T) library(kernlab) my.scale=function(df) { for (i in 1:ncol(df)) { new.col = (df[,i] - mean(df[,i])) / sd(df[,i]) if (i == 1) { scaled.df = data.frame(new.col) } else { scaled.df = da...
/r/old-testing/svr-testing/tuning-ksvr-dadN.R
no_license
nathanwilk7/mmm-lab-features-ml
R
false
false
3,655
r
rm(list=ls()) setwd('~/Documents/a-mmm-lab/a-ml/data') c.data = read.csv('6-beta.csv', header=T) library(kernlab) my.scale=function(df) { for (i in 1:ncol(df)) { new.col = (df[,i] - mean(df[,i])) / sd(df[,i]) if (i == 1) { scaled.df = data.frame(new.col) } else { scaled.df = da...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/progress.R \name{progress} \alias{progress} \title{progress bars} \description{ progress bars } \details{ pass \code{httr::progress()} to \code{progress} param in \link{HttpClient}, which pulls out relevant info to pass down to \pkg{curl} if...
/man/progress.Rd
permissive
ropensci/crul
R
false
true
440
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/progress.R \name{progress} \alias{progress} \title{progress bars} \description{ progress bars } \details{ pass \code{httr::progress()} to \code{progress} param in \link{HttpClient}, which pulls out relevant info to pass down to \pkg{curl} if...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/reproduction.R \name{reproduction} \alias{reproduction} \title{reproduction} \usage{ reproduction(species_list = NULL, fields = NULL, query = NULL, limit = 200, server = getOption("FISHBASE_API", FISHBASE_API), ...) } \arguments{ \item{spec...
/man/reproduction.Rd
no_license
GapData/rfishbase
R
false
true
1,394
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/reproduction.R \name{reproduction} \alias{reproduction} \title{reproduction} \usage{ reproduction(species_list = NULL, fields = NULL, query = NULL, limit = 200, server = getOption("FISHBASE_API", FISHBASE_API), ...) } \arguments{ \item{spec...
context("RsecFluidigm") test_that("saved rsecFluidigm is still valid object", { data(rsecFluidigm) expect_true(validObject(rsecFluidigm)) #checks that current code will still recreate same basic rsecFluidigm # takes a bit of time, so skip on bioc, just want on travis so get alert # that need to deal...
/tests/testthat/test-rsecFluidigm.R
no_license
kant/clusterExperiment
R
false
false
796
r
context("RsecFluidigm") test_that("saved rsecFluidigm is still valid object", { data(rsecFluidigm) expect_true(validObject(rsecFluidigm)) #checks that current code will still recreate same basic rsecFluidigm # takes a bit of time, so skip on bioc, just want on travis so get alert # that need to deal...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/bref.R \name{dictionary_bref_players} \alias{dictionary_bref_players} \title{Basketball Reference player dictionary} \usage{ dictionary_bref_players() } \value{ a `tibble` } \description{ Basketball Reference player dictionary } \examples{ di...
/man/dictionary_bref_players.Rd
no_license
abresler/nbastatR
R
false
true
894
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/bref.R \name{dictionary_bref_players} \alias{dictionary_bref_players} \title{Basketball Reference player dictionary} \usage{ dictionary_bref_players() } \value{ a `tibble` } \description{ Basketball Reference player dictionary } \examples{ di...
## Testing `taxmap` class library(taxa) library(testthat) context("taxmap") notoryctidae <- taxon( name = taxon_name("Notoryctidae"), rank = taxon_rank("family"), id = taxon_id(4479) ) notoryctes <- taxon( name = taxon_name("Notoryctes"), rank = taxon_rank("genus"), id = taxon_id(4544) ) typhlops <- tax...
/tests/testthat/test--taxmap.R
permissive
xpingli/taxa
R
false
false
23,947
r
## Testing `taxmap` class library(taxa) library(testthat) context("taxmap") notoryctidae <- taxon( name = taxon_name("Notoryctidae"), rank = taxon_rank("family"), id = taxon_id(4479) ) notoryctes <- taxon( name = taxon_name("Notoryctes"), rank = taxon_rank("genus"), id = taxon_id(4544) ) typhlops <- tax...
fitData.sweep <- function(v0=c(.6, .55, .5, .45, .4, .35), step=.001, verbose=TRUE, yrs=1986, wtsVar=NULL, fits=5, takeMean=FALSE, args=list(df.y=cps.x.y, y.varNames=c("x", "y", "fit"), df.x=cps.x, x.varNames=c("x", "pFreq.x", "medW.x"), y...
/parSweep.R
no_license
JohnBradford/inequality
R
false
false
6,024
r
fitData.sweep <- function(v0=c(.6, .55, .5, .45, .4, .35), step=.001, verbose=TRUE, yrs=1986, wtsVar=NULL, fits=5, takeMean=FALSE, args=list(df.y=cps.x.y, y.varNames=c("x", "y", "fit"), df.x=cps.x, x.varNames=c("x", "pFreq.x", "medW.x"), y...
source("~/T2T-Epigenetics/utils/ilee_plot_utils.R") source("~/T2T-Epigenetics/utils/methylation_R_utils.R") library(tidyverse) library(cowplot) figs="/kyber/Data/Nanopore/Analysis/gmoney/CHM13/v1.0_final_assembly/figures" dat="/kyber/Data/Nanopore/Analysis/gmoney/CHM13/v1.0_final_assembly" list=c("chr1","chr2", "chr...
/panelPlots/Centromere_PanelPlots.R
no_license
Musketeer-D/T2T-Epigenetics
R
false
false
3,417
r
source("~/T2T-Epigenetics/utils/ilee_plot_utils.R") source("~/T2T-Epigenetics/utils/methylation_R_utils.R") library(tidyverse) library(cowplot) figs="/kyber/Data/Nanopore/Analysis/gmoney/CHM13/v1.0_final_assembly/figures" dat="/kyber/Data/Nanopore/Analysis/gmoney/CHM13/v1.0_final_assembly" list=c("chr1","chr2", "chr...
\name{get.mod} \alias{get.mod} \title{Copy objects between R environments} \usage{ get.mod(modelname = ls( FlexParamCurve:::FPCEnv, pattern=".lis" ), from.envir = FlexParamCurve:::FPCEnv, to.envir = .GlobalEnv, write.mod = FALSE, silent = FALSE) } \arguments{ \item{modelname}{a charac...
/man/get.mod.Rd
no_license
cran/FlexParamCurve
R
false
false
3,123
rd
\name{get.mod} \alias{get.mod} \title{Copy objects between R environments} \usage{ get.mod(modelname = ls( FlexParamCurve:::FPCEnv, pattern=".lis" ), from.envir = FlexParamCurve:::FPCEnv, to.envir = .GlobalEnv, write.mod = FALSE, silent = FALSE) } \arguments{ \item{modelname}{a charac...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/FetchTCGA.R \name{get450K} \alias{get450K} \title{get450K to download HM40K DNA methylation data for certain cancer types from TCGA website. @description get450K is a function to download latest version of HM450K DNA methylation for all...
/man/get450K.Rd
no_license
leameunier/ELMER
R
false
true
1,162
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/FetchTCGA.R \name{get450K} \alias{get450K} \title{get450K to download HM40K DNA methylation data for certain cancer types from TCGA website. @description get450K is a function to download latest version of HM450K DNA methylation for all...
###################################################### ## ## Function to create a csv containing a the list of potential ## comparable stocks for each nei stock in a country ## ###################################################### # # Steps: # 1) Subset country's nei stocks from FAO # 2) Determine taxonomic level o...
/scripts/Script Library/ComparisonStockFinder.R
no_license
kmillage/Global-Fishery-Potential
R
false
false
5,615
r
###################################################### ## ## Function to create a csv containing a the list of potential ## comparable stocks for each nei stock in a country ## ###################################################### # # Steps: # 1) Subset country's nei stocks from FAO # 2) Determine taxonomic level o...
## This R script creates a matrix object and computes, caches, and retrieves the inverse ## of the matrix. ## This function creates a special "matrix" object that can cache its inverse. makeCacheMatrix <- function(x = matrix()) { m <- NULL set <- function(y) { x <<- y m...
/cachematrix.R
no_license
jsangillo/ProgrammingAssignment2
R
false
false
1,041
r
## This R script creates a matrix object and computes, caches, and retrieves the inverse ## of the matrix. ## This function creates a special "matrix" object that can cache its inverse. makeCacheMatrix <- function(x = matrix()) { m <- NULL set <- function(y) { x <<- y m...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/RcppExports.R \name{gz_fseek} \alias{gz_fseek} \title{Sets the starting position for the next \code{gz_read()} or \code{gz_write()}} \usage{ gz_fseek(gzfile, offset, from) } \arguments{ \item{gzfile}{file handle} \item{offset}{represents a n...
/man/gz_fseek.Rd
no_license
hrbrmstr/warc
R
false
true
569
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/RcppExports.R \name{gz_fseek} \alias{gz_fseek} \title{Sets the starting position for the next \code{gz_read()} or \code{gz_write()}} \usage{ gz_fseek(gzfile, offset, from) } \arguments{ \item{gzfile}{file handle} \item{offset}{represents a n...
source("deps.R") server <- function(input, output, session) { proxy = dataTableProxy("diagnoseTable") observeEvent(input$clear_btton, { updateTextInput(session, "input_heart", value = "") updateTextInput(session, "input_sex", value = "") updateTextInput(session, "input_health", value = "") u...
/project/hrv/server.R
no_license
guitarmind/natt
R
false
false
4,826
r
source("deps.R") server <- function(input, output, session) { proxy = dataTableProxy("diagnoseTable") observeEvent(input$clear_btton, { updateTextInput(session, "input_heart", value = "") updateTextInput(session, "input_sex", value = "") updateTextInput(session, "input_health", value = "") u...
library(rvest) library(dplyr) library(BDWPkg) ## 4th Scraper, run after fullGamesList.R, although it is independent. ## Read in list of tournament match pages and links tournamentMH <- read.csv("tournamentMatch.csv", stringsAsFactors = FALSE) ## Remove tournaments with mostly missing information tournamentMH <- tou...
/4-esportapediaMHScrape.R
no_license
Data8021/LOLScrape
R
false
false
13,791
r
library(rvest) library(dplyr) library(BDWPkg) ## 4th Scraper, run after fullGamesList.R, although it is independent. ## Read in list of tournament match pages and links tournamentMH <- read.csv("tournamentMatch.csv", stringsAsFactors = FALSE) ## Remove tournaments with mostly missing information tournamentMH <- tou...
# statistic calculation stat_sub_1 = statistics_function(d1_subset$value, d1_subset$timestamp) stat_sub_2 = statistics_function(d2_subset$value, d2_subset$timestamp) stat_d1 = statistics_function(d1$value, d1$timestamp) stat_d2 = statistics_function(d2$value, d2$timestamp) stat = rbind(stat_sub_1, stat_sub_2, stat_d1,...
/1_code/statistic_table.R
no_license
tarasevic-r/time-series
R
false
false
409
r
# statistic calculation stat_sub_1 = statistics_function(d1_subset$value, d1_subset$timestamp) stat_sub_2 = statistics_function(d2_subset$value, d2_subset$timestamp) stat_d1 = statistics_function(d1$value, d1$timestamp) stat_d2 = statistics_function(d2$value, d2$timestamp) stat = rbind(stat_sub_1, stat_sub_2, stat_d1,...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/io.R \name{f2_from_precomp} \alias{f2_from_precomp} \title{Read blocked f2 statistics from disk} \usage{ f2_from_precomp( dir, inds = NULL, pops = NULL, pops2 = NULL, afprod = FALSE, return_array = TRUE, apply_corr = TRUE, rem...
/man/f2_from_precomp.Rd
no_license
razb/admixtools
R
false
true
2,192
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/io.R \name{f2_from_precomp} \alias{f2_from_precomp} \title{Read blocked f2 statistics from disk} \usage{ f2_from_precomp( dir, inds = NULL, pops = NULL, pops2 = NULL, afprod = FALSE, return_array = TRUE, apply_corr = TRUE, rem...
# Script to load in expected phis and find top words for every topic args <- commandArgs(TRUE) fit.dir <- args[1] analysis.dir <- args[2] file.ave.params <- args[3] file.kept.word.stems <- args[4] n.get <- args[5] weight.phi <- as.numeric(args[6]) # Load in sorting function funct.dir <- "/n/home13/jbischof/reuters_pr...
/mmm_analysis_code/find_top_sem_cont_words.R
no_license
jbischof/HPC_model
R
false
false
2,520
r
# Script to load in expected phis and find top words for every topic args <- commandArgs(TRUE) fit.dir <- args[1] analysis.dir <- args[2] file.ave.params <- args[3] file.kept.word.stems <- args[4] n.get <- args[5] weight.phi <- as.numeric(args[6]) # Load in sorting function funct.dir <- "/n/home13/jbischof/reuters_pr...
Clicker for Netflix Repo
/readme.rd
no_license
dbklabs/clicker-for-netflix
R
false
false
25
rd
Clicker for Netflix Repo
## Análise da Equipe de Campo ## Fonte: Protocolos de TOI 20_03_18 # Chegando diretório getwd() install.packages("readxl") install.packages("plyr") install.packages("gmodels") install.packages("ggthemes") install.packages("corrplot") install.packages("corrgram") library(readxl) library(dplyr) library(gg...
/Exercícios/Análise explorarória equipe de campo.R
no_license
LuizAlmeida71/Exercicios
R
false
false
9,753
r
## Análise da Equipe de Campo ## Fonte: Protocolos de TOI 20_03_18 # Chegando diretório getwd() install.packages("readxl") install.packages("plyr") install.packages("gmodels") install.packages("ggthemes") install.packages("corrplot") install.packages("corrgram") library(readxl) library(dplyr) library(gg...
testlist <- list(latLongs = structure(c(0, 5.69529905969381e-304, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), .Dim = c(8L, 2L)), r = 0) result <- do.call(MGDrivE::calcCos,testlist) str(result)
/MGDrivE/inst/testfiles/calcCos/libFuzzer_calcCos/calcCos_valgrind_files/1612726819-test.R
no_license
akhikolla/updatedatatype-list2
R
false
false
192
r
testlist <- list(latLongs = structure(c(0, 5.69529905969381e-304, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), .Dim = c(8L, 2L)), r = 0) result <- do.call(MGDrivE::calcCos,testlist) str(result)
library(shiny) shinyUI(pageWithSidebar( headerPanel("Predict Vehicle 1/4 Mile Time"), sidebarPanel( h3('Instructions:'), h5('1. Select desired HP and Weight values.'), h5('2. Press Submit.'), sliderInput('hp', 'Gross HP',value = 150, min =...
/proj_app/ui.R
no_license
mykelagrene/Rdataproducts
R
false
false
1,502
r
library(shiny) shinyUI(pageWithSidebar( headerPanel("Predict Vehicle 1/4 Mile Time"), sidebarPanel( h3('Instructions:'), h5('1. Select desired HP and Weight values.'), h5('2. Press Submit.'), sliderInput('hp', 'Gross HP',value = 150, min =...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/plot_scal_est.R \name{plot_scal_est} \alias{plot_scal_est} \title{plot_scal_est} \usage{ plot_scal_est(scal_est, abundance = TRUE, YEAR) } \arguments{ \item{YEAR}{} } \description{ Plot scallop abundance (abundance = TRUE) or biomass (abundan...
/man/plot_scal_est.Rd
permissive
commfish/scallopr
R
false
true
507
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/plot_scal_est.R \name{plot_scal_est} \alias{plot_scal_est} \title{plot_scal_est} \usage{ plot_scal_est(scal_est, abundance = TRUE, YEAR) } \arguments{ \item{YEAR}{} } \description{ Plot scallop abundance (abundance = TRUE) or biomass (abundan...
confint(t.test(~Flight179, data=Flight179))
/inst/snippets/Example6.13c.R
no_license
stacyderuiter/Lock5withR
R
false
false
45
r
confint(t.test(~Flight179, data=Flight179))
site <- "https://comic.naver.com/genre/bestChallenge.nhn?&page=" navercomic <- NULL i <- 1 repeat{ url <- paste(site, i, sep="") text <- read_html(url, encoding="UTF-8") #만화 제목 nodes <- html_nodes(text,"div.challengeInfo > h6 > a") comicName <- html_text(nodes) comicName <- html_text(nodes, trim=TRUE) #만화 요약 nodes...
/R_training/실습제출/서승우/19.10.29/navercomic.R
no_license
BaeYS-marketing/R
R
false
false
746
r
site <- "https://comic.naver.com/genre/bestChallenge.nhn?&page=" navercomic <- NULL i <- 1 repeat{ url <- paste(site, i, sep="") text <- read_html(url, encoding="UTF-8") #만화 제목 nodes <- html_nodes(text,"div.challengeInfo > h6 > a") comicName <- html_text(nodes) comicName <- html_text(nodes, trim=TRUE) #만화 요약 nodes...
=begin =メール送信時に「挨拶中にエラーが発生しました」というエラーが発生します メール送信時に「挨拶中にエラーが発生しました」というエラーが発生する場合、OP25Bによってブロックされている可能性があります。この場合、サーバが対応していれば、[アカウントのプロパティ]の((<[詳細]|URL:AccountDetail.html>))ページで[送信]の[ポート]を587にし、((<[ユーザ]|URL:AccountUser.html>))ページで必要に応じてSMTP認証を有効にすることで回避できる可能性があります。 =end
/docs/OutboundPort25Blocking.rd
permissive
snakamura/q3
R
false
false
632
rd
=begin =メール送信時に「挨拶中にエラーが発生しました」というエラーが発生します メール送信時に「挨拶中にエラーが発生しました」というエラーが発生する場合、OP25Bによってブロックされている可能性があります。この場合、サーバが対応していれば、[アカウントのプロパティ]の((<[詳細]|URL:AccountDetail.html>))ページで[送信]の[ポート]を587にし、((<[ユーザ]|URL:AccountUser.html>))ページで必要に応じてSMTP認証を有効にすることで回避できる可能性があります。 =end
#this function takes in a list of spikes (s), with burst info # digitizes spikes into 10ms bins (1 in bin if any spike, 0 otherwise) # then computes correlation btw ae above, below, to left and to right .local.corr<-function(s) { # store data plate.corr=list(plate.name=list(), local.cor=list()) #loop throug...
/IGM.MEA/R/local.corr.R
no_license
ingted/R-Examples
R
false
false
3,329
r
#this function takes in a list of spikes (s), with burst info # digitizes spikes into 10ms bins (1 in bin if any spike, 0 otherwise) # then computes correlation btw ae above, below, to left and to right .local.corr<-function(s) { # store data plate.corr=list(plate.name=list(), local.cor=list()) #loop throug...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/randomise.R \name{randomise} \alias{randomise} \alias{randomize} \title{Randomised group of items} \usage{ randomise( npackages, itemnames, ncomp = 3, availability = NULL, proportions = NULL, ... ) } \arguments{ \item{npackages}{a...
/man/randomise.Rd
permissive
AgrDataSci/ClimMobTools
R
false
true
2,155
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/randomise.R \name{randomise} \alias{randomise} \alias{randomize} \title{Randomised group of items} \usage{ randomise( npackages, itemnames, ncomp = 3, availability = NULL, proportions = NULL, ... ) } \arguments{ \item{npackages}{a...
# makeCacheMatrix creates a list containing a function to # 1. set the value of the matrix # 2. get the value of the matrix # 3. set the value of inverse of the matrix # 4. get the value of inverse of the matrix makeCacheMatrix <- function(matrixtest = matrix()) { mat <- NULL set1 <- function(y) { mat...
/cachematrix.r
no_license
eprovenzano/Datasciencecoursera
R
false
false
1,289
r
# makeCacheMatrix creates a list containing a function to # 1. set the value of the matrix # 2. get the value of the matrix # 3. set the value of inverse of the matrix # 4. get the value of inverse of the matrix makeCacheMatrix <- function(matrixtest = matrix()) { mat <- NULL set1 <- function(y) { mat...
## R programming - Programmng assignment 2 ## Practicing lexical scoping and superassignment operator ## Thierry Geiger - 25 Oct 2014 ## The first function, makeVector creates ## a list containing four functions to respectively ## 1) set the value of the matrix ## 2) get its value ## 3) set the value of the inverse ...
/cachematrix.R
no_license
thierrygeiger/ProgrammingAssignment2
R
false
false
1,458
r
## R programming - Programmng assignment 2 ## Practicing lexical scoping and superassignment operator ## Thierry Geiger - 25 Oct 2014 ## The first function, makeVector creates ## a list containing four functions to respectively ## 1) set the value of the matrix ## 2) get its value ## 3) set the value of the inverse ...
context("geom_timeline") ## TODO: Add more tests # capture_output() is useful here test_that("geom_timeline produces a plot without errors", { expect_failure(expect_error(ggplot(readRDS("eq_US_China_clean.rds"),ggplot2::aes(DATE))+geom_timeline(ggplot2::aes(colour = TOTAL_DEATHS, size = EQ_PRIMARY),xmindate=2000,x...
/tests/testthat/test-geom_timeline.R
no_license
leskin/earthquaketools
R
false
false
339
r
context("geom_timeline") ## TODO: Add more tests # capture_output() is useful here test_that("geom_timeline produces a plot without errors", { expect_failure(expect_error(ggplot(readRDS("eq_US_China_clean.rds"),ggplot2::aes(DATE))+geom_timeline(ggplot2::aes(colour = TOTAL_DEATHS, size = EQ_PRIMARY),xmindate=2000,x...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/ga_get_transactions.R \name{ga_get_transactions} \alias{ga_get_transactions} \title{GA Monthly linechart graphic - sessions} \usage{ ga_get_transactions(view_id, start_date, final_date, language = "es") } \arguments{ \item{language}{Choose a ...
/man/ga_get_transactions.Rd
no_license
OmarGonD/googleAnalyticsReports
R
false
true
789
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/ga_get_transactions.R \name{ga_get_transactions} \alias{ga_get_transactions} \title{GA Monthly linechart graphic - sessions} \usage{ ga_get_transactions(view_id, start_date, final_date, language = "es") } \arguments{ \item{language}{Choose a ...
library(ggplot2) library(dplyr) # args = commandArgs(trailingOnly=TRUE) # filename<-args[1] # outfile <- args[2] # # # data<-read.table(filename, header=T) # stopifnot(nrow(data)>1) #t <- data[1,5] #simulate data var_g<-3 var_c1<-1 var_c2<-1 M<-1000 N_1<-2 N_2<-3 lambda<-rnorm(n=M, mean=0, sd=sqrt(var_g)) s1_dist<-...
/scripts_for_ismb2019/sim_pred.R
no_license
jzhou1011/replication
R
false
false
6,893
r
library(ggplot2) library(dplyr) # args = commandArgs(trailingOnly=TRUE) # filename<-args[1] # outfile <- args[2] # # # data<-read.table(filename, header=T) # stopifnot(nrow(data)>1) #t <- data[1,5] #simulate data var_g<-3 var_c1<-1 var_c2<-1 M<-1000 N_1<-2 N_2<-3 lambda<-rnorm(n=M, mean=0, sd=sqrt(var_g)) s1_dist<-...
# Building the component stuff rm(list = ls()) #UNIVERSAL FUNCTIONS require(reshape2) require(ggplot2) require(lubridate) library(dplyr) library(stringr) library(stringi) source("main.R") ## Need to first load a list of cutoffs, ## which are fed into the algorithm using the ## variable "gaps" for the whole set, the...
/R/qual-graphs.R
permissive
jintrone/advice-reification
R
false
false
799
r
# Building the component stuff rm(list = ls()) #UNIVERSAL FUNCTIONS require(reshape2) require(ggplot2) require(lubridate) library(dplyr) library(stringr) library(stringi) source("main.R") ## Need to first load a list of cutoffs, ## which are fed into the algorithm using the ## variable "gaps" for the whole set, the...
#install.packages("MatrixEQTL") # source("Matrix_eQTL_R/Matrix_eQTL_engine.r"); library(MatrixEQTL) ## Location of the package with the data files. base.dir = find.package('MatrixEQTL'); # base.dir = '.'; ## Settings # Linear model to use, modelANOVA, modelLINEAR, or modelLINEAR_CROSS useModel = modelLINEAR; # mode...
/aQTL_analyses/R_script_for_Eurobats_adipose_BMI_significant_BMI_RF_MRs_matrix_aQTL.R
no_license
hoskinsjw/aQTL2021
R
false
false
4,189
r
#install.packages("MatrixEQTL") # source("Matrix_eQTL_R/Matrix_eQTL_engine.r"); library(MatrixEQTL) ## Location of the package with the data files. base.dir = find.package('MatrixEQTL'); # base.dir = '.'; ## Settings # Linear model to use, modelANOVA, modelLINEAR, or modelLINEAR_CROSS useModel = modelLINEAR; # mode...
# July 23rd created GitHub repository # also published to markloessi.shinyapps.io @ https://markloessi.shinyapps.io/gitHub_GoogleBubbleChart/ # data <- readRDS("~/Data/shinny/googlebubble71820/healthexp.Rds") # data <- readRDS("/Users/markloessi/Data/shinny/googlebubble71820/healthexp.Rds") # data <- readRDS("healthex...
/global.R
no_license
ghettocounselor/googleBubbleChart
R
false
false
1,377
r
# July 23rd created GitHub repository # also published to markloessi.shinyapps.io @ https://markloessi.shinyapps.io/gitHub_GoogleBubbleChart/ # data <- readRDS("~/Data/shinny/googlebubble71820/healthexp.Rds") # data <- readRDS("/Users/markloessi/Data/shinny/googlebubble71820/healthexp.Rds") # data <- readRDS("healthex...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/get_info.R \name{get_info.singular} \alias{get_info.singular} \title{singularized metrics information} \usage{ \method{get_info}{singular}(x, ...) } \arguments{ \item{x}{One object from stranger package} \item{\dots}{Additional pa...
/man/get_info.singular.Rd
no_license
cran/stranger
R
false
true
936
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/get_info.R \name{get_info.singular} \alias{get_info.singular} \title{singularized metrics information} \usage{ \method{get_info}{singular}(x, ...) } \arguments{ \item{x}{One object from stranger package} \item{\dots}{Additional pa...
# doprnt --- set curln, locate window (modified for screen editor) integer function doprnt (from, to) integer from, to include SE_COMMON integer local_to, local_from local_to = to # simulate value parameters local_from = from if (local_from <= 0) { doprnt = ERR Errcode = EOR...
/swt/src/spc/se.u/source/doprnt.r
no_license
arnoldrobbins/gt-swt
R
false
false
458
r
# doprnt --- set curln, locate window (modified for screen editor) integer function doprnt (from, to) integer from, to include SE_COMMON integer local_to, local_from local_to = to # simulate value parameters local_from = from if (local_from <= 0) { doprnt = ERR Errcode = EOR...
# 반복문 while number <- 0 while(number < 5 ) { print(number) number <- number + 1 } while(number < 5 ) { print(number) if(number == 3) { break } number <- number + 1 } number <- -1 while (number <= 10) { number <- number + 1 if(number %% 2 == 1) next print(number) } # 반복문 for for(i in 1:10)...
/Part3/sec14_While_For.R
no_license
duamkr/R-program
R
false
false
1,795
r
# 반복문 while number <- 0 while(number < 5 ) { print(number) number <- number + 1 } while(number < 5 ) { print(number) if(number == 3) { break } number <- number + 1 } number <- -1 while (number <= 10) { number <- number + 1 if(number %% 2 == 1) next print(number) } # 반복문 for for(i in 1:10)...
library(llama) ### Name: analysis ### Title: Analysis functions ### Aliases: contributions ### Keywords: models ### ** Examples if(Sys.getenv("RUN_EXPENSIVE") == "true") { data(satsolvers) contributions(satsolvers) }
/data/genthat_extracted_code/llama/examples/analysis.Rd.R
no_license
surayaaramli/typeRrh
R
false
false
225
r
library(llama) ### Name: analysis ### Title: Analysis functions ### Aliases: contributions ### Keywords: models ### ** Examples if(Sys.getenv("RUN_EXPENSIVE") == "true") { data(satsolvers) contributions(satsolvers) }
#De Boeck Ahn et al - Nature Communications 2020 - R 3.6.3 #working directory contains folder with CellRanger aggr output of 6 libraries (3 pcDNA and 3 IL-33 xenografts) #Load libraries library(Seurat) library(dplyr) library(ggplot2) library(viridis) #Load data fdata<-Read10X("filtered_feature_bc_matrix_U87...
/analysis/De Boeck Ahn et al - Nature Comm - analysis.R
no_license
menon-s/De-Boeck-Ahn-et-al-IL-33
R
false
false
10,640
r
#De Boeck Ahn et al - Nature Communications 2020 - R 3.6.3 #working directory contains folder with CellRanger aggr output of 6 libraries (3 pcDNA and 3 IL-33 xenografts) #Load libraries library(Seurat) library(dplyr) library(ggplot2) library(viridis) #Load data fdata<-Read10X("filtered_feature_bc_matrix_U87...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/gen-namespace-docs.R, % R/gen-namespace-examples.R, R/gen-namespace.R \name{torch_conj} \alias{torch_conj} \title{Conj} \usage{ torch_conj(self) } \arguments{ \item{self}{(Tensor) the input tensor.} } \description{ Conj } \section{conj(inpu...
/man/torch_conj.Rd
permissive
mlverse/torch
R
false
true
574
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/gen-namespace-docs.R, % R/gen-namespace-examples.R, R/gen-namespace.R \name{torch_conj} \alias{torch_conj} \title{Conj} \usage{ torch_conj(self) } \arguments{ \item{self}{(Tensor) the input tensor.} } \description{ Conj } \section{conj(inpu...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/ar_index.R \name{index_m_melted} \alias{index_m_melted} \title{create an index of a single monthly series that is in a melted dataframe} \usage{ index_m_melted(x, index_year) } \arguments{ \item{index_year}{} } \value{ } \description{ create...
/man/index_m_melted.Rd
permissive
aranryan/arlodr
R
false
true
389
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/ar_index.R \name{index_m_melted} \alias{index_m_melted} \title{create an index of a single monthly series that is in a melted dataframe} \usage{ index_m_melted(x, index_year) } \arguments{ \item{index_year}{} } \value{ } \description{ create...
#------------------------------------------------------------------------------# # TITLE: 02b_general_formatting.R # # PURPOSE: Transforming data to formats required for further analysis. # # INPUTS: <data_wide_formatted>, <dfs>. ...
/02_script/02b_general_formatting.R
no_license
jmroemer/CATI_Panel_Attrition
R
false
false
8,618
r
#------------------------------------------------------------------------------# # TITLE: 02b_general_formatting.R # # PURPOSE: Transforming data to formats required for further analysis. # # INPUTS: <data_wide_formatted>, <dfs>. ...
library(readr) library(dplyr) DATAB <- read.csv("D:/DATA SCIENCE PROYECTS/DATA NAVIGATOR INCITATECH/DATABTABLE.txt", sep="") DATAB$DESDE <- ave(DATAB$Año, DATAB$Indicador, FUN = min) DATAB$HASTA <- ave(DATAB$Año, DATAB$Indicador, FUN = max) CODEBOOK <- DATAB%>%group_by(Indicador)%>%slice(1) CODEBOOK <-select(CODEBOO...
/www/Datos.R
no_license
dalvarezpe/panel
R
false
false
471
r
library(readr) library(dplyr) DATAB <- read.csv("D:/DATA SCIENCE PROYECTS/DATA NAVIGATOR INCITATECH/DATABTABLE.txt", sep="") DATAB$DESDE <- ave(DATAB$Año, DATAB$Indicador, FUN = min) DATAB$HASTA <- ave(DATAB$Año, DATAB$Indicador, FUN = max) CODEBOOK <- DATAB%>%group_by(Indicador)%>%slice(1) CODEBOOK <-select(CODEBOO...
% Generated by roxygen2 (4.1.1): do not edit by hand % Please edit documentation in R/initializer.R \name{mx.init.uniform} \alias{mx.init.uniform} \title{Create a initializer that initialize the weight with uniform [-scale, scale]} \usage{ mx.init.uniform(scale) } \arguments{ \item{scale}{The scale of uniform distribut...
/R-package/man/mx.init.uniform.Rd
permissive
XinliangZhu/mxnet
R
false
false
421
rd
% Generated by roxygen2 (4.1.1): do not edit by hand % Please edit documentation in R/initializer.R \name{mx.init.uniform} \alias{mx.init.uniform} \title{Create a initializer that initialize the weight with uniform [-scale, scale]} \usage{ mx.init.uniform(scale) } \arguments{ \item{scale}{The scale of uniform distribut...
#' @include aaa.R NULL #' Create a function that returns fileinfo according to the given restrictions #' #' This functions returns a new function that can generate file information to #' be send to a shiny app based on a path relative to the given root. The #' function is secure in the sense that it prevents access...
/R/filechoose.R
no_license
sebkopf/shinyFiles
R
false
false
17,949
r
#' @include aaa.R NULL #' Create a function that returns fileinfo according to the given restrictions #' #' This functions returns a new function that can generate file information to #' be send to a shiny app based on a path relative to the given root. The #' function is secure in the sense that it prevents access...
#' @name minmax_img-methods #' @docType methods #' @aliases minmax_img #' @title Normalize Image using Range #' @description Calculates the range of values in an image, then #' scales the image minimum to 0 and maximum to 1 #' @return A \code{nifti} object (or list of them) or class of #' object passed in if not spe...
/R/minmax_img.R
no_license
muschellij2/neurobase
R
false
false
2,777
r
#' @name minmax_img-methods #' @docType methods #' @aliases minmax_img #' @title Normalize Image using Range #' @description Calculates the range of values in an image, then #' scales the image minimum to 0 and maximum to 1 #' @return A \code{nifti} object (or list of them) or class of #' object passed in if not spe...
#load multi_covariate values first setwd("C:/Users/Vijay/Documents/My Dropbox/thesis stuff/R workspaces") load(file='multi_covariate_values.RData') setwd("C:/Users/Vijay/Documents/My Dropbox/thesis stuff/marmot data files") all<-read.csv(file='all.csv',header=TRUE,sep=',') setwd("C:/Users/Vijay/Documents/My Drop...
/marmotpop_fig.R
no_license
vppatil/MarmotRepPaper
R
false
false
1,540
r
#load multi_covariate values first setwd("C:/Users/Vijay/Documents/My Dropbox/thesis stuff/R workspaces") load(file='multi_covariate_values.RData') setwd("C:/Users/Vijay/Documents/My Dropbox/thesis stuff/marmot data files") all<-read.csv(file='all.csv',header=TRUE,sep=',') setwd("C:/Users/Vijay/Documents/My Drop...
dopler<-function(x){ 20*sqrt(x*(1-x))*sin(2*pi*1.05/(x+0.05)) } dataset.dopler<-function(N,sigma=1){ set.seed(0) x<-sort(runif(N,min=0.12,max=1)) y<-dopler(x)+rnorm(N,sd=sigma) x.ts<-sort(runif(N,min=0.12,max=1)) y.ts<-dopler(x.ts) list(x=x,y=y,x.ts=x.ts,y.ts=y.ts) }
/inst/scripts/Nonlinear/dopler.R
no_license
gbonte/gbcode
R
false
false
305
r
dopler<-function(x){ 20*sqrt(x*(1-x))*sin(2*pi*1.05/(x+0.05)) } dataset.dopler<-function(N,sigma=1){ set.seed(0) x<-sort(runif(N,min=0.12,max=1)) y<-dopler(x)+rnorm(N,sd=sigma) x.ts<-sort(runif(N,min=0.12,max=1)) y.ts<-dopler(x.ts) list(x=x,y=y,x.ts=x.ts,y.ts=y.ts) }
# This script compares z-scores in the same brain region from right and left hemispheares i.e CA1 region with tissue ID 4254(L) and 4263(R). # Set working directory setwd("~/absb/results/allenbrain/") # Used libraries library(reshape2) library(foreach) # Path to the results saved in RData format for individual tiss...
/scripts/allenbrain/aba_zcores_left_right_compare.R
no_license
esugis/absb
R
false
false
837
r
# This script compares z-scores in the same brain region from right and left hemispheares i.e CA1 region with tissue ID 4254(L) and 4263(R). # Set working directory setwd("~/absb/results/allenbrain/") # Used libraries library(reshape2) library(foreach) # Path to the results saved in RData format for individual tiss...
\name{fmri.stimulus} \alias{fmri.stimulus} %- Also NEED an '\alias' for EACH other topic documented here. \title{ Linear Model for FMRI Data } \description{ Create the expected BOLD response for a given task indicator function. } \usage{ fmri.stimulus(scans = 1, onsets = c(1), durations = c(1), TR = 2, ...
/man/fmri.stimulus.Rd
no_license
cran/fmri
R
false
false
3,613
rd
\name{fmri.stimulus} \alias{fmri.stimulus} %- Also NEED an '\alias' for EACH other topic documented here. \title{ Linear Model for FMRI Data } \description{ Create the expected BOLD response for a given task indicator function. } \usage{ fmri.stimulus(scans = 1, onsets = c(1), durations = c(1), TR = 2, ...
suppressPackageStartupMessages(library(tibble)) suppressPackageStartupMessages(library(dplyr)) suppressPackageStartupMessages(library(tidyr)) suppressPackageStartupMessages(library(stringr)) source('snakemake/scripts/common.R') # path_base = "~/server/programming/enhancer_pipeline/output/" # # raw=read.table(paste0(...
/snakemake/scripts/combine_expression.R
no_license
icervenka/enhancer_correlation_snakemake
R
false
false
4,633
r
suppressPackageStartupMessages(library(tibble)) suppressPackageStartupMessages(library(dplyr)) suppressPackageStartupMessages(library(tidyr)) suppressPackageStartupMessages(library(stringr)) source('snakemake/scripts/common.R') # path_base = "~/server/programming/enhancer_pipeline/output/" # # raw=read.table(paste0(...
test_that("record_output", { code <- c( "1:50", "message('hi there!')" ) out1 <- record_output(code) expect_snapshot(out1) out2 <- record_output(code, stdout = FALSE) expect_snapshot(out2) out3 <- record_output(code, stderr = FALSE) expect_snapshot(out3) out4 <- record_output(code, echo =...
/tests/testthat/test-record-output.R
permissive
r-lib/asciicast
R
false
false
354
r
test_that("record_output", { code <- c( "1:50", "message('hi there!')" ) out1 <- record_output(code) expect_snapshot(out1) out2 <- record_output(code, stdout = FALSE) expect_snapshot(out2) out3 <- record_output(code, stderr = FALSE) expect_snapshot(out3) out4 <- record_output(code, echo =...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/t_coffee.R \name{tcs_loop} \alias{tcs_loop} \title{tcs_loop} \usage{ tcs_loop(folder, pattern = NULL, number_cores = 1, other_args = NULL, ...) } \arguments{ \item{folder}{Character vector of length one; the path to the folder containing the ...
/man/tcs_loop.Rd
permissive
joelnitta/baitfindR
R
false
true
1,709
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/t_coffee.R \name{tcs_loop} \alias{tcs_loop} \title{tcs_loop} \usage{ tcs_loop(folder, pattern = NULL, number_cores = 1, other_args = NULL, ...) } \arguments{ \item{folder}{Character vector of length one; the path to the folder containing the ...