sha256 stringlengths 64 64 | language stringclasses 27
values | size int32 1 491k | lines int32 1 21.8k | content stringlengths 1 200k |
|---|---|---|---|---|
9d02c88e5fb25e711620fe6de7b1e5f7dbae3a8d678fff86c6b4963011c6393d | R | 48,399 | 1,126 | ---
title: "Experimental Supplemental Procedures OPP"
subtitle: "scRNAseq analysis of Caudet Segarra et al. 2025"
output:
pdf_document: default
fontsize: 10pt
date: "2025-01-10"
engine: knitr
knitr:
opts_chunk:
R.options:
width: 80
---
```{r wrap-hook, include = FALSE}
library(knitr)
hook_output <- kn... |
c0a53fc4f906339bb2587f0754c17b82a10d549b28b40674bdc4709739d18ddb | R | 49,164 | 1,575 | #' @importFrom R6 R6Class
#' @importFrom utils modifyList
Booster <- R6::R6Class(
classname = "lgb.Booster",
cloneable = FALSE,
public = list(
best_iter = -1L,
best_score = NA_real_,
params = list(),
record_evals = list(),
data_processor = NULL,
# Initialize will create a starter booster... |
3f2b1f058595df34d64ae8bacbe125720fe176496eb633378690bf8e0f78c502 | R | 49,352 | 1,159 | # This script is to load, format, fill-in, and save separate datasets for analysis
rm(list = ls())
library(data.table)
library(dplyr)
library(readxl)
source("./code/fun_summaries.R")
# Oyster data ----
## Brood summary ----
if (TRUE) {
# Load hatchery data as in @Gray:etal:2022:hatchery,
# from ... |
7853747bd54ed3eb440b44e34fd516d6e9a800af4a79645d25cc18342f19a256 | R | 49,601 | 1,621 | # Test read_npx_zip ----
# Test that if the input file has been misidentified as zip compressed but it is
# not (e.g. .txt), then a relevant error is thrown
test_that(
"Non-zip input is handled - random file",
{
skip_if_not_installed("zip")
withr::with_tempfile(
new = "txtfile_z",
pattern = "t... |
b4fc3efe83fcad13b8dd556e568b623a3ce97227bf3a280de8fce7c4dfb587e7 | R | 49,759 | 1,216 | # Set Dynamic Working Directory and load R source code of dependent libraries
# install.packages("rstudioapi")
library(rstudioapi)
setwd(dirname(rstudioapi::getSourceEditorContext()$path))
getwd()
source("required_packages.R")
#===============================================================================
#... |
f8aa84e3676434792fb1390b78e8db848cebc6cd392aa47edbe7a7e205171ba0 | R | 49,783 | 1,779 | #' Convert Olink data in wide format with
#' `r ansi_collapse_quot(get_olink_data_types(broad_platform = "qPCR"))` data to
#' long format.
#'
#' @author
#' Klev Diamanti
#'
#' @inherit .read_npx_args params return
#' @param df A tibble containing the full Olink dataset in wide format.
#' @param file Path to Olink sof... |
794d23395880f0bb23ccee96e299725f08931ee809dfb2a8f4349f0a78a1c378 | R | 50,133 | 1,126 | ##########################################################################
## Functions to use continuous covariates, as part of the MEFISTO framework ##
##########################################################################
#' @title Add covariates to a MOFA model
#' @name set_covariates
#' @description Function ... |
c868c01e6182a492c77ebf84548947c01c7491c2a63ef5f9dea8f1a7ea4647e5 | R | 51,458 | 1,744 | require(ggplot2)
require(dplyr)
require(tidyr)
library(digest)
library(cmdstanr)
library(posterior)
require(rethinking)
# Change these paths to your Rtools gcc and g++ executables:
Sys.setenv(
CC = "C:/rtools45/x86_64-w64-mingw32.static.posix/bin/gcc.exe",
CXX = "C:/rtools45/x86_64-w64-mingw32.static.posix/bin/g++... |
40a1e8f7ed68085b5a6e68704f36f6a7bb2e3336101fb222740d95fe48ef882b | R | 51,678 | 976 | ---
title: "Plotting #1: Analysis Plots"
date: 'Compiled: `r format(Sys.Date(), "%B %d, %Y")`'
output: rmarkdown::html_vignette
theme: united
df_print: kable
vignette: >
%\VignetteIndexEntry{Plotting #1: Analysis Plots}
%\VignetteEngine{knitr::rmarkdown}
%\VignetteEncoding{UTF-8}
---
***
<style>
p.caption {
fo... |
e820589356c1cddb91cb1ab6680df368adb4d30bc9429d73984443096ba1e2c1 | R | 51,708 | 1,563 | ---
title: "(FIGURE 3) LR Analysis with MSigDB: median of medians threshold of significance for landscapes"
author: "Ludovic Telley & Draia-Nicolau Tangra Ondina"
date: "2024-03-10"
output:
html_document:
toc: yes
toc_float: yes
theme: united
highlight: tango
code_folding: hide
fig_width: 20
... |
43a04eaa4982b443b37705bc2d520e8d5d1a4b210046ff8d32598ca8a5d86239 | R | 51,817 | 1,266 | # ==============================================================================
# S2_upload.R
# Server logic for Data Upload, Preprocessing, and Spatial Registration.
#
# Purpose:
# Handles the ingestion of user data, performing validity checks,
# preprocessing (creation of Seurat objects), and optional spa... |
307f2bdd9f526d2ce5d768f51e1336a6d7b5a057da136b9583b1c013c943ecd6 | R | 51,839 | 1,011 | ---
title: "rsfMRI Data Analyses"
author: "Claire Campbell"
date knitted: "Version `r format(Sys.time(), '%B %d, %Y')`"
output:
html_document:
df_print: paged
toc: true
toc_float: true
---
```{r setup, echo=F}
knitr::opts_chunk$set(echo = TRUE)
#Clear existing data and graphics
rm(list = ls(all.names = T... |
62f8cfc3152764013430ad35d0a62e2178e46d3840078e0d9bc3091068cdc4c2 | R | 52,779 | 1,359 |
#Load necessary packages.
library(shiny)
library(shinyjs)
library(EBImage)
library(jpeg)
library(ggplot2)
library(shinydashboard)
library(dplyr)
library(tibble)
library(ComplexHeatmap)
library(grid)
library(gridExtra)
library(cowplot)
library(DT)
library(waiter)
library(viridis)
library(shinycssloaders)
library(plotly... |
f219bef4ceeed88c68fe9176695f9464b5eaacd08c169ac59987ff3b3f7dba3d | R | 53,862 | 1,055 | ---
title: "RNA_TCGA_BEX"
author: "Mathis Nozais"
output:
html_document:
code_folding: hide
code_download: true
date: "2024-01-23"
editor_options:
chunk_output_type: console
---
#################
Script for TCGA bulkRNAseq analysis for "BEX" paper.
Made for Docker RNA 431
#################
```{r setup... |
4b4d393c7c7335d7b33156d820cfa65bc26ab6582c3b1ee34567e927fd25ed27 | R | 53,883 | 1,363 | ##########################################################################
# Function: compute.fdr
# Purpose: Apply the requested fdr method to the set(s) of p-values provided
# Arguments: p - a vector or matrix of p-values
# opts - a list with the following components
# LC = loess.control ... |
1082107fd0ab69bd9e1002320bc8567a0ba0405a52c78daa6411d446a83c6e73 | R | 54,767 | 1,437 | ##############################
# Cross-Species Fig 6 and Ext Data Fig 10 and 11
##############################
# --- Libraries ---
library(Seurat)
library(dplyr)
library(pheatmap)
library(RColorBrewer)
library(viridis)
library(orthogene)
library(ggsankey)
library(tidyr)
library(ggplot2)
setwd("~/Downloads/Chhatbar_et... |
943a52b98965c2b9d8f6da8eaf8d4adc89673af9b2a9fc1ac0f4c5a7ea5f4873 | R | 55,070 | 1,800 | test_that("Booster's finalizer should not fail", {
X <- as.matrix(as.integer(iris[, "Species"]), ncol = 1L)
y <- iris[["Sepal.Length"]]
dtrain <- lgb.Dataset(X, label = y)
bst <- lgb.train(
data = dtrain
, params = list(
objective = "regression"
, num_threads = .L... |
c1787ae9d54e3d77c5e3641aa0cb1a46d59ea79cbcfdd607b171ae5d0b5b9789 | R | 57,195 | 1,584 | #%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
#################### CONVERT TO LIGER ####################
#%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
#' Create liger object from one Seurat Object
#'
#' @param group.by Variable in meta data which c... |
d4002356ed0646749bae6280b683ef32ad4736a5674dda2ba5743f276204fef1 | R | 57,204 | 1,186 | #' @export plot_model_performance
plot_model_performance <- function(data, group_var = stop("Grouping variable not provided."),
class = stop("Classes not provided."),
legend_title = NULL,
accuracy_ref = NULL, loss_r... |
9b9f34c7b4d88aefa7f3f030cb1291869e13497a17657a9bda90b4a894df05d4 | R | 57,959 | 2,113 | # Test check_npx ----
test_that(
"check_npx - error - df is not tibble or arrow data frame",
{
df <- data.frame(
SampleID = c("A", "B", "C", "D"),
OlinkID = rep("OID12345", 4L),
SampleType = rep("SAMPLE", 4L),
NPX = rnorm(4L),
PlateID = rep("plate1", 4L),
QC_Warning = rep("P... |
c73ef0621aeb74f1e81e1cfc7bb2778d3997016d5dcf33378ac7aa251586f861 | R | 58,544 | 980 | setwd("D:/valentin/main/")
# load("RNAseq/current.Rdata")
sources = dir("./scripts/",full.names=TRUE)
for(s in sources){
source(s)
}
source("./RNASeq/limma_SE.R")
########### Methylation ############
load("eQTLDB/BDR_final_set_26-9-23.Rdata")
load("eQTLDB/UKBBN_final_set_27-9-2023.Rdata")
pheno_UKBB... |
97e5e7dbf09bdffc76fb347d6ae661fdb084adc318c34599e70f94ebb5cb586e | R | 58,977 | 1,619 | # Set your Working Directory and load R source code of dependent libraries
# install.packages("rstudioapi")
library(rstudioapi)
setwd(dirname(rstudioapi::getSourceEditorContext()$path))
getwd()
source("pcm_libraries.R")
source("rsf_libraries.R")
source("deepsurv_libraries.R")
source("deepsurv.R")
#--------... |
4f9ded4c43870b19580bfe81a63f8c6a5dbae58e2df17dd50693df4f0f37d54a | R | 59,538 | 1,813 | library(scSeqComm)
library(scrattch.hicat)
library(scrattch.vis)
library(scrattch.io)
library(Matrix)
library(Seurat)
library(dplyr)
library(rhdf5)
library(pbmcapply)
library(OmnipathR)
library(graphite)
library(data.table)
library(corrplot)
library(ComplexHeatmap)
library(stringr)
library(ggplot2)
setwd("/mnt/DD/Sc... |
9a9613fc4ae03a2ab5ffe61f63013899115122d009798c63572bfce550589e47 | R | 60,145 | 1,479 | ########################################################################################################
# Code for performing Differential Gene Expression Analysis on Exp. 13-1 (HEK SR64 vs SR71 mRNA-seq)
# row means >=10 filter before dds and splicing
# Christina Ramelow, PhD
# Date: 08/27/2025
######################... |
5595eb518dce3cd0e3434e76e3818e89baa466d3393e65dd3c3e1e59e9f6c059 | R | 60,591 | 1,908 | ---
title: "Helper_Functions_Pipeline"
author: "Thomas Goralski"
date: '2022-07-26'
output: html_document
---
```{r setup, include=FALSE}
knitr::opts_chunk$set(echo = TRUE)
```
The below are helper functions for the GeoMX data analysis pipline. The get_qc function is highly verbose. I suggest running Qc man... |
b89b91cbb5cf10f9ad46a20d9bba60028204f1ba100f71783ebf10876611c601 | R | 60,735 | 1,725 | # Test olink_normalization_n ----
test_that(
"olink_normalization_n - works - bridge",
{
ref_norm_res <- get_example_data("ref_results_norm.rds")
### bridge normalization - no norm column ----
norm_schema_bridge_nonorm <- dplyr::tibble(
order = c(1L, 2L),
name = c("df1_no_norm", "df2_no_n... |
32e21147397f50a4feda288ad58aa1d3e2d4b42e3487c2c93ed2556d6949e290 | R | 61,435 | 1,441 | #%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
#################### OBJECT QC VLN ####################
#%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
#' QC Plots Genes
#'
#' Custom VlnPlot for initial QC checks including lines for thresholding
#'
#' @... |
8dc5d29b8abb9da104a6c4d9e55c6a46901c3016e450fc636ae21335fd3a30a3 | R | 61,664 | 1,432 | # Meta-analysis of scRNA-seq data of E14 Neocortex - Part 4 : Functional analysis ---------------------
# Rahul Jose
# SCB, RGCB
# October 2024
# Primary Aim :
# For the identification of NIHes1 and NDHes1 cells from Neocortex single cell data,
# Identifying PCA based clusters in scRNA-seq data from Loo, L., S... |
47a335a2c06244544abf8c7c65a0426e3fc57c9c72e996d1db907f586f4e1770 | R | 63,372 | 1,121 | # Main script for analysing single cell Ca2+ data ++++++++++++++
# Authors: Kai Budde-Sagert, Meike Bielfeldt
# Created: 2025/04/17
# Last changed: 2025/12/08
# Delete everything in the environment
rm(list = ls())
# Close all open plots in RStudio
graphics.off()
# Show warnings as they appear
opt... |
81ba8c07a224769ef6321edfe9e1d38c719a0bb436de3e8f923b8d57b898122f | R | 64,035 | 984 | ---
title: "Supplementary Figures"
author: "Audrey Luo"
output:
html_document:
highlight: haddock
code_folding: hide
number_sections: no
theme: lumen
toc: yes
toc_depth: 4
toc_float: yes
pdf_document:
number_sections: no
toc: yes
toc_depth: '4'
word_document:
toc: yes
... |
11d485fe1155f6c870f98d869b7c53786bd923b1bf138cebaf0dfa8811c3c3bc | R | 64,142 | 1,237 | # the purpose of this script is to annotate cell clusters
# load required libraries
libs <- c( 'gplots','stringi','reshape2','cowplot','RColorBrewer',
'sctransform','stringr','org.Mm.eg.db','AnnotationDbi',
'IRanges','S4Vectors','Biobase','BiocGenerics','clusterProfiler',
'biomaRt','Ma... |
22ff3d3ae5711eb2bf52909f0e0678f861de7fd94b4ac669524c59bb49748dd8 | R | 64,220 | 1,149 | expected.roc <-
list(ndka = list(forward = list(`<` = list(sensitivities = c(
1,
1, 0.97560975609756095, 0.97560975609756095, 0.97560975609756095,
0.95121951219512191, 0.92682926829268297, 0.90243902439024393,
0.90243902439024393, 0.90243902439024393, 0.90243902439024393,
0.90243902439024393, 0.90... |
22dfa7adff829209ed2fc4371548202723f77afb2a91c939d722316fc6c1a5e8 | R | 65,285 | 1,340 | ---
title: "Emotional Data Analyses"
author: "Claire Campbell"
date knitted: "Version `r format(Sys.time(), '%B %d, %Y')`"
output:
html_document:
df_print: paged
toc: true
toc_float: true
---
```{r setup, echo=F}
knitr::opts_chunk$set(echo = TRUE)
#Clear existing data and graphics
rm(list = ls(all.names... |
64813015001ad4eb0b6bdc56f85b07bd880c84ba93ee8b56562ad8523c14b9c9 | R | 65,688 | 1,319 | ## Creating Fibroblast origin subset object with only the Fibroblast clusters from the Fibroblast origin complete object
## Follow-up script to process and explore the Fibroblast origin subset object in Figure 1 manuscript
## Rebuttal: Performed CCA instead of harmony and now includes the new Betsholtz lab data
librar... |
a762724d59ea498584ee1831e76d097957d2d2bc1e713027079e998688fa34b5 | R | 66,016 | 1,772 | ############################
## iTReX server script ##
## Author: Dina ElHarouni ##
############################
error_notification <- function(cond) {
debug_dir <- Sys.getenv("ITREX_DEBUG_DIR")
if (nchar(debug_dir)) {
cat(paste(cond), file = file.path(debug_dir, "last.err"))
}
showNotification(paste0(c... |
9cb0e8012f8dfc5d13b058daf89f1ceba5ecfb1de14e4e662876af80b14ab0d1 | R | 67,618 | 1,532 | #%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
#################### QC UTILITIES ####################
#%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
#' @param species Species of origin for given Seurat Object. If mouse, human, marmoset, zebrafish, r... |
26df170e27031832d025cbf8fef7e1a43d2baf014d28da54c4893ac8004f1452 | R | 68,125 | 1,487 | ## Script for processing 7wo ChP 4V and LV aggregate object
library('Seurat')
library('dplyr')
library('gridExtra')
library('scater')
library('DisneyTools')
################################################################################
########## GENERAL
#############################################################... |
11e8ab6b140e419b122f9c599310a89b0ddef24f6c68182ef5a13244f57a9c48 | R | 68,631 | 1,917 | #%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
#################### EXTENDED SEURAT GENERICS ####################
#%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
#' Extract Features from LIGER Object
#'
#' Extract all unique features from LIGER object... |
73266ad1d2243605edecdaab822a8df4487a5821ce96a7578ff11dbe817c8b9d | R | 68,824 | 1,614 | library(Seurat)
library(torch)
library(SummarizedExperiment)
library(ggplot2)
library(future)
library(scrattch.hicat)
library(data.table)
library(dplyr)
library(tibble)
library(pbmcapply)
library(SCISSORS)
library(MetaMarkers)
library(gplots)
plan("multicore", workers=10)
plan()
options(future.globals.maxSize= 38... |
6c94f529eaaceed05adda8e497233255acf50cc318fca3b7fc08e4f908cbf7db | R | 68,975 | 1,719 | ##该代码对两个及两个以上单细胞样本通过merge函数进行合并,并提供了定义分组找差异基因方法
##载入Seurat包
library(dplyr)
library(Seurat)
library(ggplot2)
################################################################################################
con1.data <- Read10X(data.dir = "C:/Users/28527/Desktop/MCAO/data/Control/01")
con1 <- CreateSeuratObject(co... |
24332a09bf62038986a16c7b4df36946e42aaf01957327a3e5460b88cc14d4be | R | 69,791 | 1,411 | ## Creating Fibroblast age object (Fig3) with our Fibroblast scRNA-Seq data (7/22/82 wo ChP 4V&LV) and embryonal scRNA-seq data Lehtinen lab (Dani et al.)
## Removed 3rd ventricle data from Lehtinen lab object first before starting merge and CCA workflow to integrate data
## Script continues with processing and explora... |
6b697f528e57fd8b949cebef643ff7bdd1300c3182b475efcd9726e0ea94d44a | R | 70,835 | 2,188 | #' Check inputs of \code{\link{olink_normalization}} function.
#'
#' @description
#' This function is a wrapper of multiple help functions which check the inputs
#' of the \code{\link{olink_normalization}} function.
#'
#' @details
#' The following checks are performed:
#' - \code{\link{olink_norm_input_validate}}:
#' ... |
98386e3d7f1fe80bc178b4065775c06afc14bf9192ba1f9a8c7004f7e3821c76 | R | 71,535 | 1,408 | # Load all the necessary packages
packages <- c("Seurat", "ggplot2", "tidyr", "readr"
, "plyr", "stringr", "harmony"
, "cowplot", "reshape2","ggpubr"
, "gsubfn", "tibble", "gplots"
, "Matrix", "dplyr", "pbapply", "schex"
, "UpSetR", "extraDistr", "ap... |
beb7b895caa12dbfcf487433ae5a073000e15fa0a4ec6cdcc859c93148ce9edf | R | 72,023 | 1,176 | ---
title: "Data Cleaning"
author: "Claire Campbell"
date created: "2/8/2022"
date knitted: "Version `r format(Sys.time(), '%B %d, %Y')`"
output:
html_document:
df_print: paged
toc: true
toc_float: true
---
```{r setup, echo=F}
knitr::opts_chunk$set(echo = TRUE)
#Clear existing data and graphics
rm(list ... |
e276c3f7bb2132faacfa2e1e7a2bf3d28ef75afb299681a84fdb7e0a57a1e57e | R | 72,154 | 1,792 | #' mfishtools: Building Gene Sets and Mapping mFISH Data.
#'
#' This repository includes code for gene selection for spatial transcriptomics methods and for
#' mapping of spatial transcriptomics (or RNA-Seq data) onto a RNA-Seq reference. Specific topics include:
#' 1) Correlation-based mapping of cells to reference ce... |
23045bd0de24149d4bcb8c48b19227c29a71b8c898040fb70d34ede550822dda | R | 73,506 | 992 | ######################################################################################################################
## ANOVA / DiffEx Functions
##
## parANOVA.dex() - output ANOVAout dataframe for all pairwise comparisons of each cleanDat gene product (row)
## among specified sample groups i... |
063c0ba45c57b40ef40bbfe6c846beff9891b3a19c35edc2a8bb49bbcbe6869b | R | 73,791 | 1,602 | #####################
# Exp. 13-1 HEK393 SR64 vs SR71 LV infection (3 uL) DIS LFQ-MS
# Spectronaut DIA search with human UP000005640_9606 Uniprot ID & TurboID-V5
# Christina Ramelow, PhD, MS
# Wrapper script from Sarah Shapley, PhD
# August 30th, 2025
#####################
### STEP 1 SCRIPT ###
#######################... |
2e00e4689ab7f0c7b1cbfa581ba47f6e3043567babaeae985c4071480bc46c93 | R | 74,453 | 1,805 | ---
title: "Olink® Analyze Vignette"
author: "Olink DS team"
date: "`r Sys.Date()`"
output:
html_vignette:
toc: true
toc_depth: 2
includes:
in_header: ../man/figures/logo.html
vignette: >
%\VignetteIndexEntry{Olink® Analyze Vignette}
%\VignetteEngine{knitr::rmarkdown}
%\VignetteEncoding{UTF-8... |
78c84adaea4d5b5944103c6dc2e342257480eeda294cc930dcd310f79c2332c8 | R | 75,482 | 1,832 | library(scrattch.hicat)
library(paletteer)
library(Seurat)
library(reticulate)
use_condaenv(condaenv = "r-reticulate", required=T)
setwd("/mnt/DD/Sc RNA-Seq/QC")
library(scales)
library(ggplot2)
source("/mnt/DD/Sc RNA-Seq/Cortex/Cortex/Function created or adapted/function utils.R")
#### DoubleMAD function
DoubleMA... |
5ff7ee0f1c19a486739d56ff99005eb4c720f997cb4994bbb9d590a4a32677d9 | R | 75,617 | 2,412 | # Test olink_normalization_format ----
# Verification of correctness of results from olink_normalization_format
# are done in combination with olink_normalization. Here we test only that the
# relevant messages are shown.
test_that(
"olink_normalization_format - works - within-product bridge norm",
{
ref_norm... |
680109008283033eb9e2b1c776abdf7c79a4c014ad3b636d450818d4f7bce8b4 | R | 76,423 | 1,643 | ---
output:
md_document:
variant: gfm
editor_options:
markdown:
wrap: sentence
---
If you use this software, please cite our work.
```{r citation}
citation("Tjazi")
```
The following document is adapted from the supplementary materials for this manuscript.
# 0. Introduction
Here, we will demonstrate ... |
2b968ddf9c393c3cadbd24d245c8091c192dfd5f7e2d60b09176da4a5059890c | R | 76,740 | 1,902 | #### LOAD PACKAGES ####
# Load necessary libraries
library(lme4)
library(ggplot2)
library(e1071)
# for bootstrapping:
library(foreach)
library(doParallel)
library(dplyr)
library(effectsize)
library(MuMIn)
library(viridis)
library(Matrix)
library(tidyr)
library(gridExtra) #to arrange plots
#### SET PARAMS ####
#set wor... |
6fcc19f7c9098987e135d7c78e2f4186e9a1dab1c52041b3273614393edaf520 | R | 77,644 | 1,531 | ---
title: "Activated_Regions"
author: "HannahSavage"
date: "2023-04-28"
output: html_document
---
```{r setup, include=FALSE}
knitr::opts_chunk$set(echo = TRUE)
```
#Set env
```{r, include = FALSE}
library(readxl)
library(dplyr)
library(tidyverse)
library(ggplot2)
library(grid)
library(reshape)
library(scales)
libra... |
ab0e03ae8afa2b70ff4dd9df57ffb64c0f6a68c82b3fc8415d968b90e6bebfbd | R | 79,863 | 2,097 | #### LOAD PACKAGES ####
library(lme4)
library(foreach)
library(doParallel)
library(dplyr)
library(effectsize)
library(MuMIn)
library(ggplot2)
library(viridis)
library(arules)
library(data.table)
library(effects)
library(tidyr)
library(lmerTest)
library(scales)
#### SET UP PARAMS AND LOAD DATA ####
#set working direct... |
ab192a17224dc4d00b7c3f23e3228b35eacbb5694472776ebe4c368fff1ed63c | R | 80,510 | 1,592 | ---
title: "Activation_Patients_Controls"
author: "HannahSavage"
date: "2023-05-31"
output: html_document
---
```{r setup, include=FALSE}
knitr::opts_chunk$set(echo = TRUE)
```
#Set env
```{r, include = FALSE}
library(readxl)
library(dplyr)
library(tidyverse)
library(ggplot2)
library(grid)
library(reshape)
library(s... |
0fc4b40345507f56dde738a2904288f3321c7f58d92b8a43b4db43d01751c5ac | R | 80,546 | 2,235 | #%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
#################### OBJECT HELPERS ####################
#%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
#' Check if genes/features are present
#'
#' Check if genes are present in object and return vector... |
49f19e00f7535c64b9b16cf938890963922209620fb68a0ef1ec6eb889ae6e2f | R | 80,633 | 1,486 | library(Seurat)
library(scrattch.vis)
library(scrattch.hicat)
library(scrattch.io)
library(tibble)
library(dplyr)
library(gplots)
library(data.table)
library(SeuratDisk)
setwd("/mnt/DD/Sc RNA-Seq/LR")
source("/mnt/DD/Sc RNA-Seq/Cortex/Cortex/Function created or adapted/function utils.R")
############################... |
0b4c4385fa82b42575e2776cc8945347c6012ae8b4977c6a6bc8cb263cf1df9f | R | 82,469 | 1,804 | ################################################################################
############ Integration of ADULT sc/snRNA-seq datasets via SCT v2 #############
################################################################################
###Load in packages:
library(clusterProfiler)
library(dplyr)
librar... |
09145f933a523696c6b46073a1aa851d26903b627a3c06a51f9eed2a18215d0b | R | 86,302 | 1,732 | ###################################################################################################
# Pipeline-Load+Norm+QC+FIlter+Impute+Volc...R
# Christina Ramelow, MS and Eric Dammer, PhD
# March 4th, 2024
###################################################################################################
# Based of... |
14313e11c73eaf541271faef47b42dc7d81a9f1cf6f75104d798ad77c6edf1a0 | R | 86,480 | 1,902 | #' Iterate PC Loading Plots
#'
#' Plot PC Heatmaps and Dim Loadings for exploratory analysis
#'
#' @param seurat_object Seurat object name.
#' @param dims_plot number of PCs to plot (integer). Default is all dims present in PCA.
#' @param file_path directory file path to save file.
#' @param name_prefix prefix for fil... |
abd8b8ace0c5dd6faecbdc6ff2137d08896b66f9ea73d6d34da6958c58d2897d | R | 87,610 | 1,719 | ###################################################################################################
# Pipeline-Load+Norm+QC+FIlter+Impute+Volc...R
# Christina Ramelow, MS and Eric Dammer, PhD
# February 13th, 2024
###################################################################################################
# Base... |
c5b73f35cd53bbc995529e72dcb5f7306c827ad160e991289440106d89e93287 | R | 88,596 | 1,366 | ---
title: "Main Figures"
author: "Audrey Luo"
output:
html_document:
highlight: haddock
code_folding: hide
number_sections: no
theme: lumen
toc: yes
toc_depth: 4
toc_float: yes
pdf_document:
number_sections: no
toc: yes
toc_depth: '4'
word_document:
toc: yes
toc_d... |
b310973f1cdf599e2f7ecc4e21f709f42b530c31accafe7a097ff3b741b23564 | R | 88,713 | 2,155 | ---
title: "Trajectory inference"
author: 'Jacek'
date: '`r Sys.Date()`'
output:
html_document:
keep_md: yes
code_download: true
code_folding: hide
theme: readable
css: trajectory_inference.css
toc: true
toc_float: true
rmdformats::material:
highlight: kate
params:
inFolder: "~/ap... |
aab2755b8832d6f3039978892471a59b00fb912b03945b50da421eab9d0414a9 | R | 90,336 | 2,245 | #%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
#################### 10X SEQ QC ####################
#%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
#' QC Plots Sequencing metrics
#'
#' Plot the mean number of reads per cell
#'
#' @param metrics_datafr... |
298c4de66dfc0024092b8feb4d911a4df8777a2e4d2b8615a7e9123fcada68c3 | R | 91,819 | 2,051 | # Comments
# This code is intended to be viewed in RStudio and contains appropriate headings
# "=" symbol was used as an assignment operator
# Code for CIBERSORTx runs is presented as character strings within the file
# Real token for CIBERSORTx docker container is replaced with <token_from_cibersortx_website>
# This f... |
2e42d1bc274abccf9a4fde3fb7a1fd5e7a1312599ad322b140c25889c9e174fd | R | 92,253 | 2,335 | #%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
#################### WRITE/CREATE ####################
#%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
#' Create H5 from 10X Outputs
#'
#' Creates HDF5 formatted output analogous to the outputs created by ... |
8cefab96150748d44300a2c4a8af4bbc4e164a40e324a3f628ab5414101920ae | R | 92,444 | 1,789 | setwd("/home/aleksandr/Desktop/WORK/OLINK_suicide_PSY_project/Data_preprocessing_analysis")
# Setting options
getOption("scipen") # Default number notation is 0
options(scipen=999)
options(stringsAsFactors = FALSE)
options(show.error.messages = TRUE)
################### Package import ###################
library(R.ut... |
8fe78c8abc3ce774b7d0e9dcd47fbb4c998397f9c12e050a0c843667dafe3205 | R | 92,793 | 3,219 | # Create Test Data Table --------------------------------------------------
df <- dplyr::tibble(
SampleID = c(
"ValidSample", # valid
"InvalidOID", # invalid OlinkID (too short)
"AllNA", # all NPX values NA for assay
"DuplicateSample", # duplicate SampleID
"ControlType", # ... |
f78669422adcccfabbf51ba4762a843ce19b8449b208613c6730cfd4b6a6abbb | R | 93,387 | 2,589 | ---
title: "Figure 4"
author: "Ludovic update from ondina"
date: "2024-08-14"
output:
html_document:
toc: yes
toc_float: yes
theme: united
highlight: tango
code_folding: hide
fig_width: 20
fig_height: 20
pdf_document:
toc: yes
---
```{css, echo=FALSE}
# Your custom CSS styling
# Ad... |
882bdf8e281231ea3690678c0f1800b73f5e2076d82c4eb5d604855286111b7d | R | 93,759 | 2,209 | ---
title: "Spatial Transcriptomic Analysis of Brain Organoids "
author: "George T. Hall"
date: "Compiled on `r format(Sys.time(), '%d %B %Y')`"
output:
html_document:
toc: true
toc_depth: 1
toc_float:
collapsed: false
number_sections: true
code_folding: none
... |
5f7318646af01cc99cc2e9abf636a539e7ccf751c4014bee38275627c2cab335 | R | 93,911 | 2,173 | #%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
#################### MODDED PLOTS ####################
#%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
#' PC Plots
#'
#' Plot PC Heatmaps and Dim Loadings for exploratory analysis. Plots a single Heatmap... |
d649f0113282e8401a2b865c9610896df59c959c398196980440fcd6fd069d65 | R | 96,139 | 3,551 | # Test read_npx_format ----
test_that(
"read_npx_format - works - long",
{
skip_if_not_installed("writexl")
## current version ----
# get synthetic data, or skip if not available
df_rand <- get_wide_synthetic_data(
olink_platform = "Target 48",
data_type = "NPX",
n_panels = 3L,
... |
6f53616bfc530aefbf65576495cb00ca09093fb0c2ca95998471742b768d4515 | R | 97,724 | 2,360 | library(monocle)
library(scrattch.hicat)
library(scrattch.vis)
library(Seurat)
library(ggplot2)
library(scales)
library(ComplexHeatmap)
library(SeuratObject)
library(paletteer)
library(dplyr)
library(pbmcapply)
library(SummarizedExperiment)
library(future)
library(tibble)
library(gplots)
library(SeuratWrappers)
librar... |
32647362111d481fac0709084cfc178945dda7f5318f84db77a6f17bdad1012c | R | 97,818 | 2,368 | #%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
#################### LIGER INTERNAL UTILS ####################
#%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
#' Extract default dimensionality reduction
#'
#' Extract name of the default dimensionlity r... |
88cbee9120533b820cfb7565ae773c424f6d22ac18a7f5282688dcf486fcf81c | R | 98,512 | 2,134 | ########################################################################################################
# Code for performing Differential Gene Expression Analysis on Exp. 8-1 (Aldh1l1-RiboTag) and Exp. 9-2 (Aldh1l1-TurboID)
# row means >=10 filter before dds and splicing
# Christina Ramelow, MS
# Date: 06/18/2024
###... |
2a5f52e11cca153676a90a661b74f2075be4f4b8671525c34f67f67b7a95814e | R | 99,844 | 2,376 | ########################################################################################################
# Code for performing Differential Gene Expression Analysis on Exp. 1-4 (BV2)
# row means >=10 filter before dds and splicing
# Christina Ramelow, MS
# Date: 02/03/2024
##############################################... |
f29ccb34134a1f0ae09b2213100ebe4862819aa9aac98561046d392eb0f785bf | R | 105,291 | 2,462 | #Functions used in this analysis.
#Rahul Jose
# 1. Folders --------------------------------------------------------------
#creates subdirectories
folders <- function(){
dirs <- list.dirs(full.names = F)
if (! "results" %in% dirs) {
dir.create('results')
}
if (! "data" %in% dirs) {
di... |
1a9ce1749611a66811e50d0184c9c389b1fd5dbe3eb276b642b7fbb1e57cb06c | R | 107,180 | 2,839 | # get cellBender corrected
library(Seurat)
library(hdf5r)
## make a function to load the corrected count data from cellBender
read_count_data_for_multiple_samples <- function(selected_sample){
data_dir <- "I:/Ling Lian/snRNA seq/database/database from Divergent impacts of c9 repeat expansion on neurons and glia i... |
0df5e70a7ac19593223081b8a1663c94f9e587c112b5d7e4ae0152091e4623e0 | R | 110,804 | 3,134 | ---
title: "metabolite_sncRNA"
author: "MM"
date: "2025-11-14"
output: html_document
---
```{r setup, include=FALSE}
knitr::opts_chunk$set(echo = TRUE)
options(future.globals.maxSize = 10000 * 1024^2)
library(Seurat)
library(harmony)
library(dplyr)
library(scCustomize)
library(tidyr)
library(ggplot2)
... |
ac311acbbc444ae40725429bbf0bac841e94fd5aa1f8e692d156a5bc10cae6e5 | R | 111,825 | 4,008 | # Test read_npx_legacy_help ----
test_that(
"read_npx_legacy_help - works",
{
skip_if_not_installed(pkg = "readxl")
skip_if_not_installed(pkg = "writexl")
# Target 48 NPX ----
# get synthetic data, or skip if not available
df_rand <- get_wide_synthetic_data(
olink_platform = "Target 48"... |
25fd442fc664bdd1cf6049ac0b21578f2eeabffe927f758cbdf4205d0f3ba168 | R | 113,117 | 2,788 |
# Comments
# This code is intended to be viewed in RStudio and contains appropriate headings
# "=" symbol was used as an assignment operator
# Code for CIBERSORTx runs is presented as character strings " <command code> " within the file
# Real token for CIBERSORTx docker container is replaced with <token_from_cibersor... |
08e5fd191c5c7351281b79c33a433b826a4c08f97e5c8a6d0c36a6fbacb9e97e | R | 113,409 | 2,867 | #%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
#################### QC HELPERS ####################
#%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
#' Ensembl Mito IDs
#'
#' Retrieves Ensembl IDs for mitochondrial genes
#'
#' @param species species to... |
6384ac44315a9d4ccf8d5113f24339524ac66dd1f4a1b570c02a33a585f40e7d | R | 114,423 | 3,909 | data(agaricus.train, package = "lightgbm")
data(agaricus.test, package = "lightgbm")
train <- agaricus.train
test <- agaricus.test
set.seed(708L)
# [description] Every time this function is called, it adds 0.1
# to an accumulator then returns the current value.
# This is used to mock the s... |
48e302d5d89f2fa627c627837e23bd6d3f1f23d35a203f5e69273b845c8342d4 | R | 115,575 | 2,425 | library(cowplot)
library(data.table)
library(dplyr)
library(ggplot2)
library(ggpubr)
library(grid)
library(gridExtra)
library(gratia)
library(knitr)
library(mgcv)
library(RColorBrewer)
library(scales)
library(stringr)
library(rjson)
library(tidyr)
######################################
# Figures 1, 2 and 3
##########... |
3e132e0cec10e593c36c68a4ad262a853feb02071e52eaf28b2f706d0bef77f8 | R | 116,504 | 2,032 | ---
title: "sMRI Data Analyses for Cortex"
author: "Claire Campbell"
date knitted: "Version `r format(Sys.time(), '%B %d, %Y')`"
output:
html_document:
df_print: paged
toc: true
toc_float: true
---
```{r setup, echo=F}
knitr::opts_chunk$set(echo = TRUE)
#Clear existing data and graphics
rm(list = ls(all.... |
8c693bd4cacdc4aa98be74e1b570c58c3aca3390f168910da8d125f158145bf5 | R | 118,055 | 2,917 | ---
title: "Supplemental Experimental Procedures 2 - Image Analysis"
output:
pdf_document: default
fontsize: 10pt
date: "2025-01-10"
engine: knitr
knitr:
opts_chunk:
R.options:
width: 80
---
```{r wrap-hook, include = FALSE}
library(knitr)
hook_output <- knit_hooks$get("output")
knit_hooks$set(output... |
ded8d96ee7d4e80ed2415512d233edfe29f95b9c336e1510713b05d885e96856 | R | 126,590 | 2,791 | library(Seurat)
library(ggplot2)
library(scales)
library(ComplexHeatmap)
library(SeuratObject)
library(paletteer)
library(dplyr)
library(data.table)
library(circlize)
library(tidyverse)
library(torch)
library(symphony)
# This code is used to create the figures S13, S14, S15 and S16 of the Inferring "Ligand-Receptor In... |
f0e73a3993286b94c7b0dcf4ecd257c6055b0024a2bec51102b47f1e344f8fe0 | R | 127,893 | 2,744 | #### Clustering Module Old ####
# Named vector of choices for clustering methods
# These are the available methods for Spatial Shrunken Centroid clustering
choices_ssc_method <- c("Gaussian= Spatially-aware (SA) weights", "Adaptive= Spatially-aware structurally-adaptive (SASA) weights")
names(choices_ssc_method) <- c("... |
f09df13ebc9cd6fcdf7ee09568effc82c42214f11d50ca47427c2947ce7be627 | R | 129,365 | 3,008 | ---
title: "X-ray"
output: html_document
date: "2024-02-19"
editor_options:
chunk_output_type: console
---
```{r setup, include=FALSE}
knitr::opts_chunk$set(echo = TRUE)
```
## Load required library
```{r Load dependencies}
suppressMessages(library(dplyr))
suppressMessages(library(DESeq2))
suppressMessages(librar... |
7a7721f46d6d72725e459e9e409bad15a5535c3e554ccc9163beccb1bc9aae56 | R | 132,050 | 2,002 | #' Write code for loading libraries
#'
#' @param lib vector of libraries
#'
#' @rdname wrLib
#' @export wrLib
#'
wrLib <- function(lib) {
oup = ""
for(iLib in lib){
oup = paste0(oup, "library(", iLib, ") \n")
}
glue::glue(paste0(oup, "\n"))
}
#' Write code for loading objects for server.R
#'
#' @param pref... |
28002d5a4303ced848b63df4b7776360e405b1da72aa58ad151e58a64f7016a9 | R | 132,937 | 2,493 | #the purpose of this script is to filter out ambient RNA using SoupX program and exclude doublets using scDblFinder
#load required libraries
libs <- c( 'Seurat','dplyr','tidyr','ggplot2','scDblFinder','SoupX')
lapply(libs, require, character.only = TRUE)
#create basic clustering for sample
#load filtered sample
F_... |
be805c4327e41ebe3eb5738c4ba51969b75f432ecbdba7a447daab6e5f681e74 | R | 133,710 | 2,618 | # the purpose of this script is to investigate a limited number of cell-types in more detail
# read in required libraries
libs <- c( 'gplots','stringi','reshape2','cowplot','RColorBrewer',
'sctransform','stringr','org.Mm.eg.db','AnnotationDbi',
'IRanges','S4Vectors','Biobase','BiocGenerics','clust... |
f3f292e3f5e3fa1ddb4ffd943f747ba89076f90601ca459749fea07e03bcd526 | R | 134,374 | 3,227 | #' @title Write code for loading libraries
#' @description Write code for loading libraries
#' @param lib A string/vector of libraries
#' @author John F. Ouyang
#' @importFrom glue glue
#' @export
#'
wr_lib <- function(lib) {
oup <- ""
for (iLib in lib) {
oup <- paste0(oup, "library(", iLib, ")\n")
}
glue::... |
1f33cabfd5920e0b7301326154d8f7a1a64ec2b105f696100c71bc3b24444198 | R | 138,798 | 2,249 | ---
title: "Descriptives of Data"
author: "Claire Campbell"
date created: "2/8/2022"
date knitted: "Version `r format(Sys.time(), '%B %d, %Y')`"
output:
html_document:
df_print: paged
toc: true
toc_float: true
---
```{r setup, echo=F}
knitr::opts_chunk$set(echo = TRUE)
#Clear existing data and graphics
r... |
cf8c3edfbcca499b2e62afa84c143a7137c82a67b80ae5082aca9d8a30c478b6 | R | 138,878 | 2,666 | library(Seurat)
library(torch)
library(SummarizedExperiment)
library(ggplot2)
library(future)
library(scrattch.hicat)
library(data.table)
library(dplyr)
library(tibble)
library(pbmcapply)
library(SCISSORS)
library(MetaMarkers)
library(gplots)
plan("multicore", workers=10)
plan()
options(future.globals.maxSize= 387... |
610c5a6b8e9ce8ab0078706e3ce9d4c8f5a7e2498f46f5dbfc31cc511c7b71a2 | R | 139,257 | 2,402 | # Created by use_targets().
# Follow the comments below to fill in this target script.
# Then follow the manual to check and run the pipeline:
# https://books.ropensci.org/targets/walkthrough.html#inspect-the-pipeline
# Load packages required to define the pipeline:
library(targets)
library(tarchetypes)
library(tidy... |
ab3570a43ed8697384223f5f3d4ce6d08ad78212fcc4df8bc58d8bc72836edc8 | R | 139,397 | 3,297 | #%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
#################### GENE EXPRESSION PLOTTING (2D) ####################
#%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
#' Customize FeaturePlot
#'
#' Create Custom FeaturePlots and preserve scale (no bin... |
9eabacedfb71609d9003c35cc9e12291f13687055842cc9b8fcf217c902d3751 | R | 144,383 | 3,418 | library(shiny)
library(Seurat)
library(ggplot2)
library(tibble)
library(cowplot)
library(viridis)
library(dplyr)
library(ggsci)
library(ggrepel)
library(tidyverse)
library(plotly)
library(htmlwidgets)
library(reshape2)
library(Hmisc)
library(corrplot)
library(pheatmap)
library(grid)
library(MAST)
library(shinydashboard... |
1442cc729991f47d2a9f0749a9766546fd656eb2992931b7df353e1f66724d95 | R | 146,522 | 3,306 | ########################################################################################################
# Code for performing Differential Gene Expression Analysis on Exp. 9-2 (Aldh1l1) and 10-1 (Camk2a)
# row means >=10 filter before dds and splicing
# Christina Ramelow, MS
# Date: 02/27/2024
########################... |
4bfd552ad7eaf597b800ed84f558169467ff996a4881788c54ba70ccca10dc01 | R | 147,608 | 3,157 | ### visualization scripts
library(Seurat)
library(openxlsx)
library(gridExtra)
library(tidyr)
library(tibble)
library(RColorBrewer)
library(VennDiagram)
library(SPOTlight, lib.loc = "./Rlib4.2.2/")
#library(SpatialExperiment)
library(ggplot2)
library(ggridges)
library(cowplot)
library(aplot)
library(ggpubr)
library(pa... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.