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(nc) library(testthat) context("errors") source(system.file("test_engines.R", package="nc", mustWork=TRUE), local=TRUE) foo.bar <- c("foo", "bar") test_engines("no capture groups is an error", { expect_error({ capture_first_vec(foo.bar, "o") }, "must have at least one named argument", fixed=TRUE) }) na...
/tests/testthat/test-CRAN-errors.R
no_license
TimTaylor/nc
R
false
false
4,720
r
library(nc) library(testthat) context("errors") source(system.file("test_engines.R", package="nc", mustWork=TRUE), local=TRUE) foo.bar <- c("foo", "bar") test_engines("no capture groups is an error", { expect_error({ capture_first_vec(foo.bar, "o") }, "must have at least one named argument", fixed=TRUE) }) na...
# read_blacklist_genotypes --------------------------------------------------------------- #' @name read_blacklist_genotypes #' @title read blacklist of genotypes #' @description Read a blacklist object or file. #' #' #' Used internally in \href{https://github.com/thierrygosselin/radiator}{radiator} #' and might be of ...
/R/filter_blacklist_genotypes.R
no_license
italo-granato/radiator
R
false
false
15,624
r
# read_blacklist_genotypes --------------------------------------------------------------- #' @name read_blacklist_genotypes #' @title read blacklist of genotypes #' @description Read a blacklist object or file. #' #' #' Used internally in \href{https://github.com/thierrygosselin/radiator}{radiator} #' and might be of ...
# global.R #### # Coursera Data Science Capstone Project (https://www.coursera.org/course/dsscapstone) # Shiny script for loading data into global environment # 2016-02-05 # Libraries and options #### library(shiny) library(tm) library(quanteda) library(stringr) library(wordcloud) library(RColorBrewer) #set directo...
/shiny/global.R
no_license
CristelVeefkind/DSCapstone
R
false
false
673
r
# global.R #### # Coursera Data Science Capstone Project (https://www.coursera.org/course/dsscapstone) # Shiny script for loading data into global environment # 2016-02-05 # Libraries and options #### library(shiny) library(tm) library(quanteda) library(stringr) library(wordcloud) library(RColorBrewer) #set directo...
addhead <- function(part, Npart=2, Massarr=0, Time=0, z=0, FlagSfr=0, FlagFeedback=0, FlagCooling=0, BoxSize=0, OmegaM=0, OmegaL=0, h=1, FlagAge=0, FlagMetals=0, NallHW=0, flag_entr_ics=0){ N=length(part[,1]) NpartVec=rep(0,6) NpartVec[Npart]=N MassarrVec=rep(0,6) MassarrVec[Npart]=Massarr NallVec=rep(0,6) NallVec[N...
/snapshot/R/addhead.R
no_license
ingted/R-Examples
R
false
false
717
r
addhead <- function(part, Npart=2, Massarr=0, Time=0, z=0, FlagSfr=0, FlagFeedback=0, FlagCooling=0, BoxSize=0, OmegaM=0, OmegaL=0, h=1, FlagAge=0, FlagMetals=0, NallHW=0, flag_entr_ics=0){ N=length(part[,1]) NpartVec=rep(0,6) NpartVec[Npart]=N MassarrVec=rep(0,6) MassarrVec[Npart]=Massarr NallVec=rep(0,6) NallVec[N...
# ------------------------------------------------------------------------------- # This file is part of rangerts. # # rangerts is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License...
/R/treeInfo.R
no_license
hyanworkspace/rangerts
R
false
false
6,221
r
# ------------------------------------------------------------------------------- # This file is part of rangerts. # # rangerts is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/dynamodb_operations.R \name{dynamodb_get_item} \alias{dynamodb_get_item} \title{The GetItem operation returns a set of attributes for the item with the given primary key} \usage{ dynamodb_get_item(TableName, Key, AttributesToGet, ConsistentRe...
/cran/paws.database/man/dynamodb_get_item.Rd
permissive
johnnytommy/paws
R
false
true
5,200
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/dynamodb_operations.R \name{dynamodb_get_item} \alias{dynamodb_get_item} \title{The GetItem operation returns a set of attributes for the item with the given primary key} \usage{ dynamodb_get_item(TableName, Key, AttributesToGet, ConsistentRe...
################################################################################ ## Description: GAM mean/SE map at binned_survey_age ## Description: or delta SE, the difference between SE at binned_survey_age and SE at 12 months ## Sub-national SIAs: not included in prediction ## Spatial scale: single country ## Mean...
/Code/FunctionsForMaps.R
no_license
sakitakahashi/coldspots
R
false
false
78,765
r
################################################################################ ## Description: GAM mean/SE map at binned_survey_age ## Description: or delta SE, the difference between SE at binned_survey_age and SE at 12 months ## Sub-national SIAs: not included in prediction ## Spatial scale: single country ## Mean...
#' @noRd wb_default_lang <- function(lang) { if (missing(lang)) { env_lang <- options()$wbstats.lang if (!is.null(env_lang)) default_lang <- env_lang else default_lang <- wb_api_parameters$default_lang } else { # here is where you would set the environ var # do we check against availa...
/R/update_cache.R
no_license
cran/wbstats
R
false
false
626
r
#' @noRd wb_default_lang <- function(lang) { if (missing(lang)) { env_lang <- options()$wbstats.lang if (!is.null(env_lang)) default_lang <- env_lang else default_lang <- wb_api_parameters$default_lang } else { # here is where you would set the environ var # do we check against availa...
#' @title Converts data in table form to tidy_data #' #' @description Convert data in table format to tidy_data to use in the indicators of #' the tidy_data. #' @param path Character vector containing one or more path names. #' @param dataset Electoral results by party. It can be a \code{data.frame} or a \code{list...
/R/convert_esaps.R
no_license
Nicolas-Schmidt/esaps
R
false
false
11,261
r
#' @title Converts data in table form to tidy_data #' #' @description Convert data in table format to tidy_data to use in the indicators of #' the tidy_data. #' @param path Character vector containing one or more path names. #' @param dataset Electoral results by party. It can be a \code{data.frame} or a \code{list...
data(mtcars) table(mtcars$am) trans <- as.data.frame(table(mtcars$am)) trans SamProp <- trans[1,2]/sum(trans$Freq) PopProp <- 0.4 n <- sum(trans$Freq) z <- (SamProp - PopProp) / (sqrt(PopProp*(1-PopProp))/n) z ((19/32)-0.4)/sqrt((0.4*(1-0.4))/32) SamProp 19/32 z <- (SamProp - PopProp) / sqrt((PopProp*(1-PopProp))/n) z ...
/Asst9.2.r
no_license
vasanthi72/DARET_Assignment9.2
R
false
false
734
r
data(mtcars) table(mtcars$am) trans <- as.data.frame(table(mtcars$am)) trans SamProp <- trans[1,2]/sum(trans$Freq) PopProp <- 0.4 n <- sum(trans$Freq) z <- (SamProp - PopProp) / (sqrt(PopProp*(1-PopProp))/n) z ((19/32)-0.4)/sqrt((0.4*(1-0.4))/32) SamProp 19/32 z <- (SamProp - PopProp) / sqrt((PopProp*(1-PopProp))/n) z ...
#'@title histogram of data #' #'@description Get a histogram, showing the mean and median of your data #'@author Oscar Ramirez Alan (\email{osoramirez@@gmail.com}). #'@param x is a numeric value, could be a a vector or data.frame #'@export plothist #'@keywords plothist #'@return a summary #'@export plothist #'@import ...
/R/plothist.R
no_license
osoramirez/resumeRdesc
R
false
false
1,413
r
#'@title histogram of data #' #'@description Get a histogram, showing the mean and median of your data #'@author Oscar Ramirez Alan (\email{osoramirez@@gmail.com}). #'@param x is a numeric value, could be a a vector or data.frame #'@export plothist #'@keywords plothist #'@return a summary #'@export plothist #'@import ...
# airontime_sql_db.R library(DBI) library(odbc) library(dplyr) library(data.table) library(lubridate) library(ggplot2) library(dbplot) library(tidypredict) source('config_aot.R') # # Get `nycflights13` data tables ---- # # install.packages('nycflights13') airlines13 <- nycflights13::airlines airports13 <- nycflights1...
/airontime_sql_db.R
no_license
ldnicolasmay/r_db_sandbox
R
false
false
7,301
r
# airontime_sql_db.R library(DBI) library(odbc) library(dplyr) library(data.table) library(lubridate) library(ggplot2) library(dbplot) library(tidypredict) source('config_aot.R') # # Get `nycflights13` data tables ---- # # install.packages('nycflights13') airlines13 <- nycflights13::airlines airports13 <- nycflights1...
#Read data household_power_consumption_subset <- read.csv("household_power_consumption_subset.txt", sep=";") #Convert the date and time strings to POSIX format formated_d=strptime(paste(household_power_consumption_subset$Date,household_power_consumption_subset$Time),format="%d/%m/%Y %H:%M:%S") dw=format(formated_d,"%a"...
/plot4.R
no_license
Jia340/ExData_Plotting1
R
false
false
1,985
r
#Read data household_power_consumption_subset <- read.csv("household_power_consumption_subset.txt", sep=";") #Convert the date and time strings to POSIX format formated_d=strptime(paste(household_power_consumption_subset$Date,household_power_consumption_subset$Time),format="%d/%m/%Y %H:%M:%S") dw=format(formated_d,"%a"...
library(chipmine) ## this script: ## 1) use diffbind regions and generate profile plot around peak rm(list = ls()) outDir <- here::here("analysis", "02_ChIPseq_analysis", "03_diffBind") if(!dir.exists(outDir)){ dir.create(path = outDir) } analysisName <- "creE_diffbind" outPrefix <- paste(outDir, "/", analysisNa...
/scripts/12_peak_profile_plot.R
no_license
foreverst8/RglT_analysis
R
false
false
16,208
r
library(chipmine) ## this script: ## 1) use diffbind regions and generate profile plot around peak rm(list = ls()) outDir <- here::here("analysis", "02_ChIPseq_analysis", "03_diffBind") if(!dir.exists(outDir)){ dir.create(path = outDir) } analysisName <- "creE_diffbind" outPrefix <- paste(outDir, "/", analysisNa...
# # Estimate genome size by counting unique kmers # # df -> data.frame with Frequency and Count columns # filename -> name of .histo file # start_freq -> frequency to start from with kmer counting, will autoset if start_freq = NULL # end_freq -> frequency to end from with kmer counting # either +ve number >...
/peakCountKmer.R
no_license
slimsuite/GenomeR
R
false
false
4,613
r
# # Estimate genome size by counting unique kmers # # df -> data.frame with Frequency and Count columns # filename -> name of .histo file # start_freq -> frequency to start from with kmer counting, will autoset if start_freq = NULL # end_freq -> frequency to end from with kmer counting # either +ve number >...
## read_genomic_data -- reads genomic data in the specified zoom parameters... ## setClass("genomic_data_model",#"restricted_boltzman_machine", representation( n_zooms="integer", window_sizes="integer", half_nWindows="integer" ), ) genomic_data_model <- function(window_sizes, half_nWindows) { stop...
/R_packages/dREG/R/read_genomic_data.R
no_license
juhaa/dREG_analysis
R
false
false
6,827
r
## read_genomic_data -- reads genomic data in the specified zoom parameters... ## setClass("genomic_data_model",#"restricted_boltzman_machine", representation( n_zooms="integer", window_sizes="integer", half_nWindows="integer" ), ) genomic_data_model <- function(window_sizes, half_nWindows) { stop...
\name{nwfscSurveyCode-package} \alias{nwfscSurveyCode-package} \alias{nwfscSurveyCode} \docType{package} \title{ Functions used to analyze NWFSC survey data and create input for SS3 } \description{ More about what it does (maybe more than one line) } \details{ \tabular{ll}{ Package: \tab nwfscSurveyCode\cr ...
/man/nwfscSurveyCode-package.Rd
no_license
melissahaltuch-NOAA/nwfscSurvey
R
false
false
912
rd
\name{nwfscSurveyCode-package} \alias{nwfscSurveyCode-package} \alias{nwfscSurveyCode} \docType{package} \title{ Functions used to analyze NWFSC survey data and create input for SS3 } \description{ More about what it does (maybe more than one line) } \details{ \tabular{ll}{ Package: \tab nwfscSurveyCode\cr ...
## Functions for creating and using inverted matrices which caching ## Creates cacheable matrix makeCacheMatrix <- function(original = matrix()) { inverted <- NULL set <- function(y) { original <<- y inverted <<- NULL } # getter and setter for inv. matrix value get <- function() original ...
/cachematrix.R
no_license
dlg99/ProgrammingAssignment2
R
false
false
1,255
r
## Functions for creating and using inverted matrices which caching ## Creates cacheable matrix makeCacheMatrix <- function(original = matrix()) { inverted <- NULL set <- function(y) { original <<- y inverted <<- NULL } # getter and setter for inv. matrix value get <- function() original ...
file_name <- "raw_dataset.zip" # Download and unzip the given dataset from url : if (!file.exists(file_name)){ URL <- "https://d396qusza40orc.cloudfront.net/getdata%2Fprojectfiles%2FUCI%20HAR%20Dataset.zip " download.file( URL, file_name, method= "curl" ) } if (!file.exists("UCI HAR Dataset")) { unzip(file_na...
/run_analysis.R
no_license
ggarpanchal/Coursera_Data_Cleaning_Project
R
false
false
2,831
r
file_name <- "raw_dataset.zip" # Download and unzip the given dataset from url : if (!file.exists(file_name)){ URL <- "https://d396qusza40orc.cloudfront.net/getdata%2Fprojectfiles%2FUCI%20HAR%20Dataset.zip " download.file( URL, file_name, method= "curl" ) } if (!file.exists("UCI HAR Dataset")) { unzip(file_na...
################################## # Author: Gina Nichols (vnichols@iastate.edu) # Created: June 5 2020 # # Purpose: make manuscript figs # # Notes: # Last modified: 7/13/2020 (change UB/UG to UD/UM) # #################################### library(readr) library(dplyr) library(ggplot2) library(tidyr) library(stringr) ...
/02_make-figs/code_tbl-weed-list.R
no_license
vanichols/PFIweeds2020_analysis
R
false
false
3,001
r
################################## # Author: Gina Nichols (vnichols@iastate.edu) # Created: June 5 2020 # # Purpose: make manuscript figs # # Notes: # Last modified: 7/13/2020 (change UB/UG to UD/UM) # #################################### library(readr) library(dplyr) library(ggplot2) library(tidyr) library(stringr) ...
#' @include CalculateTravelDemand.R NULL #=================== #CalculateTravelDemandFuture.R #=================== #This module calculates average daily vehicle miles traveld for households. It also #calculates average DVMT, daily consumption of fuel (in gallons), and average daily #Co2 equivalent greenhouse emissions...
/sources/modules/VEHouseholdTravel/R/CalculateTravelDemandFuture.R
permissive
VisionEval/VisionEval-Dev
R
false
false
20,933
r
#' @include CalculateTravelDemand.R NULL #=================== #CalculateTravelDemandFuture.R #=================== #This module calculates average daily vehicle miles traveld for households. It also #calculates average DVMT, daily consumption of fuel (in gallons), and average daily #Co2 equivalent greenhouse emissions...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/assign_parameters.R \name{assign_parameters.subcatchments} \alias{assign_parameters.subcatchments} \title{conversion helper} \usage{ \method{assign_parameters}{subcatchments}( x, infiltration = NULL, subcatchment = NULL, subcatchment_...
/man/assign_parameters.subcatchments.Rd
no_license
dleutnant/swmmr
R
false
true
445
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/assign_parameters.R \name{assign_parameters.subcatchments} \alias{assign_parameters.subcatchments} \title{conversion helper} \usage{ \method{assign_parameters}{subcatchments}( x, infiltration = NULL, subcatchment = NULL, subcatchment_...
#Setup rm(list=ls()) if (Sys.info()["sysname"] == "Linux") { j_root <- "/home/j/" h_root <- "/homes/USERNAME/" } else { j_root <- "J:" h_root <- "H:" } ##Packages library(data.table) library(openxlsx) ##Set objects for each age split region_pattern <- T ##if true will use regional pattern for Dismod, if ...
/nonfatal_code/mental_unipolar_mdd/age_sex_splitting/age_split_byregion_cleaned.R
no_license
Nermin-Ghith/ihme-modeling
R
false
false
11,719
r
#Setup rm(list=ls()) if (Sys.info()["sysname"] == "Linux") { j_root <- "/home/j/" h_root <- "/homes/USERNAME/" } else { j_root <- "J:" h_root <- "H:" } ##Packages library(data.table) library(openxlsx) ##Set objects for each age split region_pattern <- T ##if true will use regional pattern for Dismod, if ...
# test KKT context(strwrap("KKT checks")) set.seed(1234) draw <- gen_structured_model(n = 500, p_design = 100, p_kinship = 1e4, geography = "1d", percent_causal = 0.05, perce...
/tests/testthat/test-KKT.R
permissive
areisett/ggmix
R
false
false
2,303
r
# test KKT context(strwrap("KKT checks")) set.seed(1234) draw <- gen_structured_model(n = 500, p_design = 100, p_kinship = 1e4, geography = "1d", percent_causal = 0.05, perce...
library(smerc) ## Adjacency matrix ## making an adjacency matrix library(igraph) ex_admatrix <- matrix(rep(c(0),36*36),nrow = 36,ncol = 36) set1 <- c(1,2:5,7,13,19,25,8:11,14:17,20:23,26:29) # set take i+1 and i+6 set2 <- c(31,32:35) # set take i+1 set3 <- c(6,12,18,24,30) # set take i+6 set4 <- c(19,21,31,33) for...
/Ex_6x6_French_a.R
no_license
duong87vn/Master-Project
R
false
false
8,300
r
library(smerc) ## Adjacency matrix ## making an adjacency matrix library(igraph) ex_admatrix <- matrix(rep(c(0),36*36),nrow = 36,ncol = 36) set1 <- c(1,2:5,7,13,19,25,8:11,14:17,20:23,26:29) # set take i+1 and i+6 set2 <- c(31,32:35) # set take i+1 set3 <- c(6,12,18,24,30) # set take i+6 set4 <- c(19,21,31,33) for...
GlMnet_Optimize <- function(FeatMat,ObsVec){ Alpha_Vec <- seq(0,1,0.25) MCCmedian_Vec <- c() for(alpha in Alpha_Vec){ MCC_Vec <- c() for(BSiter in 1:10){ FoldNum <- 3 folds <- createFolds(y=ObsVec, k = FoldNum, list = TRUE, returnTrain = TRUE) Folditer <- 1 InputInd <- f...
/R/GLMnet_Optimize.R
no_license
bhklab/MODELS
R
false
false
1,277
r
GlMnet_Optimize <- function(FeatMat,ObsVec){ Alpha_Vec <- seq(0,1,0.25) MCCmedian_Vec <- c() for(alpha in Alpha_Vec){ MCC_Vec <- c() for(BSiter in 1:10){ FoldNum <- 3 folds <- createFolds(y=ObsVec, k = FoldNum, list = TRUE, returnTrain = TRUE) Folditer <- 1 InputInd <- f...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/utils-airac.R \name{cfmu_airac_epoch_number} \alias{cfmu_airac_epoch_number} \title{The CFMU epoch number for AIRAC numbering scheme} \usage{ cfmu_airac_epoch_number() } \value{ the epoch number for CFMU AIRAC numbering scheme } \description{...
/man/cfmu_airac_epoch_number.Rd
no_license
euctrl-pru/trrrj
R
false
true
649
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/utils-airac.R \name{cfmu_airac_epoch_number} \alias{cfmu_airac_epoch_number} \title{The CFMU epoch number for AIRAC numbering scheme} \usage{ cfmu_airac_epoch_number() } \value{ the epoch number for CFMU AIRAC numbering scheme } \description{...
args = commandArgs(trailingOnly=TRUE) geneFile=args[1] RSEM_Output=args[2] direct=args[3] print(geneFile) print(RSEM_Output) print(direct) print("Get covered genes from RSEM output") #RSEM_Output=paste(direct,"coverage","all_genes.bed.genes.results",sep="/") #print(RSEM_Output) rsem=read.table(RSEM_Output,header=T)...
/AnalysingMethods/getCovered.R
no_license
aina91/FivePrime
R
false
false
752
r
args = commandArgs(trailingOnly=TRUE) geneFile=args[1] RSEM_Output=args[2] direct=args[3] print(geneFile) print(RSEM_Output) print(direct) print("Get covered genes from RSEM output") #RSEM_Output=paste(direct,"coverage","all_genes.bed.genes.results",sep="/") #print(RSEM_Output) rsem=read.table(RSEM_Output,header=T)...
#' Get an aggregate value from the outdegree of nodes #' #' @description #' #' Get a single, aggregate value from the outdegree values for all nodes in a #' graph, or, a subset of graph nodes. #' #' @inheritParams render_graph #' @param agg The aggregation function to use for summarizing outdegree values #' from grap...
/R/get_agg_degree_out.R
permissive
rich-iannone/DiagrammeR
R
false
false
3,246
r
#' Get an aggregate value from the outdegree of nodes #' #' @description #' #' Get a single, aggregate value from the outdegree values for all nodes in a #' graph, or, a subset of graph nodes. #' #' @inheritParams render_graph #' @param agg The aggregation function to use for summarizing outdegree values #' from grap...
library(io) library(dplyr) library(ggplot2) library(ggsci) shift <- function(x, n=1) { if (n == 0) { x } else { c(tail(x, -n), head(x, n)) } } clones <- c("P", "RC1", "RC2", "RC3", "RC4", "RC5", "RC6", "RC7"); clone.cols <- shift(pal_d3()(length(clones)), -1); names(clone.cols) <- clones; ref.target ...
/qrtpcr/analyze.R
no_license
djhshih/analysis-parpir-sum149-rna-seq
R
false
false
3,711
r
library(io) library(dplyr) library(ggplot2) library(ggsci) shift <- function(x, n=1) { if (n == 0) { x } else { c(tail(x, -n), head(x, n)) } } clones <- c("P", "RC1", "RC2", "RC3", "RC4", "RC5", "RC6", "RC7"); clone.cols <- shift(pal_d3()(length(clones)), -1); names(clone.cols) <- clones; ref.target ...
# Latvia vaccine data library(here) source(here("Automation/00_Functions_automation.R")) library(lubridate) library(dplyr) library(tidyverse) # assigning Drive credentials in the case the script is verified manually if (!"email" %in% ls()){ email <- "jessica_d.1994@yahoo.de" } # info country and N drive addres...
/Automation/00_hydra/deprecated/Latvia_vaccine.R
permissive
timriffe/covid_age
R
false
false
4,364
r
# Latvia vaccine data library(here) source(here("Automation/00_Functions_automation.R")) library(lubridate) library(dplyr) library(tidyverse) # assigning Drive credentials in the case the script is verified manually if (!"email" %in% ls()){ email <- "jessica_d.1994@yahoo.de" } # info country and N drive addres...
#' Rank-based hypothesis tests for HPD matrices #' #' \code{pdRankTests} performs a number of generalized rank-based hypothesis tests in the metric space of HPD matrices equipped #' with the affine-invariant Riemannian metric or Log-Euclidean metric for samples of HPD matrices or samples of sequences #' (curves) of HPD...
/R/ranktests.R
no_license
cran/pdSpecEst
R
false
false
11,181
r
#' Rank-based hypothesis tests for HPD matrices #' #' \code{pdRankTests} performs a number of generalized rank-based hypothesis tests in the metric space of HPD matrices equipped #' with the affine-invariant Riemannian metric or Log-Euclidean metric for samples of HPD matrices or samples of sequences #' (curves) of HPD...
testlist <- list(AgeVector = c(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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), ExpressionSet = structure(c(1.63064200184954e+212, 1.11558267938731e+157, 2.3453288146775e+59, 7.59955788945772e-256, 5.55398...
/myTAI/inst/testfiles/cpp_omitMatrix/AFL_cpp_omitMatrix/cpp_omitMatrix_valgrind_files/1615846386-test.R
no_license
akhikolla/updatedatatype-list3
R
false
false
1,090
r
testlist <- list(AgeVector = c(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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), ExpressionSet = structure(c(1.63064200184954e+212, 1.11558267938731e+157, 2.3453288146775e+59, 7.59955788945772e-256, 5.55398...
c DCNF-Autarky [version 0.0.1]. c Copyright (c) 2018-2019 Swansea University. c c Input Clause Count: 45 c Performing E1-Autarky iteration. c Remaining clauses count after E-Reduction: 45 c c Input Parameter (command line, file): c input filename QBFLIB/Jordan-Kaiser/reduction-finding-full-set-params-k1c3n4/exque...
/code/dcnf-ankit-optimized/Results/QBFLIB-2018/E1/Experiments/Jordan-Kaiser/reduction-finding-full-set-params-k1c3n4/exquery_query15_1344n/exquery_query15_1344n.R
no_license
arey0pushpa/dcnf-autarky
R
false
false
694
r
c DCNF-Autarky [version 0.0.1]. c Copyright (c) 2018-2019 Swansea University. c c Input Clause Count: 45 c Performing E1-Autarky iteration. c Remaining clauses count after E-Reduction: 45 c c Input Parameter (command line, file): c input filename QBFLIB/Jordan-Kaiser/reduction-finding-full-set-params-k1c3n4/exque...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/eFrame.R \name{eFrameR} \alias{eFrameR} \title{eFrameR} \usage{ eFrameR(y, type, siteCovs = NULL) } \arguments{ \item{y}{An MxJ matrix of the observed removal data, where M is the number of sites and J is the maximum number of removal (primar...
/man/eFrameR.Rd
no_license
scrogster/eradicate
R
false
true
969
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/eFrame.R \name{eFrameR} \alias{eFrameR} \title{eFrameR} \usage{ eFrameR(y, type, siteCovs = NULL) } \arguments{ \item{y}{An MxJ matrix of the observed removal data, where M is the number of sites and J is the maximum number of removal (primar...
corr <- function(directory, threshold = 0) { ## 'directory' is a character vector of length 1 indicating ## the location of the CSV files ## 'threshold' is a numeric vector of length 1 indicating the ## number of completely observed observations (on all ## variables) required to compute the correlation bet...
/1/corr.R
no_license
elegantcoderM/R-programming-course-assignments
R
false
false
915
r
corr <- function(directory, threshold = 0) { ## 'directory' is a character vector of length 1 indicating ## the location of the CSV files ## 'threshold' is a numeric vector of length 1 indicating the ## number of completely observed observations (on all ## variables) required to compute the correlation bet...
#' A Gadget for testing gsub regular expressions. #' #' Supply a regex pattern, a string where matches #' are sought, and a replacement. This gadget allows #' regex testing. When the correct regex is found, #' clicking "Done" will return the current regex. #' #' @param pattern The regular expression to match. #' #' @p...
/R/regexTest.R
no_license
mosaddek-hossain/BiocGadgets
R
false
false
1,415
r
#' A Gadget for testing gsub regular expressions. #' #' Supply a regex pattern, a string where matches #' are sought, and a replacement. This gadget allows #' regex testing. When the correct regex is found, #' clicking "Done" will return the current regex. #' #' @param pattern The regular expression to match. #' #' @p...
#' An azimuth/zenith coordinate system #' #' This coordinate system imagines that your data will be plotted on the bottom of a #' sphere, oriented such that 0 azimuth is at the positive x-axis, and 0 zenith is at the #' top of the bowl. Increasing azimuth is counterclockwise, and zenith angles that are more #' negativ...
/R/coords.R
no_license
paleolimbot/ggstereo
R
false
false
13,521
r
#' An azimuth/zenith coordinate system #' #' This coordinate system imagines that your data will be plotted on the bottom of a #' sphere, oriented such that 0 azimuth is at the positive x-axis, and 0 zenith is at the #' top of the bowl. Increasing azimuth is counterclockwise, and zenith angles that are more #' negativ...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/topoplot.R \name{topoplot} \alias{topoplot} \alias{topoplot.data.frame} \alias{topoplot.eeg_data} \title{Topographical Plotting Function for EEG} \usage{ topoplot(data, ...) \method{topoplot}{data.frame}(data, time_lim = NULL, limits = NULL,...
/man/topoplot.Rd
permissive
mantour/eegUtils
R
false
true
3,890
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/topoplot.R \name{topoplot} \alias{topoplot} \alias{topoplot.data.frame} \alias{topoplot.eeg_data} \title{Topographical Plotting Function for EEG} \usage{ topoplot(data, ...) \method{topoplot}{data.frame}(data, time_lim = NULL, limits = NULL,...
#' Change type of pdqr-function #' #' Modify [type][meta_type()] of pdqr-function using method of choice. #' #' @param f A pdqr-function. #' @param type A desired type of output. Should be one of "discrete" or #' "continuous". If `NULL` (default), it is chosen as an opposite of `f`'s #' type. #' @param method Retyp...
/R/form_retype.R
permissive
echasnovski/pdqr
R
false
false
10,030
r
#' Change type of pdqr-function #' #' Modify [type][meta_type()] of pdqr-function using method of choice. #' #' @param f A pdqr-function. #' @param type A desired type of output. Should be one of "discrete" or #' "continuous". If `NULL` (default), it is chosen as an opposite of `f`'s #' type. #' @param method Retyp...
# Exercise 5: large data sets: Baby Name Popularity Over Time # Read in the female baby names data file found in the `data` folder into a # variable called `names`. Remember to NOT treat the strings as factors! names <- read.csv("data/female_names.csv", stringsAsFactors = FALSE) # Create a data frame `names_2013` th...
/exercise-5/exercise.R
permissive
tleung22/ch9-data-frames
R
false
false
1,630
r
# Exercise 5: large data sets: Baby Name Popularity Over Time # Read in the female baby names data file found in the `data` folder into a # variable called `names`. Remember to NOT treat the strings as factors! names <- read.csv("data/female_names.csv", stringsAsFactors = FALSE) # Create a data frame `names_2013` th...
library(plyr); #Download the file from the internet into the working directory internetFile <- "https://d396qusza40orc.cloudfront.net/getdata%2Fprojectfiles%2FUCI%20HAR%20Dataset.zip" download.file(internetFile,destfile="data.zip",method="internal") unzip(zipfile="data.zip") #Set the path filePath <- "UCI HAR Dataset...
/run_analysis.R
no_license
chungkster/Getting-and-Cleaning-Data
R
false
false
3,099
r
library(plyr); #Download the file from the internet into the working directory internetFile <- "https://d396qusza40orc.cloudfront.net/getdata%2Fprojectfiles%2FUCI%20HAR%20Dataset.zip" download.file(internetFile,destfile="data.zip",method="internal") unzip(zipfile="data.zip") #Set the path filePath <- "UCI HAR Dataset...
ch31=read.csv("D:/r-SEM/data/ch31.csv") fit<-lm(formula=y~x1+x2, data=ch31) summary(fit)
/data/ch3-1.R
no_license
Finfra/r-sem
R
false
false
92
r
ch31=read.csv("D:/r-SEM/data/ch31.csv") fit<-lm(formula=y~x1+x2, data=ch31) summary(fit)
# R script to find differentially expressed genes by R package wilcoxon. library("limma") library("edgeR") d<-read.csv("CPM_filtered_outlier.csv",header = T) RPM <- d[,2:42] rownames(RPM)<-d[,1] keep <- rowSums(RPM>0)>=9 RPM <- RPM[keep,] group <- c(rep("HCC",30),rep("Normal",11)) RPM_HCC <- RPM[,1:30] RPM_Normal <-...
/upload/3.diff_exp/16-Siqi-RPM_Wilcoxon_Differentail_expression_genes.sh
no_license
YuminTHU/training
R
false
false
1,361
sh
# R script to find differentially expressed genes by R package wilcoxon. library("limma") library("edgeR") d<-read.csv("CPM_filtered_outlier.csv",header = T) RPM <- d[,2:42] rownames(RPM)<-d[,1] keep <- rowSums(RPM>0)>=9 RPM <- RPM[keep,] group <- c(rep("HCC",30),rep("Normal",11)) RPM_HCC <- RPM[,1:30] RPM_Normal <-...
# filtrado intermedio filterNum <- function (x, min = NULL, max = NULL){ x1 <- x[!is.na(x)] if (!is.null(min)) x1 <- x1 [x1 >= min ] if (!is.null(max)) x1 <- x1 [x1 <= max ] return (as.numeric(x1)) }
/Datasources/src/lib/filter_num.R
no_license
esterniclos/tfm_market_analysis_with_clustering
R
false
false
233
r
# filtrado intermedio filterNum <- function (x, min = NULL, max = NULL){ x1 <- x[!is.na(x)] if (!is.null(min)) x1 <- x1 [x1 >= min ] if (!is.null(max)) x1 <- x1 [x1 <= max ] return (as.numeric(x1)) }
ui <- navbarPage(title="UK Covid Data Visualised", tabPanel(title="Maps", fluidRow( column(3, wellPanel( h4("Configurations"), radioButtons("dataRadioType", h5("Data"), ...
/ui.R
no_license
Unknown807/Interactive-UK-Covid-Data
R
false
false
3,485
r
ui <- navbarPage(title="UK Covid Data Visualised", tabPanel(title="Maps", fluidRow( column(3, wellPanel( h4("Configurations"), radioButtons("dataRadioType", h5("Data"), ...
sum_num <- function(x,y){ x + y } sum_num(5, 10) sub_num <- function(x,y){ x - y } sub_num(5, 2) mult_num <- function(x,y){ x * y } mult_num(25, 3) div_num <- function(x,y){ x / y } div_num(100, 2) exp_num <- function(x,y){ x ** y } exp_num(4, 3) sqrt_num <- functio...
/CA05/calculatorR.R
no_license
jollyroger78/programming_big_data_rp
R
false
false
587
r
sum_num <- function(x,y){ x + y } sum_num(5, 10) sub_num <- function(x,y){ x - y } sub_num(5, 2) mult_num <- function(x,y){ x * y } mult_num(25, 3) div_num <- function(x,y){ x / y } div_num(100, 2) exp_num <- function(x,y){ x ** y } exp_num(4, 3) sqrt_num <- functio...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/cellalign.R \name{gene_test_plot} \alias{gene_test_plot} \title{Plot Gene expression over pseudotime on reference and query trajectories from cellAlign} \usage{ gene_test_plot( expGlobalRef, expGlobalQuery, trajRef, trajQuery, winSz...
/man/gene_test_plot.Rd
permissive
mitsingh/seuratTools
R
false
true
492
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/cellalign.R \name{gene_test_plot} \alias{gene_test_plot} \title{Plot Gene expression over pseudotime on reference and query trajectories from cellAlign} \usage{ gene_test_plot( expGlobalRef, expGlobalQuery, trajRef, trajQuery, winSz...
library(distrMod) ### Name: FunSymmList-class ### Title: List of Symmetries for a List of Functions ### Aliases: FunSymmList-class ### Keywords: classes ### ** Examples new("FunSymmList", list(NonSymmetric(), EvenSymmetric(SymmCenter = 1), OddSymmetric(SymmCenter = 2)))
/data/genthat_extracted_code/distrMod/examples/FunSymmList-class.Rd.R
no_license
surayaaramli/typeRrh
R
false
false
303
r
library(distrMod) ### Name: FunSymmList-class ### Title: List of Symmetries for a List of Functions ### Aliases: FunSymmList-class ### Keywords: classes ### ** Examples new("FunSymmList", list(NonSymmetric(), EvenSymmetric(SymmCenter = 1), OddSymmetric(SymmCenter = 2)))
# Author: Robert J. Hijmans # Date : December 2011 # Version 1.0 # Licence GPL v3 setMethod("select", signature(x="SpatRaster"), function(x, ...) { e <- draw(...) int <- intersect(e, ext(x)) if (is.null(int)) { x <- NULL } else { x <- crop(x, e) } x } ) #setMethod("selec...
/terra/R/select.R
no_license
akhikolla/TestedPackages-NoIssues
R
false
false
639
r
# Author: Robert J. Hijmans # Date : December 2011 # Version 1.0 # Licence GPL v3 setMethod("select", signature(x="SpatRaster"), function(x, ...) { e <- draw(...) int <- intersect(e, ext(x)) if (is.null(int)) { x <- NULL } else { x <- crop(x, e) } x } ) #setMethod("selec...
# Genotypes QC # plot 1 library(ggplot2) library(dplyr) #theme_set(theme_classic()) #tab2 = tab tab=tabp tab=tab[!(tab$pred_hard=='./.'),] tab$simple = 'ccomplex' tab[tab$GT %in% c('0|0', '1|0', '0|1', '1|1'),]$simple = 'asimple' tab[tab$GT %in% c('noreads'),]$simple = 'zeroreads' tab[tab$GT %in% c('noreads'),]$simp...
/workflow/scripts/arbigent/genotypes_qc.R
permissive
friendsofstrandseq/mosaicatcher-pipeline
R
false
false
14,552
r
# Genotypes QC # plot 1 library(ggplot2) library(dplyr) #theme_set(theme_classic()) #tab2 = tab tab=tabp tab=tab[!(tab$pred_hard=='./.'),] tab$simple = 'ccomplex' tab[tab$GT %in% c('0|0', '1|0', '0|1', '1|1'),]$simple = 'asimple' tab[tab$GT %in% c('noreads'),]$simple = 'zeroreads' tab[tab$GT %in% c('noreads'),]$simp...
context("Testing Single Sample Endpoints") test_that("We can get the info for a single sample.", { httptest::skip_if_disconnected() url <- build_url('/tests/test_sample/') json_file <- 'api/tests/test_sample.json' response <- httr::content(httr::GET(url), as="text") httptest::expect_json_equivalen...
/staphopia/tests/testthat/test_single_sample_endpoints.R
no_license
staphopia/staphopia-r
R
false
false
4,408
r
context("Testing Single Sample Endpoints") test_that("We can get the info for a single sample.", { httptest::skip_if_disconnected() url <- build_url('/tests/test_sample/') json_file <- 'api/tests/test_sample.json' response <- httr::content(httr::GET(url), as="text") httptest::expect_json_equivalen...
library(shiny) library(ggvis) shinyUI(pageWithSidebar( div(), sidebarPanel( ########################### ## Sidebar for file chooser ########################### conditionalPanel( condition = "input....
/RDataViz_Shiny/ui.R
no_license
wtcooper/DataProductsCourse
R
false
false
10,571
r
library(shiny) library(ggvis) shinyUI(pageWithSidebar( div(), sidebarPanel( ########################### ## Sidebar for file chooser ########################### conditionalPanel( condition = "input....
Draw.boxplots <- function(Obj) { Sensitivity.SP <- Obj$TP.SP/(Obj$TP.SP + Obj$FN.SP) Sensitivity.EF <- Obj$TP.EF/(Obj$TP.EF + Obj$FN.EF) Specificity.SP <- Obj$TN.SP/(Obj$TN.SP + Obj$FP.SP) Specificity.EF <- Obj$TN.EF/(Obj$TN.EF + Obj$FP.EF) p0hat <- with(Obj, cbind(p0hat.EF, p0hat.SP)) RMSE <- with(Obj, ...
/simulations/SimUni_Gamma.R
no_license
seokohj/SPMix-LocalFDR
R
false
false
3,295
r
Draw.boxplots <- function(Obj) { Sensitivity.SP <- Obj$TP.SP/(Obj$TP.SP + Obj$FN.SP) Sensitivity.EF <- Obj$TP.EF/(Obj$TP.EF + Obj$FN.EF) Specificity.SP <- Obj$TN.SP/(Obj$TN.SP + Obj$FP.SP) Specificity.EF <- Obj$TN.EF/(Obj$TN.EF + Obj$FP.EF) p0hat <- with(Obj, cbind(p0hat.EF, p0hat.SP)) RMSE <- with(Obj, ...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/read_content.R \name{read_content} \alias{read_content} \title{Compute nucleotide content per position. Wrapper function around seqTools.} \usage{ read_content(fseq, output_file = NA) } \arguments{ \item{fseq}{a seqTools::fastqq object} \ite...
/man/read_content.Rd
no_license
compbiocore/qckitfastq
R
false
true
727
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/read_content.R \name{read_content} \alias{read_content} \title{Compute nucleotide content per position. Wrapper function around seqTools.} \usage{ read_content(fseq, output_file = NA) } \arguments{ \item{fseq}{a seqTools::fastqq object} \ite...
#' @include AllClass.R {} #' @include AllGeneric.R {} #' @include common.R {} #' @include SparseBrainVector.R {} .BrainVectorFromMatrix <- function(data, space) { nvols <- dim(space)[4] nelements <- prod(dim(space)[1:3]) if ( (dim(data)[1] == nvols) && (dim(data)[2] == nelements) ) { #fourth dimension is ro...
/R/BrainVector.R
no_license
bbuchsbaum/neuroim
R
false
false
23,858
r
#' @include AllClass.R {} #' @include AllGeneric.R {} #' @include common.R {} #' @include SparseBrainVector.R {} .BrainVectorFromMatrix <- function(data, space) { nvols <- dim(space)[4] nelements <- prod(dim(space)[1:3]) if ( (dim(data)[1] == nvols) && (dim(data)[2] == nelements) ) { #fourth dimension is ro...
#!/usr/bin/Rscript # This is an example of how to wait for user input # This does not work in a script (meaning not in Rscript, only in R) cat("please press a key...\n") invisible(scan(file = "", what = "", nmax = 1))
/src/examples/console/scan.R
no_license
veltzer/demos-r
R
false
false
220
r
#!/usr/bin/Rscript # This is an example of how to wait for user input # This does not work in a script (meaning not in Rscript, only in R) cat("please press a key...\n") invisible(scan(file = "", what = "", nmax = 1))
| pc = 0xc002 | a = 0x05 | x = 0x00 | y = 0x00 | sp = 0x01fd | p[NV-BDIZC] = 00110100 | | pc = 0xc004 | a = 0x05 | x = 0x02 | y = 0x00 | sp = 0x01fd | p[NV-BDIZC] = 00110100 | | pc = 0xc007 | a = 0x05 | x = 0x02 | y = 0x00 | sp = 0x01fd | p[NV-BDIZC] = 00110100 | MEM[0x0515] = 0x05 | | pc = 0xc009 | a = 0x03 | x = 0x02...
/res/adc_absx_2.r
permissive
JSpuri/EmuParadise
R
false
false
788
r
| pc = 0xc002 | a = 0x05 | x = 0x00 | y = 0x00 | sp = 0x01fd | p[NV-BDIZC] = 00110100 | | pc = 0xc004 | a = 0x05 | x = 0x02 | y = 0x00 | sp = 0x01fd | p[NV-BDIZC] = 00110100 | | pc = 0xc007 | a = 0x05 | x = 0x02 | y = 0x00 | sp = 0x01fd | p[NV-BDIZC] = 00110100 | MEM[0x0515] = 0x05 | | pc = 0xc009 | a = 0x03 | x = 0x02...
#sourcing # for (i in dir("R/")) source(paste0("R/", i)) # library(ggplot2) # library(crayon) # stop("Done sourcing.", call. = FALSE) devtools::load_all(".") #Cmd + Shift + L #Tests things quickly #library("cobalt") data("lalonde", package = "cobalt") covs <- subset(lalonde, select = -c(re78, treat)) lalonde_ <- split...
/do_not_include/tests.R
no_license
ngreifer/cobalt
R
false
false
19,957
r
#sourcing # for (i in dir("R/")) source(paste0("R/", i)) # library(ggplot2) # library(crayon) # stop("Done sourcing.", call. = FALSE) devtools::load_all(".") #Cmd + Shift + L #Tests things quickly #library("cobalt") data("lalonde", package = "cobalt") covs <- subset(lalonde, select = -c(re78, treat)) lalonde_ <- split...
# path to the file dataFile <- "./data/household_power_consumption.txt" # load data from the file data <- read.table(dataFile, header=TRUE, sep=";", stringsAsFactors=FALSE, dec=".") # take only two days data subSetData <- data[data$Date %in% c("1/2/2007","2/2/2007") ,] datetime <- strptime(paste(subSetData$Date, sub...
/plot3.R
no_license
bradd123/ExData_Plotting1
R
false
false
1,141
r
# path to the file dataFile <- "./data/household_power_consumption.txt" # load data from the file data <- read.table(dataFile, header=TRUE, sep=";", stringsAsFactors=FALSE, dec=".") # take only two days data subSetData <- data[data$Date %in% c("1/2/2007","2/2/2007") ,] datetime <- strptime(paste(subSetData$Date, sub...
% Generated by roxygen2 (4.1.1): do not edit by hand % Please edit documentation in R/modeling.R \name{DR.Okunieff} \alias{DR.Okunieff} \title{Function that calculates TCP according Okunieff model} \usage{ DR.Okunieff(doses, TD50 = 45, gamma50 = 1.5, a = 1) } \arguments{ \item{doses}{Either a \code{dvhmatrix} class obj...
/man/DR.Okunieff.Rd
no_license
cat2tom/moddicom
R
false
false
1,588
rd
% Generated by roxygen2 (4.1.1): do not edit by hand % Please edit documentation in R/modeling.R \name{DR.Okunieff} \alias{DR.Okunieff} \title{Function that calculates TCP according Okunieff model} \usage{ DR.Okunieff(doses, TD50 = 45, gamma50 = 1.5, a = 1) } \arguments{ \item{doses}{Either a \code{dvhmatrix} class obj...
/r4ds_ch5.R
no_license
yan9914/R4DS
R
false
false
4,322
r
# Define required packages and install new packages dm.required.packages <- c("lubridate", "dplyr", "ggplot2", "scales", "rpart", "rpart.plot", "party", "RColorBrewer") package.install.func <- function(x) { for (i in x) { # require returns TRUE invisibly if it was able to load package if ...
/CRICKET.R
no_license
shubhampachori12110095/kdd-cricket
R
false
false
12,268
r
# Define required packages and install new packages dm.required.packages <- c("lubridate", "dplyr", "ggplot2", "scales", "rpart", "rpart.plot", "party", "RColorBrewer") package.install.func <- function(x) { for (i in x) { # require returns TRUE invisibly if it was able to load package if ...
dane <- read.csv("household_power_consumption.txt",sep = ";", na.strings="?") dane$Date <- as.Date(dane$Date, format="%d/%m/%Y") dane$Date<-paste(dane$Date, dane$Time) dane$Time<-NULL sub.dane = subset(dane, as.Date(Date)>= '2007-02-01'& as.Date(Date)<='2007-02-02') sub.dane$Date<-as.POSIXct(strptime(sub.dane$Date, "%Y...
/plot4.R
no_license
cornerek/ExData_Plotting1
R
false
false
996
r
dane <- read.csv("household_power_consumption.txt",sep = ";", na.strings="?") dane$Date <- as.Date(dane$Date, format="%d/%m/%Y") dane$Date<-paste(dane$Date, dane$Time) dane$Time<-NULL sub.dane = subset(dane, as.Date(Date)>= '2007-02-01'& as.Date(Date)<='2007-02-02') sub.dane$Date<-as.POSIXct(strptime(sub.dane$Date, "%Y...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/plot_wind.R \name{plot_wind} \alias{plot_wind} \alias{plot_wind.swmpr} \title{Create a wind rose} \usage{ plot_wind(swmpr_in, ...) \method{plot_wind}{swmpr}(swmpr_in, years = NULL, angle = 45, width = 1.5, breaks = 5, paddle = FALSE, grid....
/man/plot_wind.Rd
no_license
swmpkim/SWMPr
R
false
true
2,452
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/plot_wind.R \name{plot_wind} \alias{plot_wind} \alias{plot_wind.swmpr} \title{Create a wind rose} \usage{ plot_wind(swmpr_in, ...) \method{plot_wind}{swmpr}(swmpr_in, years = NULL, angle = 45, width = 1.5, breaks = 5, paddle = FALSE, grid....
setwd("~/Desktop/tmp/MorrisonLab/Computational/06102019-TERT/") library(ggplot2) TERT = read.table("TERT_mut.tsv", sep="\t") TERT = TERT[,c(1,2,7,8,9,10,11,13,14,16,17,29)] TERT = unique(TERT) rb_patient = fread("~/Desktop/rblist.csv") not_rb_patient = fread("~/Desktop/notrblist.csv") TERT_rb <- TERT %>% filter(V2 %i...
/plot_script/figure22.R
no_license
mkmwong/bioinformatics_util
R
false
false
1,269
r
setwd("~/Desktop/tmp/MorrisonLab/Computational/06102019-TERT/") library(ggplot2) TERT = read.table("TERT_mut.tsv", sep="\t") TERT = TERT[,c(1,2,7,8,9,10,11,13,14,16,17,29)] TERT = unique(TERT) rb_patient = fread("~/Desktop/rblist.csv") not_rb_patient = fread("~/Desktop/notrblist.csv") TERT_rb <- TERT %>% filter(V2 %i...
## Run a linear regression analysis of two chosen variables in a dataset. linear_regression <- function(variable_1, variable_2) { model_fit <- lm(variable_1 ~ variable_2) summary <- summary(model_fit) return(summary) } Ex: > linear_regression(Data$Estimated_Age, Data$SVL)
/brock/R/project_two_function.R
no_license
BiologicalDataAnalysis2019/2020
R
false
false
287
r
## Run a linear regression analysis of two chosen variables in a dataset. linear_regression <- function(variable_1, variable_2) { model_fit <- lm(variable_1 ~ variable_2) summary <- summary(model_fit) return(summary) } Ex: > linear_regression(Data$Estimated_Age, Data$SVL)
library(cancereffectsizeR) library(scales) library(stringr) library(dplyr) library(ggplot2) library(cowplot) scientific <- function(x){ ifelse(x==0, "0", parse(text=gsub("[+]", "", gsub("e", " %*% 10^", label_scientific()(x))))) } #Load in your file threestage_final <- load_cesa("threestage_final.rds"...
/Figure3_CES.R
no_license
alexander-y-yang/PRAD
R
false
false
26,307
r
library(cancereffectsizeR) library(scales) library(stringr) library(dplyr) library(ggplot2) library(cowplot) scientific <- function(x){ ifelse(x==0, "0", parse(text=gsub("[+]", "", gsub("e", " %*% 10^", label_scientific()(x))))) } #Load in your file threestage_final <- load_cesa("threestage_final.rds"...
context("map_layers") test_that("layerId includes all layers", { layers <- c( "animated_arc" , "animated_line" , "arc" , "bitmap" , "column" , "geojson" , "greatcircle" , "grid" , "h3" , "heatmap" , "hexagon" , "line" , "mesh" , "path" , "pointcloud" , "polygon" , "scatterplot" , ...
/tests/testthat/test-map_layers.R
no_license
SymbolixAU/mapdeck
R
false
false
4,222
r
context("map_layers") test_that("layerId includes all layers", { layers <- c( "animated_arc" , "animated_line" , "arc" , "bitmap" , "column" , "geojson" , "greatcircle" , "grid" , "h3" , "heatmap" , "hexagon" , "line" , "mesh" , "path" , "pointcloud" , "polygon" , "scatterplot" , ...
##### # PACKAGES ##### library(rgdal) library(readr) library(readxl) library(ggplot2) library(dplyr) ##### # DIRECTORIES ##### #wd <- getwd() # Be in the mortality_map/code directory -- change only if needed ##### # LOAD CHEN'S DATA ##### df <- read_excel('../data/dataofcountries.xls') ##### # LOAD IN THE WORLD SHAP...
/chen/mortality_map/code/make_maps.R
no_license
joebrew/uf
R
false
false
7,225
r
##### # PACKAGES ##### library(rgdal) library(readr) library(readxl) library(ggplot2) library(dplyr) ##### # DIRECTORIES ##### #wd <- getwd() # Be in the mortality_map/code directory -- change only if needed ##### # LOAD CHEN'S DATA ##### df <- read_excel('../data/dataofcountries.xls') ##### # LOAD IN THE WORLD SHAP...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/generated_client.R \name{scripts_post_containers_clone} \alias{scripts_post_containers_clone} \title{Clone this Container Script} \usage{ scripts_post_containers_clone( id, clone_schedule = NULL, clone_triggers = NULL, clone_notificat...
/man/scripts_post_containers_clone.Rd
no_license
elsander/civis-r
R
false
true
7,911
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/generated_client.R \name{scripts_post_containers_clone} \alias{scripts_post_containers_clone} \title{Clone this Container Script} \usage{ scripts_post_containers_clone( id, clone_schedule = NULL, clone_triggers = NULL, clone_notificat...
library(raster) library(RColorBrewer) library(lattice) library(rasterVis) r = stack("../Data files/modis.tif") min_div = min(r,na.rm=TRUE) min_val = min(r[[1]],na.rm = TRUE) range_ndvi = range(r,na.rm = TRUE) numero_layers = nlayers(range_ndvi) levelplot(stack(r[[1]]), par.settings = RdBuTheme, contour = FALSE)
/map_algebra.R
no_license
geosconsulting/geospatial_analysis
R
false
false
314
r
library(raster) library(RColorBrewer) library(lattice) library(rasterVis) r = stack("../Data files/modis.tif") min_div = min(r,na.rm=TRUE) min_val = min(r[[1]],na.rm = TRUE) range_ndvi = range(r,na.rm = TRUE) numero_layers = nlayers(range_ndvi) levelplot(stack(r[[1]]), par.settings = RdBuTheme, contour = FALSE)
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/ggTrace.R \name{ggTrace} \alias{ggTrace} \title{ggTrace} \usage{ ggTrace(output, pars, title = "") } \arguments{ \item{output}{BayesTraits MCMC output - output from btmcmc function.} \item{pars}{The paramater you want to see an autocorrelati...
/man/ggTrace.Rd
no_license
hferg/btrtools
R
false
true
407
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/ggTrace.R \name{ggTrace} \alias{ggTrace} \title{ggTrace} \usage{ ggTrace(output, pars, title = "") } \arguments{ \item{output}{BayesTraits MCMC output - output from btmcmc function.} \item{pars}{The paramater you want to see an autocorrelati...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/sexRatioTest.R \name{print.sexRatioTest} \alias{print.sexRatioTest} \title{\code{print()} helper function for \code{sexRatioTest()} function} \usage{ \method{print}{sexRatioTest}(x, ...) } \arguments{ \item{x}{Output resulting from applying t...
/man/print.sexRatioTest.Rd
no_license
SaeedR1987/nipnTK
R
false
true
906
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/sexRatioTest.R \name{print.sexRatioTest} \alias{print.sexRatioTest} \title{\code{print()} helper function for \code{sexRatioTest()} function} \usage{ \method{print}{sexRatioTest}(x, ...) } \arguments{ \item{x}{Output resulting from applying t...
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/fdo.R \docType{data} \name{fdo_leagueCodes} \alias{fdo_leagueCodes} \title{fdo_leagueCodes} \format{A data frame with 3 variables: \describe{ \item{\code{leagueCode}}{The League Code as a string e.g. "PL" represents Premier League...
/man/fdo_leagueCodes.Rd
permissive
biglongnow/footballR
R
false
true
736
rd
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/fdo.R \docType{data} \name{fdo_leagueCodes} \alias{fdo_leagueCodes} \title{fdo_leagueCodes} \format{A data frame with 3 variables: \describe{ \item{\code{leagueCode}}{The League Code as a string e.g. "PL" represents Premier League...
#' ATE and ATT functions #' #' Computes ATE and ATT from data and nuisance parameters as in DoubleML p.35 (Chernozhukov et al., 2017) #' Last edited: 11/01/2018 #' #' @param y vector of the dependent variable #' @param D vector of treatment assignment #' @param g1 estimate of E(Y_1 \vert X) #' @param g0 estimate of E(...
/functions/ATE.R
no_license
zhangc927/hdmetrics
R
false
false
1,402
r
#' ATE and ATT functions #' #' Computes ATE and ATT from data and nuisance parameters as in DoubleML p.35 (Chernozhukov et al., 2017) #' Last edited: 11/01/2018 #' #' @param y vector of the dependent variable #' @param D vector of treatment assignment #' @param g1 estimate of E(Y_1 \vert X) #' @param g0 estimate of E(...
rm(list=ls()) source(file="connectTodb.R") query="select * from high_repu" high<-dbGetQuery(con,query) query="select * from mid_repu" mid<-dbGetQuery(con,query) query="select * from low_repu" low<-dbGetQuery(con,query) rm(con,query) par(mfrow=c(1,5)) level_contrib<-rbind(cbind(high,type="H"),cbind(mid,type="M"),cb...
/replications/Rastogi_2016/R/level_of_contribution.R
permissive
micheledinanni/Psychometric-tools-benchmark
R
false
false
1,388
r
rm(list=ls()) source(file="connectTodb.R") query="select * from high_repu" high<-dbGetQuery(con,query) query="select * from mid_repu" mid<-dbGetQuery(con,query) query="select * from low_repu" low<-dbGetQuery(con,query) rm(con,query) par(mfrow=c(1,5)) level_contrib<-rbind(cbind(high,type="H"),cbind(mid,type="M"),cb...
## Objective: Optimize performance for Inverse Vector by caching result ## Execution example: ## m <- makeCacheMatrix( matrix( rnorm(16) , nrow=4 , ncol=4) ) // cache original matrix ## cacheSolve( m ) // return inverse matrix ## cacheSolve( m ) // second ...
/cachematrix.R
no_license
bertranddol/ProgrammingAssignment2
R
false
false
1,326
r
## Objective: Optimize performance for Inverse Vector by caching result ## Execution example: ## m <- makeCacheMatrix( matrix( rnorm(16) , nrow=4 , ncol=4) ) // cache original matrix ## cacheSolve( m ) // return inverse matrix ## cacheSolve( m ) // second ...
#' @title Sample Correlation Coefficient (r) #' @name r #' @description It estimates the Pearson's coefficient of correlation (r) for a continuous predicted-observed dataset. #' @param data (Optional) argument to call an existing data frame containing the data. #' @param obs Vector with observed values (numeric). #' @p...
/R/reg_r.R
permissive
adriancorrendo/metrica
R
false
false
2,185
r
#' @title Sample Correlation Coefficient (r) #' @name r #' @description It estimates the Pearson's coefficient of correlation (r) for a continuous predicted-observed dataset. #' @param data (Optional) argument to call an existing data frame containing the data. #' @param obs Vector with observed values (numeric). #' @p...
require("biomaRt") ensembl <- useEnsembl(biomart = "genes", dataset = "hsapiens_gene_ensembl") res <- getBM(c("ensembl_gene_id", "ensembl_transcript_id", "5_utr_start", "5_utr_end", "3_utr_start", "3_utr_end"), mart=ensembl, filter="with_hgnc", values=TRUE) res <- res[!(is.na(res[,3]) & is.na(res[,4]) & is.na(res[,5...
/download_UTRs_Ensembl.R
no_license
yingstat/snRNAseq_Pipeline
R
false
false
501
r
require("biomaRt") ensembl <- useEnsembl(biomart = "genes", dataset = "hsapiens_gene_ensembl") res <- getBM(c("ensembl_gene_id", "ensembl_transcript_id", "5_utr_start", "5_utr_end", "3_utr_start", "3_utr_end"), mart=ensembl, filter="with_hgnc", values=TRUE) res <- res[!(is.na(res[,3]) & is.na(res[,4]) & is.na(res[,5...
# calculate_irl_setup.R # Bryan Holman || v0.1 || 20170501 # Given the GEFS ensemble data just downloaded, this R script calculates the # setup according to the procedure outlined in Colvin et al. (2016). # v0.1 -> Calculates wind run for each GEFS ensemble member using the # interpolated data only. No bias correctio...
/R/calculate_irl_setup.R
permissive
FL-ASGS/IRLSetup
R
false
false
7,415
r
# calculate_irl_setup.R # Bryan Holman || v0.1 || 20170501 # Given the GEFS ensemble data just downloaded, this R script calculates the # setup according to the procedure outlined in Colvin et al. (2016). # v0.1 -> Calculates wind run for each GEFS ensemble member using the # interpolated data only. No bias correctio...
/R/encodeOntargetGeno.R
no_license
lje00006/DeepCpf1
R
false
false
2,796
r
#Matrices matrix(0, 3, 4) a <- 1:12 print(a) matrix(a, 3, 4) plank <- 1:8 dim(plank) <- c(2, 4) print(plank) matrix(1, 5, 5) #Matrix Access print(plank) plank[2, 3] plank[1,4] plank[1, 4] <- 0 plank[2,] plank[, 4] plank[, 2:4] #Matrix Plotting elevation <- matrix(1, 10, 10) elevation[4, 6] <- 0 contour(elevation) ...
/3.R
no_license
Evonne0623/Try-R
R
false
false
426
r
#Matrices matrix(0, 3, 4) a <- 1:12 print(a) matrix(a, 3, 4) plank <- 1:8 dim(plank) <- c(2, 4) print(plank) matrix(1, 5, 5) #Matrix Access print(plank) plank[2, 3] plank[1,4] plank[1, 4] <- 0 plank[2,] plank[, 4] plank[, 2:4] #Matrix Plotting elevation <- matrix(1, 10, 10) elevation[4, 6] <- 0 contour(elevation) ...
#' Find and hide dataset names in a package that match a class. #' #' @param package String; Package name to search datasets in. #' @param .class Class of data to find or hide. #' #' @examples #' show_data_of_class("fgeo.tool", "tbl") #' hide_data_of_class("fgeo.tool", "data.frame") #' #' @family functions for devel...
/R/find_data_of_class.R
no_license
forestgeo/fgeo.misc
R
false
false
1,104
r
#' Find and hide dataset names in a package that match a class. #' #' @param package String; Package name to search datasets in. #' @param .class Class of data to find or hide. #' #' @examples #' show_data_of_class("fgeo.tool", "tbl") #' hide_data_of_class("fgeo.tool", "data.frame") #' #' @family functions for devel...
###########10X_5cl process10x_rmDupGenes <- function(genebycellmat){ tb = genebycellmat tb <- tb[rowSums(tb) > 0,] gn = rownames(tb) rs <- rowSums(tb) kid <- sapply(unique(gn),function(sid) { tmp <- which(gn==sid) if (length(tmp)==1) { tmp ...
/reproducibility/Down-stream Analysis Improvement/raw_scripts/DEG_10x_5cl.r
permissive
iyhaoo/DISC
R
false
false
25,571
r
###########10X_5cl process10x_rmDupGenes <- function(genebycellmat){ tb = genebycellmat tb <- tb[rowSums(tb) > 0,] gn = rownames(tb) rs <- rowSums(tb) kid <- sapply(unique(gn),function(sid) { tmp <- which(gn==sid) if (length(tmp)==1) { tmp ...
#' @rdname website #' @title Bucket Website configuration #' @description Get/Put/Delete the website configuration for a bucket. #' #' @template bucket #' @param request_body A character string containing an XML request body, as defined in the specification in the \href{http://docs.aws.amazon.com/AmazonS3/latest/A...
/R/website.R
no_license
dgruenew/aws.s3
R
false
false
1,831
r
#' @rdname website #' @title Bucket Website configuration #' @description Get/Put/Delete the website configuration for a bucket. #' #' @template bucket #' @param request_body A character string containing an XML request body, as defined in the specification in the \href{http://docs.aws.amazon.com/AmazonS3/latest/A...
# Script preprocesses file containing epistatic interactions in TGEN cohort. library(gProfileR) # Read the file epi <- read.table(file = "~/absb/data/epistasis/TGEN_epistasis.tsv", header = T) # Create the folder where current results will be written resdir <- "~/absb/results/epistasis/" dir.create(file.path(resdir),...
/scripts/epistasis/epi_tgen.R
no_license
Mozihua/AgedBrainSYSBIO
R
false
false
5,436
r
# Script preprocesses file containing epistatic interactions in TGEN cohort. library(gProfileR) # Read the file epi <- read.table(file = "~/absb/data/epistasis/TGEN_epistasis.tsv", header = T) # Create the folder where current results will be written resdir <- "~/absb/results/epistasis/" dir.create(file.path(resdir),...
rm(list=ls()) library(knitr) library(plotrix) # Set up the experiment values set.seed(1230) par(xpd=NA) lambda <- 0.2 n <- 40 # Generate the random variables for these n values par(mfrow = c(2,2)) for (no_sim in c(10, 100, 1000, 10000)){ meanValue <- NULL meanSD <- NULL for (i in 1:no_sim){ values <- re...
/StatisticsProject/simulation.R
no_license
yywxenia/datasciencecoursera
R
false
false
2,371
r
rm(list=ls()) library(knitr) library(plotrix) # Set up the experiment values set.seed(1230) par(xpd=NA) lambda <- 0.2 n <- 40 # Generate the random variables for these n values par(mfrow = c(2,2)) for (no_sim in c(10, 100, 1000, 10000)){ meanValue <- NULL meanSD <- NULL for (i in 1:no_sim){ values <- re...
my.approx.match <- function(mSetObj=NA, q, lipid){ mSetObj <- .get.mSet(mSetObj); if(anal.type %in% c("msetora", "msetssp", "msetqea") & lipid){ cmpd.db <- .get.my.lib("lipid_compound_db.qs"); }else if(anal.type == "utils"){ cmpd.db <- .get.my.lib("master_compound_db.qs"); }else{ cmpd.db <- .get.m...
/R/util_approx.R
permissive
xia-lab/MetaboAnalystR
R
false
false
5,319
r
my.approx.match <- function(mSetObj=NA, q, lipid){ mSetObj <- .get.mSet(mSetObj); if(anal.type %in% c("msetora", "msetssp", "msetqea") & lipid){ cmpd.db <- .get.my.lib("lipid_compound_db.qs"); }else if(anal.type == "utils"){ cmpd.db <- .get.my.lib("master_compound_db.qs"); }else{ cmpd.db <- .get.m...
path <- "F://Coursera/Johns Hopkins Data Science Specialization//4. Exploratory Data Analysis//Project//exdata-data-household_power_consumption" setwd(path) full.data <- read.table("household_power_consumption.txt", na.strings="?" , sep=";", header=TRUE) data <- full.data[(full.data$Date=="1/2/2...
/plot1.R
no_license
taha-islam/exdata-data-household_power_consumption
R
false
false
607
r
path <- "F://Coursera/Johns Hopkins Data Science Specialization//4. Exploratory Data Analysis//Project//exdata-data-household_power_consumption" setwd(path) full.data <- read.table("household_power_consumption.txt", na.strings="?" , sep=";", header=TRUE) data <- full.data[(full.data$Date=="1/2/2...
message("03_define_grid.R") grid <- tribble( ~algo, ~hyper, # glmnet # LASSO "glmnet", list(alpha = 1, lambda = 10^seq(10, -2, length = 100)), # # RIDGE "glmnet", list(alpha = 0, lambda = 10^seq(10, -2, length = 100)), # kknn "kknn", list(k = seq(from = 1, by = 4, length.out = 20)), # e10...
/R/03_define_grid.R
permissive
unmnn/evoxploit_scirep
R
false
false
1,784
r
message("03_define_grid.R") grid <- tribble( ~algo, ~hyper, # glmnet # LASSO "glmnet", list(alpha = 1, lambda = 10^seq(10, -2, length = 100)), # # RIDGE "glmnet", list(alpha = 0, lambda = 10^seq(10, -2, length = 100)), # kknn "kknn", list(k = seq(from = 1, by = 4, length.out = 20)), # e10...
## validate output of sw_1_calculate_summaries.R ##==## load and validate summaries: treatment dose_uM CMAX comparison over cell lines/ replicates files_paths <- dir('generated/results/processed summaries', ) ##==## basic quality control plotting of all data
/sw_2_validate_sw_1_summaries.R
no_license
Hardervidertsie/DILItimepoint
R
false
false
264
r
## validate output of sw_1_calculate_summaries.R ##==## load and validate summaries: treatment dose_uM CMAX comparison over cell lines/ replicates files_paths <- dir('generated/results/processed summaries', ) ##==## basic quality control plotting of all data
rm(list = ls()) library(Daniel) library(dplyr) library(nnet) CalcCImultinom <- function(fit) { s <- summary(fit) coef <- s$coefficients ses <- s$standard.errors ci.1 <- coef[1,2] + c(-1, 1)*1.96*ses[1, 2] ci.2 <- coef[2,2] + c(-1, 1)*1.96*ses[2, 2] return(rbind(ci.1,ci.2)) } #key # A, B,C,D,E,F - betaE[2] =...
/Simulations/Scripts/R/Rare/Scenario 14/CMPEn50KrareScen14BC.R
no_license
yadevi/CausalMPE
R
false
false
4,220
r
rm(list = ls()) library(Daniel) library(dplyr) library(nnet) CalcCImultinom <- function(fit) { s <- summary(fit) coef <- s$coefficients ses <- s$standard.errors ci.1 <- coef[1,2] + c(-1, 1)*1.96*ses[1, 2] ci.2 <- coef[2,2] + c(-1, 1)*1.96*ses[2, 2] return(rbind(ci.1,ci.2)) } #key # A, B,C,D,E,F - betaE[2] =...
library(tidyverse) library(gtools) # load data #### load('data/daf_fst.RData') #### QC of variant data #### # does quality depend on read depth? dvar %>% filter(qual < 999) %>% ggplot(aes(raw_depth, qual)) + geom_point(alpha=0.05) + scale_x_log10() # qual ~ read depth plot dvar %>% filter(qual < 999) %>% mu...
/data-qa.R
no_license
matiasgoco/islands-paper
R
false
false
3,011
r
library(tidyverse) library(gtools) # load data #### load('data/daf_fst.RData') #### QC of variant data #### # does quality depend on read depth? dvar %>% filter(qual < 999) %>% ggplot(aes(raw_depth, qual)) + geom_point(alpha=0.05) + scale_x_log10() # qual ~ read depth plot dvar %>% filter(qual < 999) %>% mu...
## 1. removed entries in linneaus.csv data that had no species #IB: Data comming from??? show read.data or refer to the file were loaded #clean_linneaus=linneaus[c(1:294, 296:367, 369:474, 476:495, 497:538),] # ## 2. grouped factors into categories # ## create new column by using micro-habitat data # clean_linneaus$H...
/joe_edits.R
no_license
ibartomeus/linnaeus2.0
R
false
false
5,539
r
## 1. removed entries in linneaus.csv data that had no species #IB: Data comming from??? show read.data or refer to the file were loaded #clean_linneaus=linneaus[c(1:294, 296:367, 369:474, 476:495, 497:538),] # ## 2. grouped factors into categories # ## create new column by using micro-habitat data # clean_linneaus$H...
## Hijack a function ## see: http://stackoverflow.com/a/25366322/1000343 hijack <- function(FUN, ...){ .FUN <- FUN args <- list(...) invisible(lapply(seq_along(args), function(i) { formals(.FUN)[[names(args)[i]]] <<- args[[i]] })) .FUN } ## Ellipsis recieving function changing elli <- fu...
/R/utils.R
no_license
trinker/discon
R
false
false
1,873
r
## Hijack a function ## see: http://stackoverflow.com/a/25366322/1000343 hijack <- function(FUN, ...){ .FUN <- FUN args <- list(...) invisible(lapply(seq_along(args), function(i) { formals(.FUN)[[names(args)[i]]] <<- args[[i]] })) .FUN } ## Ellipsis recieving function changing elli <- fu...
data <- read.table("household_power_consumption.txt", header=T, sep = ";", stringsAsFactors = F, dec = ".") data$Date <- as.Date(data$Date, format="%d/%m/%Y") subdata <- data[data$Date == "2007-02-01" | data$Date == "2007-02-02",] png("plot1.png", width=480, height=480) hist(as.numeric(subdata$Global_active_power), co...
/plot1.R
no_license
takanyaotomo/ExData_Plotting1
R
false
false
407
r
data <- read.table("household_power_consumption.txt", header=T, sep = ";", stringsAsFactors = F, dec = ".") data$Date <- as.Date(data$Date, format="%d/%m/%Y") subdata <- data[data$Date == "2007-02-01" | data$Date == "2007-02-02",] png("plot1.png", width=480, height=480) hist(as.numeric(subdata$Global_active_power), co...
#' Creates a plotly manhattan plot #' #' Creates an interactive manhattan plot with multiple annotation options #' #' @param x Can be an object of class \code{manhattanr} produced by the #' \code{\link{manhattanr}} function or a \code{data.frame} which must contain #' at least the following three columns: \itemize{...
/R/manhattanly.R
no_license
FloWuenne/manhattanlyCRISPR
R
false
false
23,730
r
#' Creates a plotly manhattan plot #' #' Creates an interactive manhattan plot with multiple annotation options #' #' @param x Can be an object of class \code{manhattanr} produced by the #' \code{\link{manhattanr}} function or a \code{data.frame} which must contain #' at least the following three columns: \itemize{...
process_hours <- function(day_hour, senior = FALSE) { days_long <- c("Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday", "Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday", "Sunday") days_col_normal <- c("mon", "tues", "wed", "thr", "fri", "sat", "sun", "mon", "tues", "...
/megamap/data_extraction_and_formatting/debugging_process_hours.R
permissive
codeforsanjose/bac-resources
R
false
false
3,644
r
process_hours <- function(day_hour, senior = FALSE) { days_long <- c("Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday", "Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday", "Sunday") days_col_normal <- c("mon", "tues", "wed", "thr", "fri", "sat", "sun", "mon", "tues", "...
require(ggplot2) # Get data wdfiles <- list.files(".") if( !"data.zip" %in% wdfiles ) { print( "Downloading files." ); download.file( "https://d396qusza40orc.cloudfront.net/exdata%2Fdata%2FNEI_data.zip", "data.zip", method="curl" ) } if( !all( c("Source_Classification_Code.rds", "summarySCC_PM25.rds") %in% wd...
/plot6.R
no_license
axelgafu/ExploratoryDataAnalysis-Project2
R
false
false
1,525
r
require(ggplot2) # Get data wdfiles <- list.files(".") if( !"data.zip" %in% wdfiles ) { print( "Downloading files." ); download.file( "https://d396qusza40orc.cloudfront.net/exdata%2Fdata%2FNEI_data.zip", "data.zip", method="curl" ) } if( !all( c("Source_Classification_Code.rds", "summarySCC_PM25.rds") %in% wd...