sha256
stringlengths
64
64
language
stringclasses
27 values
size
int32
1
491k
lines
int32
1
21.8k
content
stringlengths
1
200k
b66edc20bc8a13862898236c6fb9a5853e33ad53284c1ebeaf971e53684ccf3b
R
5,652
197
--- title: "Mixed effect model for batch correction" author: "Joyce Hsiao" date: 2016-01-12 --- **Last updated:** `r Sys.Date()` **Code version:** `r system("git log -1 --format='%H'", intern = TRUE)` ```{r chunk-options, include=FALSE} source("chunk-options.R") ``` ## Objective Update the batch-corrected counts...
22a62120db903361fbab23f5c5b0378d4724c2517a52f4bf0ab9bef24bcd2f0a
R
5,666
168
# Created on Thu Jul 13 17:50:17 2021 # Name: gradients_correlation_ranking.R # Purpose: Selects the top n (number of synapses) post for a given pre and # evaluates the Pearson's correlation coefficient between all possible # pairs. # Author: Andrea Vaccari (avaccari@middlebury.edu) # # Generates:...
cdb8b546ead9cdfbace7b2a47a8a2b8ce4aacfe8a5ab3fcd1a9e59ef41f6e007
R
5,670
175
--- title: "ERCC counts" author: "PoYuan Tung" date: 2015-07-07 --- **Last updated:** `r Sys.Date()` **Code version:** `r system("git log -1 --format='%H'", intern = TRUE)` ```{r chunk-options, include=FALSE} source("chunk-options.R") library("edgeR") library("ggplot2") theme_set(theme_bw(base_size = 14)) ``` ## I...
38c19ba3553786a1903d93ab88ccabf2f03df8bfc5d0c620e3a2687bd2ed0d69
R
5,699
117
## ----setup list.of.packages <- c("dplyr", "vegan", "BiocManager", "mlr3") new.packages <- list.of.packages[!(list.of.packages %in% installed.packages()[,"Package"])] if(length(new.packages)) install.packages(new.packages, lib = .libPaths()[2], ...
60cd68ede3b59a2ac35c852c33d2215b424b39087384e534c35bb9f006055f49
R
5,707
127
#Code for sup figure 4 #Panel A: HD encoding accuracy for both cues initial_offset_precision_data <- read.csv("C:/Users/mbasn/Dropbox/Manuscript-Basnak/Nat Neurosci Aug 2024 revision/zenodo/Ext_data_fig_4_analysis/initial_offset_precision_data.csv") initial_offset_precision_data <- initial_offset_precision_da...
4c082fd21f42274fe815f9e55b38aa542a065f00c74278a40d590c61d4ecd8d2
R
5,731
186
--- title: "model coeff." author: "SRomano" output: html_document editor_options: chunk_output_type: console --- # Load packages ```{r setup} library(phyloseq) library(vegan) library(dplyr) library(tidyverse) library(SIAMCAT) # load my function to run siamcat source("/Scripts/Model_coefficient_extraction.r") set....
38798a0430d024efdb4c36a8f6d787a6bda8adfd75ea66d5cc9036ca666f2683
R
5,734
111
#There are two replicates.Replicate1 contains five plates (P0_CD133_RGC_Plate1-5) and replicate2 contains three plates (P0_CD133_RGC_Plate6-8).Here P0_CD133_RGC_Plate1 is used as an example. #1 Building the genome index of mm10 STAR --runThreadN 20 --runMode genomeGenerate \ --genomeDir STAR_index/mm10/ \ --genomeFast...
5672f3ab09e3155e1150d7ab982e6158cc6eb11d6643c0a8dd7d028732595b1d
R
5,748
171
# R Corbett 2024 # # Generate somalier principal component Kaplan-Meier survival curves and forest plots for PBTA ancestry cohort # Load packages library(tidyverse) library(survival) library(patchwork) library(colorblindr) # Define directory paths root_dir <- rprojroot::find_root(rprojroot::has_dir(".git")) analysis...
fc23da3a7b01f28e645af9826e5a61090a0bd47d9ef3b76ca7d657143248bf15
R
5,750
131
############################################## # smFISHHMRF Benchmarking - Kidney 10x Visium # Authors: Mauminah Raina ############################################## library(Giotto) library(smfishHmrf) # Embeddings - Sample SSL57 counts <-read.csv(paste0("/N/slate/mraina/REGNN_final/REGNN_SSL/result/Embeddings...
c8b7aee30e9e9c93b9cddec05f99ebe88f3b6a3fe192e54cefd0dccd1bb32a78
R
5,774
143
--- title: 'Merge PBTA ancestry and histology data' output: html_document: toc: TRUE toc_float: TRUE author: Ryan Corbett date: "2023" --- Load libraries and set directories ```{r load libraries and set directories} library(data.table) library(tidyverse) root_dir <- rprojroot::find_root(rprojroot::has_dir("...
c807e242b25f70ef19b5ad76a0f2ff34189b504f5931b761f4b36fa800570142
R
5,783
214
--- title: "RNAscope pseudobulk shuffle final iteration, cohort1" author: "Sean Maden" date: "2023-09-03" output: pdf_document: default html_document: default --- This notebook shows a pseudobulk shuffle experiment in which $S_{deconvolution}$ is shuffled. # Variables Descriptions of the variables used. Find ref...
00c78291bc6003da3e02b52e48532ad32f02041eb87100b8be57c8c93fd9675f
R
5,796
161
rm(list = ls()) library(ggplot2) library(cluster) library(ggdendro) library(dendextend) library(factoextra) Project_path = '/Users/panguoqing/Desktop/help/project' Save_path = paste(Project_path, 'Data/CaseControl', sep = '/') data_FieldID = read.csv(paste(Project_path, 'Data/CaseControl/data_FieldID.csv', sep = '/')...
7ff71c33b4139a3dd55e6ecb650c91569cce520f43d9bec7c4314b0d8ab349d5
R
5,798
198
--- title: "Potential batch effect in the ordering effect of the capture sites" author: "Joyce Hsiao" date: 2015-10-02 --- **Last updated:** `r Sys.Date()` **Code version:** `r system("git log -1 --format='%H'", intern = TRUE)` ```{r chunk-options, include=FALSE} source("chunk-options.R") ``` ## Objective We inves...
39841b5f13bfa4e406873b552875cd6e8497719c97133b2d9f7773bdc80dbd4b
R
5,813
193
#' Fit (generalised) linear random effects model robustly, checking for convergence #' #' This function fits a (G)LME. If the fit does not converge, it will try different #' optimisers, and if still not converging will remove the integration over random effects. #' #' @param mdl_formula Complete model formula #' @param...
acf910dcd5e84a726288b7443c34db802abe31a58e15f9d9527fead8791fb003
R
5,829
170
# R Corbett 2023 # # Generate Kaplan-Meier survival curves and forest plots for PBTA ancestry cohort # Load packages library(tidyverse) library(survival) library(patchwork) library(colorblindr) # Define directory paths root_dir <- rprojroot::find_root(rprojroot::has_dir(".git")) analysis_dir <- file.path(root_dir, "a...
0df612abe913efebcabbaf4518393544ec7ff51011c2645f83f72d45daaab16b
R
5,834
190
--- title: "Subsample high coverage single cells" date: 2015-07-13 --- **Last updated:** `r Sys.Date()` **Code version:** `r system("git log -1 --format='%H'", intern = TRUE)` ```{r chunk-options, include=FALSE} source("chunk-options.R") ``` ```{r message=FALSE} library("dplyr") library("ggplot2") library("cowplot"...
0a63823fb8dd39fd53abcb61249576606895e53e2fc960ea08a660a4d5952e54
R
5,839
227
--- title: "01_run" author: "Sean Maden" date: "2023-10-17" output: pdf_document: default html_document: default --- ```{r setup, include=FALSE} libv <- c("ggplot2", "gridExtra") sapply(libv, library, character.only = TRUE) knitr::opts_chunk$set(echo = FALSE) setwd("..") setwd("..") load("./env/01_pseudobulk/01_re...
775858f45cabb7f9a6be42e4c1452cc0b0a7dc80d310221aa852e498ba240526
R
5,846
188
numCorGenes <- function(corr, corr_t, corr_min){ corr_thres = abs(corr) > corr_t length(which(colSums(corr_thres) > corr_min)) } getCorThreshold <- function(corr, init_corr_t=.2, numgenes_target=1500, corr_min=3, numcores=3){ corr_t <- init_corr_t while( numCorGenes(corr, corr_t, corr_min=corr_min) >= ...
2bae4843b349c743f53d3d21290391f56d43bc4f6352fdcd0a5813a3c27134ec
R
5,862
180
--- title: "Coverage of endogenous genes - bulk reads" date: 2015-02-23 --- **Last updated:** `r Sys.Date()` **Code version:** `r system("git log -1 --format='%H'", intern = TRUE)` ```{r chunk-options, include=FALSE} source("chunk-options.R") opts_chunk$set(cache = TRUE) ``` The sequencing coverage from the UMI pro...
376388f46e65649a56d8a423e22cb3fff9adc23dcf9caf3cb6d1b9c92615dcbc
R
5,873
206
#' VR Threat ggplot theme #'#' #' @param base_size Base font size #' @param base_family Base font familt #' #' @return A ggplot theme object. #' @export #' #' @examples theme_vrthreat <- function(base_size=14, base_family="sans") { ggplot2::theme_classic(base_size = base_size, base_family = base_family) ggplot2::th...
f62a502e7c932d31c58a0e5efc4c6dfed6efbba71d3e6da1be7b8ca6ecb88c3a
R
5,880
186
--- title: "Coverage of endogenous genes" date: 2015-02-22 --- **Last updated:** `r Sys.Date()` **Code version:** `r system("git log -1 --format='%H'", intern = TRUE)` ```{r chunk-options, include=FALSE} source("chunk-options.R") opts_chunk$set(cache = TRUE) ``` The sequencing coverage from the UMI protocol should ...
9ad8f8fd6a7e2fc09bb317ccf725cf5932c8f158315865a184aee2e82805db90
R
5,889
187
--- title: "Coverage of endogenous genes - single cell reads" date: 2015-02-23 --- **Last updated:** `r Sys.Date()` **Code version:** `r system("git log -1 --format='%H'", intern = TRUE)` ```{r chunk-options, include=FALSE} source("chunk-options.R") opts_chunk$set(cache = TRUE) ``` The sequencing coverage from the ...
f96dfab826287c16bb8cb316e5a12340039d82df8a31affb0a2d5ee3969dbe71
R
5,890
209
--- title: "Process sequence data - LCLs" author: "John Blischak" date: 2015-04-11 --- **Last updated:** `r Sys.Date()` **Code version:** `r system("git log -1 --format='%H'", intern = TRUE)` PoYuan performed the original troubleshooting of the UMI protocol with LCLs from individual NA19239. One flow cell worked wel...
13c1ca807b674abc5906bebb9bb9489a7c86d6d34409d2a926720300eb56c419
R
5,900
152
#!/usr/bin/env Rscript # Command line argument processing args = commandArgs(trailingOnly=TRUE) if (length(args) < 5) { stop("Usage: dupRadar.r <input.bam> <annotation.gtf> <strandDirection:0=unstranded/1=forward/2=reverse> <paired/single> <nbThreads> <R-package-location (optional)>", call.=FALSE) } input_bam <- arg...
567e77f3c95390e92a952e094738687abb8ffdbce848d0147220f0a107522b8e
R
5,918
219
normalize_feature_values <- function(feature_values) { unique_values <- sort(unique(feature_values)) if (length(unique_values) == 1) { return(rep(1, length(feature_values))) } if (is.numeric(unique_values)) { low <- min(unique_values) high <- max(unique_values) return(unlist...
911ebd8806e2cd38aef61a25b413fecd32e026651df074e05b4716026aa973db
R
5,943
184
library(ArchR) library(stringr) library(ggplot2) library(dplyr) library(glue) library(parallel) library(Seurat) library(GenomicRanges) library(HDF5Array) library(SummarizedExperiment) library("tidyr") library(argparse) # Fig. 5c-f and ED Fig. 10c-h args = commandArgs(trailingOnly=TRUE) addArchRThreads(threads = 20)...
fca56909fba54c6649193d072235e23795da584be3bd90146f5370574757a175
R
5,963
143
# LRT for Timecourse FOXA2 OE RNA-Seq DE Analysis # Fig. 2A library(DESeq2) library(tidyverse) library(RColorBrewer) library(ComplexHeatmap) set.seed(7712) library(clusterProfiler) ## Read in counts and sample table ---------------------------------------------------------------------------------------------------- ...
615388aecae4e5b5e40537cb259583a99ae757ecd13f51fed31a0b1825d62828
R
5,971
222
--- title: "Plate reader growth curves of GAT201 mutants in RPMI media combining NaHCO3 and cAMP" author: "Liz Hughes & Edward Wallace" date: "05/03/2024" output: html_document: toc: yes toc_depth: 2 --- ```{r call_shared_functions_formatting, child = "shared_functions_formatting.Rmd"} ``` # Summary This e...
6350243626e90e619bb2915b3bbb5c1c3b80eed44338424bb573275b3c181b80
R
5,977
170
--- title: "Standardize with counts per million" date: 2015-09-30 --- **Last updated:** `r Sys.Date()` **Code version:** `r system("git log -1 --format='%H'", intern = TRUE)` ```{r chunk-options, include=FALSE} source("chunk-options.R") opts_chunk$set(fig.width = 8, fig.height = 8) ``` ```{r packages, message=FALSE...
2a86526e1a28ada323f36a08e9ce3049b9f7cf89350bb4232b416136af4d317d
R
5,993
131
#This is some code adapted from steps 8.1 and 8.2 of the 2024 protocol: #2024 protocol:https://www.protocols.io/view/brain-data-alchemy-project-meta-analysis-of-re-ana-yxmvmejkng3p/v1?step=8.2 #Megan Hagenauer, July 20, 2026 ############################################ #This part is a little different: #Starting wit...
acb16ec4e890291d24814fd8c73b8bb09b339021e87c584b8a1a25a39ada00bf
R
6,000
93
--- title: "Plot MCluster Methylation" --- ```{r Libraries, warning=FALSE, echo=FALSE} require(ggplot2) library(tidyverse) library(RColorBrewer) library(data.table) library(pheatmap) ``` # Visualize Methylation Clusters the clustering of regions by methylation values was done on accre using the script hclust.R. The fil...
99ec1d4d7040fc560aced9199d94f73dd6a22f46a7575491b90e021dc081d86f
R
6,012
194
--- output: html_document: toc: true --- **Last updated:** `r Sys.Date()` **Code version:** `r system("git log -1 --format='%H'", intern = TRUE)` At lower number of sampled cells, reads appear to perform better with lower sequencing. On the other hand, the molecules look as expected, higher sequencing depth le...
a6b643c5c799f6b52aa7b769fb5dbed7c51f5062175673b33ba302b0f1cdc212
R
6,029
195
--- output: html_document: toc: true --- **Last updated:** `r Sys.Date()` **Code version:** `r system("git log -1 --format='%H'", intern = TRUE)` At lower number of sampled cells, reads appear to perform better with lower sequencing. On the other hand, the molecules look as expected, higher sequencing depth le...
53cfec9868dec64571ede70b6c0014da3a7241f2ccec75fcf3c453dcaa86b3e5
R
6,069
159
#!/usr/bin/env Rscript "Compare the variance estimates of subsamples to all cells. Usage: subsample-variance.R [options] [--quantiles=<q>...] <num_cells> <seed> <exp> Options: -h --help Show this screen. --individual=<ind> Only use data from ind, e.g. 19098 --min_count=<x> The minimum c...
fe7ce00cd5d61d9c130902078abec30618b1ad9482a5a14af85901022543a88c
R
6,101
97
library(lme4) library(sjPlot) #for plotting lmer and glmer mods library(tidyverse) # Analysis of mean global efficiency after random and targeted attacks # 1. Mean was taken over sequential removal of random/targeted nodes # 2. AUC was taken over selected density thresholds (0.3-1) # 3. Here we perform # - A. a mixed ...
e6146eb0bfab0d433d4b34b2fbfbe0fdb21e3463c3899be05c0c0db6cbdd8762
R
6,102
169
--- title: "Account for technical noise measured with ERCC controls using Poisson GLM transformation" date: 2015-12-22 --- **Last updated:** `r Sys.Date()` **Code version:** `r system("git log -1 --format='%H'", intern = TRUE)` ```{r chunk-options, include=FALSE} source("chunk-options.R") opts_chunk$set(fig.width ...
52902ce6c91d89aa211536cbcdcd7d03d20d54b7e9984200078040ae76f95492
R
6,124
150
#Code for aligning limma results from different datasets #Megan Hagenauer #July 27, 2023 ############################### #I tweaked this code from last year to align using NCBIid within species AligningRatDatasets<-function(ListOfRatDEResults){ Rat_MetaAnalysis_FoldChange_Dfs<-list() for(i in c(1:length(Li...
60453bbb7faa91ac38a1baa359e375149acd328522d3696b67276843e54df4a3
R
6,131
158
############################################## # BayesSpace Benchmarking - Kidney 10x Visium # Authors: Chandrima Modak, Mauminah Raina ############################################## #Load required packages library(Matrix) library(BayesSpace) library(Seurat) library(SingleCellExperiment) library(ggplot2) li...
226a4d23919bb5fb38a71460275ce5626f64c68a437d985579f320688238a4c1
R
6,132
150
library(ggplot2) theme_Publication <- function(base_size = 14) { library(grid) library(ggthemes) (theme_foundation(base_size = base_size) + theme( plot.title = element_text( face = "bold", size = rel(1.2), hjust = 0.5 ), text = element...
9c7f73c2628193129ddb6c47346db02bb9e916e40b94833bb54d2cb810e69b50
R
6,162
237
--- title: "MDACC RNASeq QC for Anders lab MelBrM" author: "Marissa Lee, DCI Bioinformatics" date: '`r format(Sys.Date(), "%B %d, %Y")`' output: html_document: toc: true toc_depth: 2 toc_float: true code_folding: hide number_sections: true editor_options: chunk_output_type: console --- ```{r ...
963f041c8f2b9205f9c9be1ad789929de95856fff9e95ebe9b718f9d1ce5d01d
R
6,176
126
rm(list = ls()) library(ggplot2) library(ggrepel) library(ggbreak) require(dplyr) require(tidyr) require(RColorBrewer) Project_path = '/Users/panguoqing/Desktop/help/project' Save_path = paste(Project_path, 'Data/CaseControl', sep = '/') Threshold = 0.05 Threshold_1 = 0.01 Threshold_2 = 0.005 colors <- c('Blood count'...
dcc3e88df8e669b8abe982bddbf27bb3431326d92dc3eedca497f897e4bc23b9
R
6,178
134
### Tripsacum greenhouse experiment ### Phenotypic analysis ### Code by Joel Swift 04-2024 library(tidyverse) library(ggpubr) library(lme4) library(lmerTest) library(emmeans) # Theme set and Color Palettes theme_set(theme_bw()) treatment_palette <- c("Waterlogged 24" = "#26008E", "Waterlogged 4...
f130fc459b6c367273fa078868822934cf338a51b8f89ce3515ee42eee834cdd
R
6,184
195
--- title: "Create gene-x-sample count matrices and annotation file" date: 2015-09-30 --- **Last updated:** `r Sys.Date()` **Code version:** `r system("git log -1 --format='%H'", intern = TRUE)` ```{r chunk-options, include=FALSE} source("chunk-options.R") opts_chunk$set(fig.width = 8, fig.height = 8) ``` ```{r pac...
f6e1b8776151dc1abd0d430e283b0528884205b0e0cb826ea980ab7c9bf6a1fd
R
6,199
125
library(tidyverse) library(Signac) library(Seurat) library(patchwork) set.seed(1234) library(scCustomize) library(EnsDb.Hsapiens.v86) library(TxDb.Hsapiens.UCSC.hg38.knownGene) library(BSgenome.Hsapiens.UCSC.hg38) d14 <- readRDS("../single/simple_d14.RDS") d2 <- readRDS("../single_d2/simple_d2.RDS") d21 <- readRDS(".....
accaffacc9d60de5fab7b34cfab0aadec0504301c80f7ef37fe3340073d4bc14
R
6,204
244
# the whole structure newargs <- commandArgs(T) #1. input 1mb interaction frequency #2. backbone structure #3. 5kb result output directory #4. 5kb pairwise distance matrix #5. output result name input_if <- read.table(newargs[1]) #load("/mnt/ufs18/rs-027/compbio/wanglab/haowang/Proj10_recon_3D/output/chr21_...
a0ce316b49719afd636077f8a1824b9bed12d86f87e2594864c5dcd55bee8371
R
6,210
47
--- bibliography: refs.bib --- ```{r chunk-options, include=FALSE} source("chunk-options-paper.R") ``` ## Discussion ### Study design and sample size for scRNA-seq Our nested study design allowed us to explicitly estimate technical batch effects associated with single cell sample processing on the C1 platform. We f...
912b98399dabd0cfec5cbca5445a3792001616a72bd5e64ea60c778098f3617e
R
6,232
116
#Adding RNA-Seq Library Size to the summarized experiment for a dataset #Megan Hagenauer #July 20, 2023 #Set working directory: setwd("/Users/hagenaue/Dropbox (University of Michigan)/LaptopBackup_20221123/Teaching/BrainDataAlchemy") #load useful code packages library(SummarizedExperiment) library(gemma.R) library(pl...
83e9dc6a852708d80e66e4be21bc8b616578f470a9e4248a83a61a9de51c61d8
R
6,241
192
--- title: "Using ngsplot to calculate coverage over ERCC genes" date: 2015-03-15 --- **Last updated:** `r Sys.Date()` **Code version:** `r system("git log -1 --format='%H'", intern = TRUE)` ```{r chunk-options, include=FALSE} source("chunk-options.R") opts_chunk$set(cache = FALSE) ``` Here I use [ngsplot][] to cal...
230a5d33ddce0b133b76d3a38f0e8e54fb7ea777943c23fb71fad84c34712b28
R
6,242
175
# creates final plots for the Simulations of the PRS GXE project - Rev1 # grab command line arguments args = commandArgs(trailingOnly = TRUE) print("Arguments received:") print(args) if(length(args) < 2) {stop("not enough Arguments received")} baseLoc = args[1] outputLoc= args[2] plotName= args[3] # Debug vars # b...
432da736d93e9100b7cde79ba22467de46a51fa46c806b847330fcfe838fec43
R
6,252
176
--- title: "Coverage of ERCC spike-ins" date: 2015-02-22 --- **Last updated:** `r Sys.Date()` **Code version:** `r system("git log -1 --format='%H'", intern = TRUE)` ```{r chunk-options, include=FALSE} source("chunk-options.R") ``` This is a companion to the analysis of the [coverage of endogenous genes][endo]. It ...
636268995e9a3eea47f0ddd26859d75d7a224206d3a6de44bc82c1555f52d8b9
R
6,281
144
# LuNE RNA-Seq library(tidyverse) library(DESeq2) library(ComplexHeatmap) set.seed(7712) # CCS1477 Treatment DEGs Fig 7F ----------------- # mr399 to mr 404 ff <- list.files(path = "/projects/b1126/Viriya/rna-seq/mr399_mr404/", pattern = "*ReadsPerGene.out.tab$", full.names = TRUE) lune_counts.files <- lapply(ff, read...
aa9faff6ca8bbef9c5bf4bb25a4f46c48859674eff47220b10903c68b5ba4951
R
6,290
180
#!/usr/bin/env R # Author: Sean Maden #' musicParam-class #' #' Applies the MuSiC::music.basic() implementation of the MuSiC deconvolution #' algorithm. #' #' @include lute_generics.R #' @include referencebasedParam-class.R #' #' @details Main constructor for class \linkS4class{musicParam}. #' @rdname musicParam-c...
03f560cc706bf122ecae390a75d8e876d91e074340826f690fa93ef68d0d9da7
R
6,291
213
--- title: "Ordering effect of the capture sites" author: "Joyce Hsiao & Po-Yuang Tung" date: 2015-09-26 --- **Last updated:** `r Sys.Date()` **Code version:** `r system("git log -1 --format='%H'", intern = TRUE)` ```{r chunk-options, include=FALSE} source("chunk-options.R") ``` ## Goal We investigated potential o...
2692b198feb02fbd36b746509f38eafa5046d4ced595481907634458cd5acc54
R
6,304
110
# Environment setup section set.seed(0); rm(list = ls()); gc() load_pkg <- rlang::quos(tidyverse, tibble, readxl, dplyr, tidyr, reshape, patchwork, Seurat, ggcorrplot, ggplot2, rstatix, org.Mm.eg.db, org.Hs.eg.db, rjson, purrr, grid, pheatmap, sargent, biomaRt, enrichp...
045df089dfcb07e0d28d27c11fe7f8ad16a4f04915610bc06b2ed4d581e5a242
R
6,331
166
rm(list = ls()) library(ggplot2) library(lme4) library(lmerTest) library(dplyr) library(reshape) library(nlme) library(permuco) library(ggseg) library(stringr) library(mediation) library(lm.beta) code_location <- dirname(sys.frame(1)$ofile) source(paste0(code_location, '/model_funs.R')) source(paste0(code_location, '/...
b34d7e7d28e25d252bef624da1302a943d993e479f9580682db86e04547638b2
R
6,342
181
--- title: "Per gene statistical comparison of CVs" author: "Joyce Hsiao" date: 2015-11-12 --- **Last updated:** `r Sys.Date()` **Code version:** `r system("git log -1 --format='%H'", intern = TRUE)` ```{r chunk-options, include=FALSE} source("chunk-options.R") library(knitr) opts_chunk$set(message = FALSE, warning...
e399c5fea077baee8a34b1b0077d2728829277871239fd195c0b3e3d28889fa6
R
6,369
189
#'@export #'@title PTMwRapper #'@description a function that takes in input a report from spectronaut, #'candidates table, and condition setup. Run the PTMwRapper, and create #'a MultipleExperiment out of it. The wrapper summarize PTM site by #'their median abundance and run limma analysis out of it. #'to process the...
713c1fd3f1e727a6963d789077df0fd84d131051ff7b91aa580c0c49d6a7e10c
R
6,373
171
library(dplyr) library(readxl) library(ggplot2) library(ggrepel) library(enrichplot) library(clusterProfiler) library(org.Mm.eg.db) setwd("") # Figure_S14c, bar plot showing the protein numbers of quantified and identified proteins { rm(list=ls()) obj_list = readRDS(file = "ct_dataset_02.rds") temp.df = ...
7747ade4ea88a13d382557f86dd02a2faa8454018019e97dd38af076c473f34b
R
6,373
124
#Manuscript Figure 4c - phee syllabe duration or length plots and stats phee_duration<- phee.analysis%>% dplyr::mutate(subject= factor(subject))%>% dplyr::rename(duration=`Delta Time (s)`)%>% dplyr::filter(!(syllable %in% c("end", "start", "")))%>% ...
7baef03c2c88f693d46b9d48c8b3d10f8176f430efbff6f50e1d62bda6dd9573
R
6,392
114
--- title: Heatmap for Motif Enrichment Across time --- ```{r, load libraries, warning=FALSE, message=FALSE} library(tidyverse) library(data.table) library(RColorBrewer) library(pheatmap) ``` Read in files with and without background ```{r , message = FALSE} # (1) Get a list of files to iterate over setwd("/Users/linds...
d9b2ab75f97381098fe4ec53b62ca516fa5eaa9a6109440014332ddd538846e2
R
6,395
156
# Specify which metric to run this for (need to run twice to reproduce all plots) #metric = "r" metric = "rho" get_mylist = function(subset,metric) { # subset - list of TRUE/FALSE # metric - "r" or "rho" mylist = c(); pos = 0; at = c() tests = c("Seq_Enc","LossFn","Optimizer","LRScheduler","Model") for (tes...
fb96b42d3d635014500a3fb6bb1ae19d5b673bd230ff9054a244090a75a8104d
R
6,403
150
#STReEF05_Rmodel # This R code is developed for the manuscript 'Structural and # Effective brain connectivity in focal epilepsy' by Jelsma et al. # author: Susanne Jelsma # date: October 2021 # calculate the jaccard index, construct a linear multilevel model ----------------------------------------------------------...
0ac87a47c6354af7e6a8e2ef10af1d1a61ac5e4a9f9e86a78bf02da4aa429d7d
R
6,435
134
## ----setup list.of.packages <- c("dplyr", "vegan", "BiocManager", "mlr3") new.packages <- list.of.packages[!(list.of.packages %in% installed.packages()[,"Package"])] if(length(new.packages)) install.packages(new.packages, lib = .libPaths()[2], ...
4dde73a81355da5de3e1aff67166d74ae0e8b0c87e67b24f400f04cc133b7d2b
R
6,435
134
## ----setup list.of.packages <- c("dplyr", "vegan", "BiocManager", "mlr3") new.packages <- list.of.packages[!(list.of.packages %in% installed.packages()[,"Package"])] if(length(new.packages)) install.packages(new.packages, lib = .libPaths()[2], ...
428f3571301b2c63779d7ae9b60c5d97556e324adecdf57274c6e0445ec22194
R
6,440
131
rm(list = ls()) Project_path = '/Users/panguoqing/Desktop/help/project' Save_path = paste(Project_path, 'Data/CaseControl', sep = '/') library(ggplot2) library(reshape2) library(dplyr) library(cluster) library(NbClust) library(ggrepel) loess_predict_all = read.csv(paste(Project_path, "Data/CaseControl/S5_loess_predict_...
d12dedfeb136ae2cc64650b87a99f9b324228e2ae715785eeb1943b9bbd81b89
R
6,441
132
## ----setup list.of.packages <- c("dplyr", "vegan", "BiocManager", "mlr3") new.packages <- list.of.packages[!(list.of.packages %in% installed.packages()[,"Package"])] if(length(new.packages)) install.packages(new.packages, lib = .libPaths()[2], ...
972225a934180235d284ab38f1945da6d8ef7ac546c22e9a66c11eb509527469
R
6,448
132
## ----setup list.of.packages <- c("dplyr", "vegan", "BiocManager", "mlr3") new.packages <- list.of.packages[!(list.of.packages %in% installed.packages()[,"Package"])] if(length(new.packages)) install.packages(new.packages, lib = .libPaths()[2], ...
9961e1fea5f2faaa1668a86bc1ba8195a33c47b0566d004671f247e42540dbfa
R
6,448
132
## ----setup list.of.packages <- c("dplyr", "vegan", "BiocManager", "mlr3") new.packages <- list.of.packages[!(list.of.packages %in% installed.packages()[,"Package"])] if(length(new.packages)) install.packages(new.packages, lib = .libPaths()[2], ...
7ffd5635e6b03694d0315bb66e57cca30e4257e858378c1feda13de464307281
R
6,451
132
## ----setup list.of.packages <- c("dplyr", "vegan", "BiocManager", "mlr3") new.packages <- list.of.packages[!(list.of.packages %in% installed.packages()[,"Package"])] if(length(new.packages)) install.packages(new.packages, lib = .libPaths()[2], ...
3bcae1d6a10aa0119c81d77d3473bbf08f54657d039563399502ecee55c54f3d
R
6,454
134
## ----setup list.of.packages <- c("dplyr", "vegan", "BiocManager", "mlr3") new.packages <- list.of.packages[!(list.of.packages %in% installed.packages()[,"Package"])] if(length(new.packages)) install.packages(new.packages, lib = .libPaths()[2], ...
aed93ea9390590722117002ca4ba23770f7a1b779f9a7a48fe99fba704596d36
R
6,454
134
## ----setup list.of.packages <- c("dplyr", "vegan", "BiocManager", "mlr3") new.packages <- list.of.packages[!(list.of.packages %in% installed.packages()[,"Package"])] if(length(new.packages)) install.packages(new.packages, lib = .libPaths()[2], ...
4bd2f655828ae774b532c760c374e59579636ddbffc6e6ffc8cb973b97c98b3e
R
6,459
135
## ----setup list.of.packages <- c("dplyr", "vegan", "BiocManager", "mlr3") new.packages <- list.of.packages[!(list.of.packages %in% installed.packages()[,"Package"])] if(length(new.packages)) install.packages(new.packages, lib = .libPaths()[2], ...
712c414558f257bc6b7578a49fe9f24b5bd52ea19d38a9a7ca96719230c98cfc
R
6,459
135
## ----setup list.of.packages <- c("dplyr", "vegan", "BiocManager", "mlr3") new.packages <- list.of.packages[!(list.of.packages %in% installed.packages()[,"Package"])] if(length(new.packages)) install.packages(new.packages, lib = .libPaths()[2], ...
b0d56bb1e9ae1a898062f29ed4530cf7b1524e9b472c306a05c5cebcd78a2752
R
6,459
135
## ----setup list.of.packages <- c("dplyr", "vegan", "BiocManager", "mlr3") new.packages <- list.of.packages[!(list.of.packages %in% installed.packages()[,"Package"])] if(length(new.packages)) install.packages(new.packages, lib = .libPaths()[2], ...
b5fb1fa31a3506354204645a7feec1cb8910698804ce2af2f6c1dba19c13d58d
R
6,459
135
## ----setup list.of.packages <- c("dplyr", "vegan", "BiocManager", "mlr3") new.packages <- list.of.packages[!(list.of.packages %in% installed.packages()[,"Package"])] if(length(new.packages)) install.packages(new.packages, lib = .libPaths()[2], ...
fa0a822a70ebc15287f33716d9cd4e5462d52ae9811770994598bab9e47cebf4
R
6,459
135
## ----setup list.of.packages <- c("dplyr", "vegan", "BiocManager", "mlr3") new.packages <- list.of.packages[!(list.of.packages %in% installed.packages()[,"Package"])] if(length(new.packages)) install.packages(new.packages, lib = .libPaths()[2], ...
297925c718ecd1f399f50cfbc85b2c474b6a1fdc0f2e7118e75474b7c161420c
R
6,460
207
--- title: "KO Coeff" author: "SRomano" output: html_document editor_options: chunk_output_type: console --- # Load packages. ```{r setup} library(phyloseq) library(dplyr) library(SIAMCAT) library(tidyverse) source("/Scripts/Model_coefficient_extraction.r") set.seed(56987) ``` # KO ## Load metadata ```{r} meta<...
6f3c1c73e18a667211d75763c3c02b17d6fbcc1d7254fee262dfce4f7fb32cee
R
6,463
133
## ----setup list.of.packages <- c("dplyr", "vegan", "BiocManager", "mlr3") new.packages <- list.of.packages[!(list.of.packages %in% installed.packages()[,"Package"])] if(length(new.packages)) install.packages(new.packages, lib = .libPaths()[2], ...
7c299ce4af195abe3661be69650721235fc156b9c680d626a738c3c44d1ea67f
R
6,467
133
## ----setup list.of.packages <- c("dplyr", "vegan", "BiocManager", "mlr3") new.packages <- list.of.packages[!(list.of.packages %in% installed.packages()[,"Package"])] if(length(new.packages)) install.packages(new.packages, lib = .libPaths()[2], ...
f4ceba2265e970117f52d67e47542901e3d3e9f87540931bff4222197601e233
R
6,475
133
## ----setup list.of.packages <- c("dplyr", "vegan", "BiocManager", "mlr3") new.packages <- list.of.packages[!(list.of.packages %in% installed.packages()[,"Package"])] if(length(new.packages)) install.packages(new.packages, lib = .libPaths()[2], ...
713c531766fad003dd9c0c146a24c103a0dffc7b6331721591addd22700ff311
R
6,476
134
## ----setup list.of.packages <- c("dplyr", "vegan", "BiocManager", "mlr3") new.packages <- list.of.packages[!(list.of.packages %in% installed.packages()[,"Package"])] if(length(new.packages)) install.packages(new.packages, lib = .libPaths()[2], ...
7a29b0b033388a50a577a4244de73147429bae88cf7d609e79eb17010d8d2816
R
6,476
133
## ----setup list.of.packages <- c("dplyr", "vegan", "BiocManager", "mlr3") new.packages <- list.of.packages[!(list.of.packages %in% installed.packages()[,"Package"])] if(length(new.packages)) install.packages(new.packages, lib = .libPaths()[2], ...
53cf0d5cefc501b7556d2676e3688b0de233399718658be05c13ead5f745744f
R
6,477
134
## ----setup list.of.packages <- c("dplyr", "vegan", "BiocManager", "mlr3") new.packages <- list.of.packages[!(list.of.packages %in% installed.packages()[,"Package"])] if(length(new.packages)) install.packages(new.packages, lib = .libPaths()[2], ...
dce2f51904580d2d9fbb50aaf3526825f57cdfdec2f82eaa1a8a58be9ef5723b
R
6,477
134
## ----setup list.of.packages <- c("dplyr", "vegan", "BiocManager", "mlr3") new.packages <- list.of.packages[!(list.of.packages %in% installed.packages()[,"Package"])] if(length(new.packages)) install.packages(new.packages, lib = .libPaths()[2], ...
f7872bd870c13260dfbe2fd0033bb6d4a0be1424b6d1d0a82ddefd960ab15490
R
6,477
134
## ----setup list.of.packages <- c("dplyr", "vegan", "BiocManager", "mlr3") new.packages <- list.of.packages[!(list.of.packages %in% installed.packages()[,"Package"])] if(length(new.packages)) install.packages(new.packages, lib = .libPaths()[2], ...
de068dc1b56740c63f429030219f8e5dc4c02ebf59b181d539be347f35f05538
R
6,485
186
# sif=/mnt/data1/public/singularity/dcibioinformaticsR-v2.1.sif # wd=/mnt/data1/workspace/Anders/MelBrM # rtmp=/mnt/data1/workspace/Methods/Containers/MissingPackages/v2.1:/rtmp # singularity exec \ # --containall \ # --no-home \ # --bind ${wd}:${wd}:rw \ # --bind ${rtmp} \ # ${sif} \ # R library(tidyverse) library(op...
a4870b96ac4caea0614f13e8a987e82f041775a4e69532a6b90f303a48c76195
R
6,511
175
# IT neuron subtypes projecting to medial subnetwork # Figure 2E 3D soma distribution of subtypes in medial pathway ---- Label_Subtype_IT_Medial = c(6,7,8,9,10,11,29,31) Index_IT_medial = Index_IT[Label_Subtype_PFC[Index_IT] %in% Label_Subtype_IT_Medial] # # tmpColor = c("6"="#e41a1c", "7"="#377eb8", "8"="#4daf4a", ...
e63b6eb829df418cb6e3b8b9389fac39b439efc40d26aac98c8bf135f1480511
R
6,531
252
--- title: "Plate reader growth curves of GAT201 mutants in RPMI and CO2-independent media" author: "Liz Hughes & Edward Wallace" date: "23/05/2023" output: html_document: toc: yes toc_depth: 2 --- ```{r call_shared_functions_formatting, child = "shared_functions_formatting.Rmd"} ``` # Summary Plate reader...
810ca8e902b80cc4d915837de3630118c87dbb13aedd49d877c65b4997ac0354
R
6,577
354
args <- commandArgs(T) #1. fraction of basis to use #2. penalty #3 distance threshold #4 input pairwise distance matrix #5 input interaction frequency matrix #6 output file name #7 output file dir library(parallel) library(mgcv) library(Matrix) #given a pairwise distance matrix, calculate gram matrix...
c3aa7352dc8355f3eef58d4f6a42442c5b65331b19fa9e77d055b1cec667a739
R
6,582
128
#Manuscript Figure 4d - phee syllabe RMS amplitude plots and stats phee_amp_1<- phee.analysis%>% dplyr::mutate(subject= factor(subject))%>% dplyr::rename(duration=`Delta Time (s)`, rms_amp =`RMS Amp (U)`)%>% dplyr::filter(!(syllable %in...
6a1c2c333bbdf83d3a570d6165d84fd878196e1088318cceb937633c5ece16cb
R
6,583
89
#' flamingo.main_func #' #' Main function of FLAMINGO, a wraper for all steps #' @param hic_data_low Input Hi-C data in .hic format, .mcool format or sparse matrix format. #' @param file_format foramt of the input hic data. Could be .hic, .mcool or sparse matrix format. #' @param domain_res Size of the domains in bps,...
4dc9fd73ffbe817571f8362a31d9026437e1122b7c40a64cf7fc2c6e1cb9ab43
R
6,627
177
--- title: "Batch Importing ASC Files" author: "Austin Hurst" date: "`r Sys.Date()`" output: rmarkdown::html_vignette vignette: > %\VignetteIndexEntry{Batch Importing ASC Files} %\VignetteEngine{knitr::rmarkdown} %\VignetteEncoding{UTF-8} --- ```{r results="hide", message=FALSE} # Import libraries required for t...
073735d3ab48309a6edb13f1614e2250e91e648decf1fef05aac844ab8299146
R
6,654
206
## Testing ___________________ import_segmentation_ij __________________ ## Testing slice objects test_that("reading segmentation info from a slice object works", { skip_on_cran() skip_on_ci() s <- slice(slice_ID = "1_4", slice_directory = test_object_path("slice")) expect_message( s <- impor...
a922255cb6eedf490d95ab28301b67fbe1ee783557d7694073efc66011f584ad
R
6,719
140
## ----setup list.of.packages <- c("dplyr", "vegan", "BiocManager", "mlr3") new.packages <- list.of.packages[!(list.of.packages %in% installed.packages()[,"Package"])] if(length(new.packages)) install.packages(new.packages, lib = .libPaths()[2], ...
559b33b8837bb86ce39df534cf6537ed7a4dbf90c60ded3cea290771675679c1
R
6,720
140
## ----setup list.of.packages <- c("dplyr", "vegan", "BiocManager", "mlr3") new.packages <- list.of.packages[!(list.of.packages %in% installed.packages()[,"Package"])] if(length(new.packages)) install.packages(new.packages, lib = .libPaths()[2], ...
449bf23a312a62c66167f0273265495568d0524384ce65918f4e1a664d67c56b
R
6,735
263
--- title: "Making a grid of kmers" output: html_notebook --- To make an image that summarize the distribution of k-mers for a sample, we will need to assign each kmer to a pixel. We used tSNE to place kmers in a 2D plane based on their sequence similarity. Here we will move kmers around as needed to assign each one u...
e81e553944c9edc3653fa0230afbf084b0dfb328784c0c22efb3e77d1645031f
R
6,746
139
#This code document includes the code for a function that is designed to run a basic meta-analysis of Log2FC and sampling variance values using our previously generated objects MetaAnalysis_FoldChanges & MetaAnalysis_SV #Megan Hagenauer #July 25 2024 ###################### #Installing and loading relevant code packag...
587b308764938bcd5eb39b5f38dde371c337a527809fc46320cc2295d9f9b58b
R
6,781
117
library(tidyverse) library(Seurat) library(patchwork) set.seed(1234) options(scipen = 999) stepped <- DiscretePalette_scCustomize(num_colors = 24, palette = "stepped") stepped <- stepped[c(7,6,5, 16,15,14, 12,11,10,9, 24, 24)] source("../../../../../multiome2/atac_integration/epi_loose/meta_highlight_manual.R") sourc...
efac92829a54b2c77ad16b350b8823c8171bda262f98a2571846fca48d6e9c4b
R
6,810
222
test_that("add_noise returns an n x p array", { g <- add_noise(p = 10, 1000) expect_equal(dim(g), c(1000, 10)) }) test_that("add_noise returns a matrix", { g <- add_noise() expect_true(is.matrix(g)) }) test_that("add_noise returns genotypes with MAF in maf_range", { tol = 0.02 maf_min = 0.05 maf_max =...
322360d00985d690aaa1991e0f7cd806b79e86bb87dd7f51464e6db0cef6e833
R
6,832
135
#' Fit the null logistic mixed model and estimate the variance ratio by a set of randomly selected variants #' #' @param plinkFile character. Path to plink file to be used for calculating elements of the genetic relationship matrix (GRM) #' @param phenoFile character. Path to the phenotype file #' @param phenoCol char...