sha256 stringlengths 64 64 | language stringclasses 28
values | size int32 1 491k | lines int32 1 23.2k | content stringlengths 1 200k |
|---|---|---|---|---|
c58cfeee1335246dd81b6023681866a7a4d29b25b8c9209911db6f2d93179a01 | R | 7,198 | 215 | # logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(Seurat)
library(scDist)
data_obj_sub <- readRDS("../seurat_objects/snRNA_cellBneder_corrected_postQC_scTransformed_clustered_2ndRoundAnnotated_SeuratV4_object.... |
ddae13630f1fd188b77162aa69bd2c644adfe7a8ebe7602df62d417c884dbcc1 | R | 7,232 | 214 | # run this dobro w/o activated conda env, with `MAST` v1.18.0 installed
# logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(data.table)
library(NMF)
library(rsvd)
library(lme4)
library(Seurat)
library(sctransform... |
0aab3346ebdc247e2756e107358854831414f8feb86982074b417d26fb554cc5 | R | 7,245 | 206 | # logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(ArchR)
library(Seurat)
set.seed(666)
addArchRThreads(threads = 8)
addArchRGenome("hg38")
# full dataset, snRNA label transferred with level 2
proj <- loadArc... |
ac241eb41a48bc4932e840000f8eec2123a9ca2944aed72aad3af2456180cc8a | R | 7,321 | 174 | library(testthat)
library(gUtils)
setDTthreads(1)
test_that(desc = "test read.juncs for svaba vcf",
code = {
fn = system.file("extdata", "svaba.subset.vcf", package = "gGnome")
svaba.all = gGnome:::read.juncs(fn)
svaba.std = gGnome:::read.juncs(fn, standard.only = T... |
5c28a88c9f390eb8c9a5761d51cd995eddef347deb9127e90ced774d4694c011 | R | 7,418 | 190 | library(Matrix)
library(RcppCNPy)
library(reticulate)
library(readxl)
##########################################################
# depth and width
##########################################################
# user-specified data folder and name
folder.data <- 'masked dataset median/'
dataset <- 'mbrain'
file... |
7ad0ff51955354af7ccdbbf6935b662b6a1b73124be62c51f645324f1dd126e3 | R | 7,419 | 261 | library(tidyverse)
library(ggrepel)
library(ggrastr)
# df_obs <- read_tsv("./MAST_res_level2_summary.txt")
df_obs <- read_tsv("./MAST_res_level2_rmChrXY_summary.txt")
selected_cond_1 <- "ALS"
selected_cond_2 <- "Control"
selected_cell_type <- "Astro"
# selected_cell_type <- "Micro"
selected_region <- "MCX"
# selected... |
718594b461f702f5844ebdfb0413c1f8f46387b10c2f0598ef6084098cc94571 | R | 7,469 | 195 | # run this dobro w/o activated conda env, with `MAST` v1.18.0 installed
# logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(data.table)
library(NMF)
library(rsvd)
library(lme4)
library(Seurat)
library(sctransform... |
06e5c1fcdbb2ff526164cd3b784a520bf0f7451fcfd07ef63e733b196dc326fc | R | 7,528 | 189 | # logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(DiffBind)
bam_path <- "/cndd3/Public_Datasets/Dracheva_ALS_ChIPseq/bam/"
peak_path <- "/cndd2/junhao/ALS_FTD_singleCell/ChIPseq/peaks_bed/"
subject_id <- c("1... |
039f89056bbaf09620039d691ef9dea8acff99f5cb68c33b75f5883575ac9f65 | R | 7,533 | 269 | library(tidyverse)
library(ComplexHeatmap)
library(circlize)
library(viridis)
library(scico)
DE_level_2 <- read_tsv("MAST_res_level2_summary.txt")
FDR_threshold <- 0.05
FC_threshold <- 1.2
selected_cell_types <- c(
"Exc_superficial", "Exc_intermediate", "Exc_deep",
"Inh_PVALB", "Inh_SST", "Inh_VIP", "Inh_LAMP5",... |
4ff63dcaff61f250ed8cebca325b79f1ef8f6b821a81cfd56a5575e64e63b23a | R | 7,540 | 358 | scatterPlot_general <- function(
df,
xVar,
xLab,
yVar,
yLab,
fillVar = NULL,
fillLimits = NULL,
fillValues = NULL,
lineColorVar = NULL,
lineColorLimits = NULL,
lineColorValues = NULL,
textSize = 12,
zoom_x = FALSE, # Zoom to part of x axis
xmin = NULL,
xmax = NULL,
zoom_y = FALSE, # Zoom... |
924134ed62e07f1bbc30b417e4a173f5651c3e5fbc804a1d47422d0180d43731 | R | 7,573 | 201 | #### Thank you for using our code, wish you all the best! ####
# Note: In this script, our code comments are not very detailed,
# please see the simulation code of Homo-Area for detailed comments.
# The main difference between Compo-Area code and Homo-Area code is to assign-
# different properties to each sub-regi... |
993d437c2becbf61556c47155f72bc8eb7f1a1771356a54b1a9c5e0023dab958 | R | 7,587 | 195 | # run this dobro w/o activated conda env, with `MAST` v1.18.0 installed
# logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(data.table)
library(NMF)
library(rsvd)
library(lme4)
library(Seurat)
library(sctransform... |
040b420145d034e097a2ce89680a3439a38b4f82aaf3d1c2edba15ab48ecba33 | R | 7,591 | 205 |
# SONAR
## Configure
```{r,setup,warning = FALSE, message = FALSE}
library(SONAR)
library(here)
library(Matrix)
library(data.table)
library(Seurat)
library(matlabr)
library(R.matlab)
```
## Set paths / Prepare the Input
```{r}
#Set paths.In this example, we set the path as this files' dir.
knitr::opts_knit$set(roo... |
756b36ab5079b199484d7bf78e5a067be76bf122c85ecb2892b6a2ce06666d9c | R | 7,628 | 275 | library(tidyverse)
library(ComplexHeatmap)
library(circlize)
library(viridis)
library(scico)
DE_level_2 <- read_tsv("MAST_res_level2_summary.txt")
FDR_threshold <- 0.05
# FDR_threshold <- 0.2
# FC_threshold <- 1
# FC_threshold <- 1.2
FC_threshold <- 2
selected_cell_types <- c(
"Exc_superficial", "Exc_intermediate"... |
dab638c309f026190fe4ed7e7b7646051357b67a0fe17886f48f5eadd9d0007f | R | 7,661 | 216 | build_slice_color_table <- function(csv_paths, output_path) {
# ---- Step A: Read, normalize treatment, filter ----------------------------
normalize_tx <- function(x) {
dplyr::case_when(
grepl("^ba", x, ignore.case = TRUE) ~ "baseline",
grepl("^se", x, ignore.case = TRUE) ~ "senktide",
grep... |
5ced6243baf77f1214e036b6b7310a2c912919e170aa72ef160aca8a63d4ee31 | R | 7,709 | 153 | #!/nfs/sw/R/R-3.6.1/bin/Rscript
## Common functions
extractGenes = function( X , geneNames) {
## this function is a private function of mergeCodesets.
if( !is.data.frame(X)) stop("No data frame provided")
if( !is.character(geneNames) | !is.null(ncol(geneNames)) ) stop("geneNames must be a vector of character")
... |
cac3cdbb2cbc2bf366d8272d451d2b2a14c25af0f6f4c1c85b1ef7f3074668bd | R | 7,712 | 205 |
# SONAR
## Configure
```{r,setup,warning = FALSE, message = FALSE}
library(SONAR)
library(here)
library(Matrix)
library(data.table)
library(Seurat)
library(matlabr)
library(R.matlab)
```
## Set paths / Prepare the Input
```{r}
#Set paths.In this example, we set the path as this files' dir.
knitr:... |
1d57df944a509d71bb9b634fb78e9ef63da00f61855863ed0da7222b8b765341 | R | 7,853 | 408 | # all ph_label can be read here
# layout_properties(doc, layout = "Title and Content")
addSlide_sectionHead <- function(
ppt,
title
){
ppt <- add_slide(ppt, "Section Header")
ppt <- ph_with(
ppt,
value = title,
location = ph_location_label("Title 1")
)
}
addSlide_oneGraph <- function(
ppt... |
403df03b3bf791be77f2468b8dbd879ebb9b51a99cc574c5ce7c9d27d1b4b419 | R | 7,878 | 207 | library(MixfMRI, quietly = TRUE)
prefix <- "simu"
load("new/summary/summary.rda")
if(!file.exists("new/summary_plotpv")){
dir.create("new/summary_plotpv")
}
### Plot
i.counter <- 0
for(i.case in 1:nrow(ret.summary.org)){
i.counter <- i.counter + 1
tmp.phantom <- eval(parse(text = ret.summary.org[i.case, 1]))
... |
a800fa0bceed827e638a5dd242222b794139000af0722a718fe29fd5f0219468 | R | 7,956 | 223 | phantom <- c("shepp0fMRI", "shepp1fMRI", "shepp2fMRI")
overlap <- c("0.01", "0.1", "0.25", "0.50", "0.75", "0.95")
library(MixfMRI, quietly = TRUE)
prefix <- "simu"
col.1 <- rgb(1, 0, 0)
col.2 <- rgb(0, 1, 0)
col.3 <- rgb(0, 0, 1)
x <- exp(seq(log(1e-8), log(0.999), length = 50))
pv.xlim = c(50, 206)
pv.ylim = c(50, ... |
b6af2a55097fa244ec4801678e71119c946ddd4045d8c9fde94b899a9d67cde4 | R | 8,002 | 221 | ##Using StringTie with DESeq2 to analysis Nasonia RNAseq data
rm(list=ls()) #clear all objects
gc()
#dataset:
#Nasonia RNAseq data
#experimental light treatment and dark control
#4 different time point: 0.5h 1h 2h 4h
#8 sample groups
#3 replicates per experimental sample group, 2 replicates per control sampl... |
e68ea1ac0a5fee9ecff1e6f71cac0fa2684d3bf25ac97391b969585f9316d82d | R | 8,038 | 300 | library(tidyverse)
library(ggrastr)
DE_level_2 <- read_tsv("MAST_res_level2_splitControls_summary.txt")
FDR_threshold <- 0.05
FC_threshold <- 1.2
cell_types <- c(
"Astro", "Endo", "Micro", "Oligo", "OPC", "VLMC"
)
res <- DE_level_2 %>%
mutate(
sig_DE = if_else(
(fdr < FDR_threshold &
abs(model... |
1a1ce4bd7afdaba18d1df29c056572c2bab3024167e285032b045d2797de4b2e | R | 8,078 | 227 | # logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(Seurat)
library(scales)
library(scico)
library(tictoc)
library(shades)
# read in annotated data
# data_obj_sub <- readRDS("./seurat_objects/snRNA_cellBneder_co... |
453418235a824b9964923e7fd6ef986648434ae99fdcc9a3bbdc736b7de788e8 | R | 8,129 | 200 | #' @title Dotplot of the Effects of Perturbations on Factors
#' @details The size of a dot represents the PIP of association;
#' the color represents the effect size.
#'
#' @param fit An object of class \code{"gsfa_fit"}
#' @param target_names Names of the perturbations, the default uses the
#' row names in \code{fit$p... |
e4884ae17ece40f1e2c3c9c2e047321f9f9fc1b1b34538b95e43e1fd34885b9b | R | 8,156 | 225 |
check.Rcplex.control <- function(control, isQP)
{
## default control parameters
con <- list(
## CPLEX parameters
trace = 1L, ## Messages to screen switch
method = 0L, ## Algorithm for optimization
preind = 1L, ## Presolve switc... |
02260f7001387c5ca7a7158319b634a5ecb3bab6acb312776bab07fa262c809b | R | 8,177 | 341 | textTheme <- function(size = 11, boldXText = FALSE, forManuscript = isManuscript){
theme = theme(
text = element_text(
size = size
# , family = "Arial" # Downloading the fonts is always a thing that trips me up on a new device, but I have some troubleshooting code that we could try and then uncomment ... |
115c5006ea4dd0cba85291fc0cf99ca5eae96bcaed9efed50df3b1494e18649e | R | 8,178 | 215 | ###Using StringTie with DESeq2 to analyze Nasonia RNAseq data
rm(list=ls()) #clear all objects
gc()
#dataset:
#Nasonia RNAseq data
#experimental light treatment and dark control
#4 different time point: 0.5h 1h 2h 4h
#8 sample groups
#3 replicates per experimental sample group, 2 replicates per control sampl... |
dd7f8378154699fd20b097e03f1b7483aa40ef4a2e3a257f3525f22b6609c7cc | R | 8,183 | 182 | library(ArchR)
library(ggplot2)
library(gridExtra)
library(Rtsne)
library(clusterProfiler)
setwd('output path')
###Figure2g####
proj = readRDS('Save-ArchR-Project.rds')
cellColData=as.data.frame(proj@cellColData)
cellColData[,1][cellColData[,1] == 'adult_hindbrain_PL2011260025'] = 'Rho-1'
cellColData[,1][ce... |
78c1897a6a83b2b21edd99a96c4dbe7b9b9bc30ed0af49a1c4a7624b8068af23 | R | 8,283 | 196 | ---
title: "UPDRSIII.sobgroups_progression"
author: "AMCalejandro"
date: "23/7/2021"
output: html_document
---
```{r setup, include=FALSE}
library(tidyverse) # For tidy manipulation of data
library(here) # For file path construction
library(DT) # To display data tables
library(readxl) ... |
5ed2e9412fd0015700f6464fd5ca924ca008f6fc909459600c8c80a58b22f046 | R | 8,384 | 213 | plot_selected_runs_treatments <- function(df_in_0, run_type, run_ids, select_treatments,
groups = c("DI", "OVX", "MALE", "ORX"),
slice_colors,
freq_overall_min = 0, freq_overall_max = 0.7,
amp_overall_min = 0.003, amp_ove... |
5d0194bd772ac8c82b02524c90499bb3476a80737ab33fad39525576b2a99bce | R | 8,398 | 226 | ### SHELL> Rscript create_simu.r
phantom <- c("shepp0fMRI", "shepp1fMRI", "shepp2fMRI")
overlap <- c("0.01", "0.1", "0.25", "0.50", "0.75", "0.95")
min.1st.prop <- c("0.975")
max.PV <- c("0.05")
model <- c("I")
seed <- 1234
# system <- function(x) cat(x, "\n", sep = "")
mkdir.prefix <- TRUE
cp.prefix <- TRUE
mkdir.ou... |
a23e15c1ae97d6c0d556af4afe43f67b5437410e3cee5da947ae9416b9c38cfb | R | 8,401 | 170 | ---
title: "Analysis of vGlut stainings for Marc"
author: "Dr. Jana Dahlmanns"
date: "`r Sys.Date()`"
output:
word_document:
reference_docx: reference_doc.docx
header-includes:
- \usepackage{helvet} # this is used to set the font to helvetica instead of the horrible default
- \renewcommand{\familyde... |
602a82e346fe0e5bb5ce42812108d8d0503d1f11074087505947eb7508fe5aba | R | 8,409 | 218 | # run this dobro w/o activated conda env, with `MAST` v1.18.0 installed
# logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(data.table)
library(NMF)
library(rsvd)
library(lme4)
library(Seurat)
library(sctransform... |
dd8d7a5cb890454f8e120ad78efc188599e295111e1bf5c50ba21500abfaf461 | R | 8,425 | 218 | # run this dobro w/o activated conda env, with `MAST` v1.18.0 installed
# logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(data.table)
library(NMF)
library(rsvd)
library(lme4)
library(Seurat)
library(sctransform... |
addff1ba199597ee394e2c0c6dceb92cefbe719a2d6f8db839a97eb6d1490c76 | R | 8,427 | 218 | # run this dobro w/o activated conda env, with `MAST` v1.18.0 installed
# logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(data.table)
library(NMF)
library(rsvd)
library(lme4)
library(Seurat)
library(sctransform... |
4e53579771dcbd4bfb86eb38829bd6ac6cc3db224756da36994ef69fe3bd77bd | R | 8,477 | 266 | library(WGCNA);library(hdWGCNA);library(tidyverse);library(cowplot);library(patchwork)
library(Seurat);library(dplyr);library(ggrepel);library(ggplot2);library(RColorBrewer)
defcol1<- c("#F3C300", "#875692", "#F38400", "#A1CAF1", "#BE0032", "#C2B280",
"#008856", "#E68FAC", "#0067A5", "#F99379", "#604E97",... |
4324070d4dd89f63415ee7bea6e90e325e1935cbd71cfdd3428be488f9d809e1 | R | 8,721 | 243 | library(tidyverse)
library(ggplot2)
library(ggdendro)
library(reshape2)
library(viridis)
library(scico)
library(scales)
# Exc up ------------------------------------------------------------------
df<-read_csv("/cndd2/jchien/project/ALS/GO/GO_postCellBender/GO_summary_full_AP_ALS.csv")%>%
filter(reg =='up') %>%
... |
b5ddf55975a0da0b521e451f31766d2ffa3dba1949be06285370ba645f9ada00 | R | 8,745 | 222 | #!/nfs/sw/R/R-3.6.1/bin/Rscript
################################################################################
### COPYRIGHT ##################################################################
# New York Genome Center
# SOFTWARE COPYRIGHT NOTICE AGREEMENT
# This software and its documentation are copyright (2023) by... |
e307a10ee82fb0be76a8297138dd5d7687cc2c765ce54a56594a63876c55e6f4 | R | 8,786 | 219 | ---
title: "Getting started with Pando"
author: "Jonas Simon Fleck"
date: "17/05/2022"
output: html_document
---
```{r, echo = FALSE, message=FALSE}
knitr::opts_chunk$set(message = FALSE, warning = FALSE)
```
This vignette gives you an introduction to the Pando workflow and gives a broad overview of the functionality... |
09191ec7f26612a33cec61f910d39cd9efc310454eb39f205a7cf1cef6469518 | R | 8,942 | 242 | ### SHELL> Rscript create_simu.r
phantom <- c("shepp1fMRI")
overlap <- c("0.1", "0.25", "0.50", "0.75", "0.95")
min.1st.prop <- c("0.95", "0.975", "0.99")
max.PV <- c("0.05")
model <- c("I")
seed <- 1234
smooth <- TRUE
# system <- function(x) cat(x, "\n", sep = "")
mkdir.prefix <- TRUE
cp.prefix <- TRUE
mkdir.output ... |
099cad575243569f42d008f02dc06c83096885d70bb5107a473f0eb93f9f1d0f | R | 8,950 | 274 | "%&%" <- function(a,b) paste(a,b, sep = "")
library(tidyverse)
library(data.table)
#Use Phyloseq for diversity analysis
library(phyloseq)
#library(DECIPHER)
#library(phangorn)
library("microbiome")
library(ggplot2)
library(cowplot)
library(vegan)
"%ni%" <- Negate("%in%")
library(MMUPHin)
library(vegan)
library(magrit... |
e994b13d298b6f7dce9811f68a26ff4ebfbecb52648f4515580ecf1c304fe86a | R | 8,955 | 120 | #!/usr/bin/env Rscript
library(optparse)
option_list = list(
make_option(c("-i", "--input"), type = "character", default = "qcreport.txt", help = "Input txt file from a snowman preprocess qcreport.txt"),
make_option(c("-o", "--output"), type = "character", default = "qcreport.pdf", help = "Output pdf to ge... |
f51111a5b32fd9adbcd3a0b2edf1b314f1771d051b6d53b839a388f6c734e172 | R | 8,994 | 207 | library(shiny)
library(shinythemes)
library(shinyjs)
# Define UI for application that draws a histogram
ui <- fluidPage(theme = shinytheme("cosmo"),
tags$style(HTML('#fluidrow1 {
display: flex;
align-items: center;
}
#fluidrow2 {
di... |
cba903ed7998980ae361675f0ed0e20464b5143d1d00c4e50bf2d91b2cb1c009 | R | 9,011 | 170 | # logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
snRNA <- read_tsv("MAST_res_level2_summary.txt")
FDR_threshold <- 0.05
# FC_threshold <- 1.2
FC_threshold <- 2
snRNA_cell_types <- c(
"Exc_superficial", "Exc_int... |
7b571d6953a358e349226bbe6efab0efa414ffbc60eecd5f74b691fa43942d99 | R | 9,026 | 228 | # logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(DiffBind)
bam_path <- "/cndd3/Public_Datasets/Dracheva_ALS_ChIPseq/bam/"
peak_path <- "/cndd2/junhao/ALS_FTD_singleCell/ChIPseq/peaks_bed/"
subject_id <- c("1... |
cb97bfffbf4f32e5dfebe4323a757913880ad033664f4e295be9bb7fa8d24d7e | R | 9,041 | 229 | # logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(DiffBind)
bam_path <- "/cndd3/Public_Datasets/Dracheva_ALS_ChIPseq/bam/"
peak_path <- "/cndd2/junhao/ALS_FTD_singleCell/ChIPseq/peaks_bed/"
subject_id <- c("1... |
ee573bdf6c0a9593076ae2f7890edd8a74083d85dee8e6ae6968212f4b5dc495 | R | 9,054 | 230 | # logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(DiffBind)
bam_path <- "/cndd3/Public_Datasets/Dracheva_ALS_ChIPseq/bam/"
peak_path <- "/cndd2/junhao/ALS_FTD_singleCell/ChIPseq/peaks_bed/"
subject_id <- c("1... |
410f2d5f3d72884311e7cfa80eb7a4129e6017bf4afc5dd6b5a1b0aba608a3e1 | R | 9,066 | 229 | # logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(DiffBind)
bam_path <- "/cndd3/Public_Datasets/Dracheva_ALS_ChIPseq/bam/"
peak_path <- "/cndd2/junhao/ALS_FTD_singleCell/ChIPseq/peaks_bed/"
subject_id <- c("1... |
d78141cb4a8a36e87c2ab1cc5712e6b6002b623b674a445da8b43bbeb669305d | R | 9,090 | 226 | #!/usr/bin/env Rscript
suppressMessages(library(optparse))
suppressMessages(library(DirichletMultinomial))
suppressMessages(library(TailRank))
suppressMessages(library(doMC))
#
# Load command line arguments and read in data
#
arguments <- parse_args(OptionParser(usage = "%prog [options] counts_file", description="Le... |
b620f123733824ab8fa29122ec6ef86ecf09734730de89380b08b5985bbc6b9c | R | 9,146 | 218 | #============================================================================
#==============SUPER-ENHANCER CALLING AND PLOTTING FUNCTIONS=================
#============================================================================
#This function calculates the cutoff by sliding a diagonal line and finding where it... |
773f509c67ff8bffafb7ab19cb2962ff2e4eec67dd043dfaa3ec8d209941d9c6 | R | 9,149 | 198 | # Function to get plots for the power calculation
powerPlot = function(df, mafs) {
a = ggplot(finaldf, aes(fill = beta, x = maf, y = power)) +
geom_bar(position = "dodge", stat = "identity") +
facet_wrap(~SS, scales = "free") +
theme_bw(base_size = 13) +
geom_hline(yintercept=0.8, linetype='dashed... |
84f83a1aad5d303c2fe9b79cbe428e933fe00c285f7943f80e19881506f8f7ad | R | 9,154 | 253 | ---
title: 'Code Notebook for : </br> </br> Developmental Emergence of Neurogliaform Cell Diversity'
author: "Lucia Gomez Teijeiro"
date: "2023-07-19"
output:
html_document:
df_print: paged
subtitle: </br> </br> Postnatal Molecular Architecture - NGC Type </br> </br>
---
</br>
**Information for replication:... |
4596e8e6abf714787e6ffa9e73ee1a956336c75d651f1e9eefe90a3d52a3d1aa | R | 9,194 | 229 | # logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(DiffBind)
bam_path <- "/cndd3/Public_Datasets/Dracheva_ALS_ChIPseq/bam/"
peak_path <- "/cndd2/junhao/ALS_FTD_singleCell/ChIPseq/peaks_bed/"
subject_id <- c("1... |
d97bdbcb82fe57bb9f5f715745f19255bd8ea409a06a450db955ecbd2e620912 | R | 9,208 | 228 | # logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(DiffBind)
bam_path <- "/cndd3/Public_Datasets/Dracheva_ALS_ChIPseq/bam/"
peak_path <- "/cndd2/junhao/ALS_FTD_singleCell/ChIPseq/peaks_bed/"
subject_id <- c("1... |
960de905b4b85fccf2dad954905dad3012fba1215031557adb690d46210cd20c | R | 9,209 | 277 | suppressPackageStartupMessages({
library(compositions)
library(Seurat)
library(tidyverse)
library(clustree)
library(uwot)
library(scran)
library(cluster)
library(patchwork)
library(ISCHIA)
library(robustbase)
library(data.table)
})
colours <- c("#00CC99", "#F0E685", "#99CC00", "#C75127", "#5050FF", "#CDDEB7","#EE82EE"... |
a57baf1f7794e9d19df6e8d60707f2073ffe41bd290f9fa703cb7bd31e845055 | R | 9,223 | 229 | # logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(DiffBind)
bam_path <- "/cndd3/Public_Datasets/Dracheva_ALS_ChIPseq/bam/"
peak_path <- "/cndd2/junhao/ALS_FTD_singleCell/ChIPseq/peaks_bed/"
subject_id <- c("1... |
78504b5fede7790d00a5f44c845c754f6e625412d17610ec915b45b2cc073115 | R | 9,243 | 264 | #!/nfs/sw/R/R-3.6.1/bin/Rscript
################################################################################
### COPYRIGHT ##################################################################
# New York Genome Center
# SOFTWARE COPYRIGHT NOTICE AGREEMENT
# This software and its documentation are copyright (2023) by... |
1d4a3ad9a72b20dc0a9a5381920502c37dffe61906ac7ee69ec7de6be04dee8d | R | 9,248 | 229 | # logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(DiffBind)
bam_path <- "/cndd3/Public_Datasets/Dracheva_ALS_ChIPseq/bam/"
peak_path <- "/cndd2/junhao/ALS_FTD_singleCell/ChIPseq/peaks_bed/"
subject_id <- c("1... |
5694890bcd6cecc8673b7d740fe2eca3ec1a259fde37adb669c01dd1e5bb5180 | R | 9,256 | 232 | ###0-1. rotation
coord_rotate <- function(seurat.object,theta,clockwise=TRUE) {
seurat.object$xcoord <- seurat.object@reductions$spatial@cell.embeddings[,1]
seurat.object$ycoord <- seurat.object@reductions$spatial@cell.embeddings[,2]
coordinates <- seurat.object@meta.data[c("xcoord","ycoord")]
the... |
06998f65f73a2c39cb578329f066f3a4cb68796fc996e12573bd6cfc575034d0 | R | 9,271 | 305 | library(dplyr)
library(stringr)
DATA_DIR <- "/data2/MRI_PET_DATA/predicts/" # nolint
################################################################
####### Start MLP
################################################################
mlp_dat <- read.csv(paste0(DATA_DIR, "mlp_predictions.csv"))
mlp_dat$Dataset <- as.f... |
3001ca0d770db5cfad89a9bd875d39d31b54a60ebb6904de32ea2c3e1306a220 | R | 9,298 | 245 | #### Thank you for using our code, wish you all the best! ####
# Note: In this script, our code comments are not very detailed,
# please see the simulation code of Homo-Area for detailed comments.
# The main difference between Compo-Area code and Homo-Area code is to assign-
# different properties to each sub-regi... |
d16403facf8d941cab5585da3f0eaebf927c49d8ef67e5dd955b71b2d08e1b9a | R | 9,338 | 244 | # run this in the `r_env_v4`conda env, with `MAST` v1.17.3 installed
library(tidyverse)
library(data.table)
library(NMF)
library(rsvd)
library(lme4)
library(MAST)
library(Seurat)
library(sctransform)
library(future)
library(scales)
library(magrittr)
library(pheatmap)
library(scico)
library(viridis)
library(tictoc)
libr... |
167877029f0cb1549a05ef7700beeba2bb94bd354faefebc6a9f020ad8bc3b30 | R | 9,343 | 211 | library(tidyverse)
library(lme4)
library(lmerTest)
library(DHARMa)
library(emmeans)
library(robustlmm)
library(ggdist)
library(ggplot2)
library(sjPlot)
library(devtools)
install_github("jfrancoiscollin/ClinReport")
library('ClinReport')
#Read data, convert and recode factor variables
dat <-read.delim("Data_TempResolu... |
ea72e7ae83866222560cb2c3e6429f671572d15693cddae6751cf7deca8cdb34 | R | 9,370 | 445 | myDisplay <- function(df, docType = doc.type){
rownames(df) <- gsub("trt","treatment", rownames(df)) # replace 'trt' with 'treatment' in the row names of dataframe
if(!is.null(docType) && docType == "docx"){
return(flextable(df))
} else {
return(df)
}
}
subTrtInRowNames <- function(tbl, sub = "early-li... |
f353b41415aa2185c4dc0f4c96035e050105fff0a4f8c8b3884997c9903b58a6 | R | 9,372 | 322 | ---
title: "Examples plus noise"
output: html_document
---
```{r setup, include=FALSE}
knitr::opts_chunk$set(echo = TRUE)
```
```{r IMPORTANT - RT decrease from different distributions}
# SAME THING WITH GAUSSIAN - still slope of -1
library(stats4)
require(tidyverse)
# https://stats.stackexchange.com/questio... |
e5d98ff38978c8ac7e5f8e8de7e9a131fe1a3cd052c77ae7267bb8d21eb88d22 | R | 9,419 | 267 | # run this dobro w/o activated conda env, with `MAST` v1.18.0 installed
# logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(data.table)
library(NMF)
library(rsvd)
library(lme4)
library(Seurat)
library(sctransform... |
d831384af70dbea5197f533e4fc7b9a7927d01a1d45a3dcef06a781aba0c5336 | R | 9,427 | 254 | # logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(Seurat)
library(sctransform)
library(scales)
library(harmony)
library(ggrastr)
library(scCustomize)
library(shades)
library(ggbeeswarm)
library(ggpubr)
## read... |
c0953147533fcab3076990734b328080a6a7af2e7d254e018ed9645b877015c3 | R | 9,436 | 267 | # run this dobro w/o activated conda env, with `MAST` v1.18.0 installed
# logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(data.table)
library(NMF)
library(rsvd)
library(lme4)
library(Seurat)
library(sctransform... |
f394b5e6eda90f3d0c91b5c0b0c500906e2e0606aad4a735c6e66e927af32e72 | R | 9,537 | 245 | # run this dobro w/o activated conda env, with `MAST` v1.18.0 installed
# logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(data.table)
library(NMF)
library(rsvd)
library(lme4)
library(Seurat)
library(sctransform... |
f0f27b41e0969803a4b994af632d580ca552a7a0923c13152b477f40d1bd2e9c | R | 9,612 | 337 | # logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(scales)
library(ggrastr)
library(scattermore)
library(clustree)
library(ggpubr)
# read metadata
meta_data <- read_tsv("./metadata_all_cells_2nd_round_annotatio... |
448e3350df951a8b25bbf3254bed9b91571213520563070834f6632284f0d8d2 | R | 9,651 | 264 | #' Motif scanning with a corrected background conversion
#'
#' This file vendors the parts of motifmatchr (1.32.0, GPL-3, Alicia Schep)
#' and Signac (1.17.1, MIT, Tim Stuart) that Pando uses to scan candidate
#' regions for motifs (`Signac::AddMotifs()` -> `Signac::CreateMotifMatrix()`
#' -> `motifmatchr::matchMotifs(... |
60bdba8ceb4382712e9d4eac03d2d7c5322f50927ec1192fec210b51915e9bc5 | R | 9,696 | 300 | # logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(viridis)
library(scico)
library(shades)
library(ggbeeswarm)
library(ggpubr)
# read metadata
meta_data <- read_tsv(
"metadata_all_cells_2nd_round_annotation... |
ba7c43ac499e4d8c748c1ee023a66de086d7183cca4899aec928f4623cef0817 | R | 9,779 | 219 | # plot-slices-core.R
#
# Shared helpers for slice-level scatter plots. Used by both
# plot_baseline_v2() and before_after_v7(). Lower-level than the wrappers —
# defines style constants, scale builders, geom builders, theme block, and
# the slice-id -> color/shape mapping used for stable visual identity.
#
# This file ... |
60cc2100acf055c4869ce8f5bf8df082e390ce518590abbdea83b7c9f18f513f | R | 9,842 | 263 | require(tidyverse)
setwd('~/Dropbox/Apps/ShareLaTeX/CogSci 2019/code/')
source(file='transmit/R/transmit.R')
prior_experiment_entropy <- function(
codebook,
actual_proportion,
prior_proportion,
expected_entropy_threshold,
signal_power,
noise_power,
timesteps,
time_interval,
repeats
){
# Go throu... |
34485776f861ccdfbdd3af0bb7c578b50e77267b8695db7dc0018e861ad09815 | R | 10,834 | 264 | library(testthat)
library(gUtils)
setDTthreads(1)
###########################
## test binstats and unphased balance
##
###########################
message("Reading test subgraph")
sg = readRDS(system.file("extdata", "hcc1954.rigma.sg.rds", package = "gGnome"))
message("Reading test coverage")
sg.cov = readRDS(syste... |
0736cd7c0fa2eb6e377c5bff73e4bbcbf3e6815fec8f631dfdd9a86bbf6754ba | R | 11,325 | 300 | ##########LICENCE##########
# Copyright (c) 2014-2020 Genome Research Ltd.
#
# Author: Peter Van Loo <cgphelp@sanger.ac.uk>
#
# This file is part of AscatNGS.
#
# AscatNGS is free software: you can redistribute it and/or modify it under
# the terms of the GNU Affero General Public License as published by the Free
# Sof... |
e243165eeac8bf61f39c302fd940196a10c81e24a4ba20a44817a510680730c1 | R | 11,330 | 309 | ---
title: "Untitled"
author: "AMCalejandro"
date: "28/3/2022"
output: html_document
---
```{r}
.libPaths("/data/kronos/kronos/acarrasco/R_libs/")
library(colochelpR)
library(data.table)
library(tidyverse)
library(coloc)
library(biomaRt)
library(DT)
library(ggpubr)
library(SNPlocs.Hsapiens.dbSNP144.GRCh37)
```
```{... |
4eba51934ccb369f4d82dc2c2deca1e73572b00ccee0f06a84b5fe65602f6357 | R | 11,378 | 282 | ---
title: 'Imputation of splitted UPDRS measures'
author:
- name: "Alejandro M.Carrasco"
affiliation: UCL
output:
html_document:
css: ./font/missingexploration_fontsize.css
code_folding: hide
theme: paper
highlight: kate
df_print: paged
fontsize: 20pt
toc: true
toc_float: true
... |
89780a64b72a6024d2b4dac3acf6332450261b8ca99d8d0f2b7e03c096199fcc | R | 11,423 | 377 | # logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(scico)
library(ggrepel)
library(plotly)
library(htmlwidgets)
# read DE list
DE_level2 <- read_tsv("/cndd2/junhao/ALS_FTD_singleCell/snRNA_postCellBender/DE_MAS... |
947ad1b4b302b4f5a4f29f2c54ea29be8adf9c6ee2048f299a94a944b0637a33 | R | 11,436 | 200 | # Tidy up blasting and GO annotation files for RNAseq
rm(list=ls()) #clear all objects
# load packages
library(tidyverse)
library(dplyr)
library(data.table)
library(stringr)
### Step 1 We combined blast results and pulled additional annotation for DEGs only ###
# read sprot and trembl and nr blast file
s... |
993668fbbc5a64e13207333bd0b3a45799a679f38b62a7312bf9de708982f4de | R | 11,508 | 279 | source('~/git/dissertation/thesis/Chapter 04 - A variable-length code/src/transmit/R/transmit.R')
require(entropy)
require(cowplot)
require(tidyverse)
entropy_threshold_experiment <- function(
codebook,
actual_proportion,
prior_proportion,
entropy_threshold,
signal_power,
noise_power,
timesteps,
time_i... |
a571607184527f9bf970002a72552344dd2c5d27eda0f7acfa3e791b998556fd | R | 11,623 | 377 | # logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(Seurat)
library(scales)
library(future)
library(ggbeeswarm)
library(ggpubr)
library(shades)
library(ggrastr)
# enable parallelization
plan("multisession", work... |
b1a4f7cdb56d642a224d101e17dbefb5c2fd7e420eb9135d6e088665184dd427 | R | 11,811 | 166 | ---
title: "Differential Splicing"
output: rmarkdown::html_vignette
vignette: >
%\VignetteIndexEntry{Vignette Title}
%\VignetteEngine{knitr::rmarkdown}
%\VignetteEncoding{UTF-8}
---
For a (hopefully) complete example of the complete pipeline, take a look at
```
example_data/worked_example.sh
```
:warning: The te... |
9bf815e1bb26c9bd0dc4d209ec736c88ea46be4485476b38aae963d2124678fc | R | 12,011 | 250 | # logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(Seurat)
library(sctransform)
library(scales)
library(harmony)
## read the sctransform-normalized seurat object
selected_celltype <- "NonNeu"
data_obj_sub <- r... |
4f4615ec20c7d4ab19a57d4efd1a0800ce03bb9fa8c717fb95ad508b3194b43a | R | 12,012 | 357 | library(shiny)
library(DT)
library(shinycssloaders)
library(shinyjs)
if (!exists("introns")){
defaultValue <- 12 #RBFOX1
showCode <- "GTEx Brain vs Heart"
}else{
defaultValue <- NULL
showCode <- code
}
ui <- tagList(
useShinyjs(),
navbarPage(
title = actionLink("aboutLink", "LeafViz"),
#title = ... |
f243566620c6800494bd82cb0dcc3c2e1a1944843903974ea9c3f3628af10f75 | R | 12,035 | 312 | ---
title: 'Code Notebook for : </br> </br> Developmental Emergence of Neurogliaform Cell Diversity'
author: "Lucia Gomez Teijeiro"
date: "2023-07-19"
output:
html_document:
df_print: paged
subtitle: </br> </br> Dataset Integration and Identity Prediction - Postnatal Day 15 </br> </br>
---
</br>
**Informati... |
bbc403bd1a921269905b3b13cbb30559d120d24054f1a68408e5b03ffa994732 | R | 12,036 | 313 | ---
title: 'Code Notebook for : </br> </br> Developmental Emergence of Neurogliaform Cell Diversity'
author: "Lucia Gomez Teijeiro"
date: "2023-07-19"
output:
html_document:
df_print: paged
subtitle: </br> </br> Dataset Integration and Identity Prediction - Postnatal Day 30 </br> </br>
---
</br>
**Informati... |
62326638081e3cd96f3f2cf435a33d42339288a72e06d5a7cb673ba5429dce11 | R | 12,279 | 254 | # logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load librar
library(tidyverse)
library(Seurat)
library(sctransform)
library(scales)
library(harmony)
## read the sctransform-normalized seurat object
selected_celltype <- "Inh"
data_obj_sub <- readR... |
eb38a98abca3896361e92692567f6c50b3ed116ab78d2d7da3fe607ebcdbd30b | R | 12,318 | 390 | # logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(ArchR)
library(viridis)
library(scico)
library(ggrepel)
library(shades)
library(ggrastr)
library(ggbeeswarm)
library(circlize)
library(cowplot)
set.seed(666)
a... |
5f38218eb5dc48d5d00af6b783cda3923f2cc98e7877c19af84a9e022962937d | R | 12,822 | 284 | # logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(scico)
library(ggrepel)
# read DE list
DE_level2 <- read_tsv("MAST_DE_res_level2_summary.txt")
DE_level2_Astro <- DE_level2 %>%
filter(cond_1 == "ALS",
... |
9a3697537d3feee580ce35b5f6e5576c9c7b1e34d65116e2bc7a8384d8f87322 | R | 12,924 | 297 | #!/usr/bin/env Rscript
library(optparse)
require(VariantAnnotation)
option_list = list(
make_option(c("-i", "--input"), type = "character", default = "qcreport.txt", help = "Input txt file from a snowman preprocess qcreport.txt"),
make_option(c("-o", "--output"), type = "character", default = "q... |
df4ce410091565a342d1ae2e906ad6d568f11f8b33973753025a686e37f44ddd | R | 12,947 | 325 | overall_start_time = Sys.time()
library(AnVIL)
library(tidyverse)
library(gridExtra)
library(ggrepel)
library(Seurat)
library(janitor)
library(hdf5r)
library(magick)
library(MASS); select = dplyr::select; summarize = dplyr::summarize
# statistical parameters
ci_size = .95
alpha = 1 - ci_size # 0.05
qnormval = qnorm(1... |
f1fdf5d64da137e6e4c5daf576643e86dc783e3dd37d6f98f634a3d3021f903b | R | 13,172 | 319 | library(tidyverse)
library(viridis)
library(scico)
bulk_DE <- read_tsv("edgeR_res_glmTest_allExpressedGenes_rmOutlierSamples_simplified.txt")
# MA plot
p <- bulk_DE %>% ggplot(aes(logCPM, logFC))
p +
geom_hex(bins = 100) +
theme_bw(base_size = 10, base_family = "Helvetica") +
facet_wrap(~comparison + region ... |
20d5571ea14c9cc757fd082ecf19639c5033aecfda3fe49360b20a32ec14a124 | R | 13,221 | 307 | library(JaBbA)
library(gUtils)
library(gTrack)
library(testthat)
context('JaBbA')
print(sessionInfo())
## load testing data
juncs.fn = system.file("extdata", "junctions.vcf", package = 'JaBbA')
bedpe = system.file("extdata", "junctions.bedpe", package = 'JaBbA')
cov.fn = system.file("extdata", "coverage.txt", packag... |
af27a67cfd65e2aa587acde1ac788ae2a7bee8e4464d2ce4760a137f83e0c33e | R | 13,263 | 285 | # logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(Seurat)
library(scales)
library(scico)
library(tictoc)
library(shades)
# read in annotated data
# data_obj_sub <- readRDS("./seurat_objects/snRNA_cellBneder_co... |
a40d16936ac95762f6bb9e2d1e1b527bd08c600c8b6fcc87aa165a94f8779904 | R | 13,330 | 312 | require(tidyverse)
source(file='/Volumes/Data/git/dissertation/thesis/Chapter 04 - A variable-length code/src/transmit/R/transmit.R')
# Want to vary the entropy (i.e. the distribution or proportion of what you're transmitting) and see how response time changes
alphabet_length = 128
codebook <- construct_codebook(past... |
dc0872fe2be5d16923ff7897eec23cb7f2ed0c6e2a3fafd69cc7bd8222c2f236 | R | 13,370 | 531 | #' @importFrom methods setClass
#' @importClassesFrom Signac Motif
#' @importClassesFrom GenomicRanges GRanges
#' @importClassesFrom SeuratObject Seurat
NULL
#' The Modules class
#'
#' The Modules object stores the TF modules extracted from the inferred network..
#'
#' @slot meta A dataframe with meta data about the ... |
828c99716cabc478768cdac3a8f6332fe4546bdd1a9da76f26c698688ceb68a1 | R | 13,479 | 324 | # logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(scales)
library(ggrastr)
library(scattermore)
library(cowplot)
# read meta data
meta_data <- read_tsv("./metadata_merged_addAnno.txt")
# shuffle the order of ... |
eb5163f97e904724c3c1115e75b3a85e5cc916c9901e63506de5b54c8b75d89f | R | 13,486 | 416 | # logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(Seurat)
library(scales)
library(future)
library(ggbeeswarm)
library(ggpubr)
library(shades)
library(ggrastr)
# enable parallelization
plan("multiprocess", work... |
39ea5ac3db7bfb1a82e0ecdda01b7ad1064d9fa9cdc4870384ed02f97ea86e92 | R | 13,674 | 411 | # logging which server was used to run this script
system("echo \"Running this on ### $(hostname) ### \\(* w *)/\"")
# load library
library(tidyverse)
library(ggrepel)
library(directlabels)
sem <- function(x) {
sd(x, na.rm = T) / sqrt(length(na.omit(x)))
}
ci <- function(x, conf.interval = 0.95) {
N <- sum(!is.na... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.