sha256 stringlengths 64 64 | language stringclasses 28
values | size int32 1 491k | lines int32 1 23.2k | content stringlengths 1 200k |
|---|---|---|---|---|
199351df279d751a8958eabc59c642a3b8e6eadce9fa2f68a4ccebeaec078ad1 | R | 1,626 | 38 | library(scDblFinder)
samples_dir <- "C:/Users/mauri/Desktop/scRNAseqR/data/samples/sakshi NGN2 microglia"
sample_name <- "NSM"
data.data <- Seurat::Read10X(data.dir = file.path(samples_dir, sample_name, "filtered_feature_bc_matrix"), strip.suffix = TRUE)
data <- Seurat::CreateSeuratObject(counts = data.data, project ... |
f1ca8a1d0fd7af08bf92f453992d406318e2bde3b042c04749998c977f7af172 | R | 1,631 | 43 | library(dplyr)
dat <- read.csv("F:\\Manuscript\\ATAC\\figure\\ori_Tissue_stage_specific\\ReadCount\\ATAC-Tissue_specific.peaks.csv", header = T) %>% arrange(.,Var1)
AnnotationFile <- read.csv("F:\\Manuscript\\ATAC\\data\\AllPeakList.merged.ReadCount.PeakToGene_Feature.csv", header = T)
AnnotationFile_f <- filt... |
bb74c451b0b19e9cf44761046cd9743205e4f457e9f2fcb312546b77a10b62ee | R | 1,632 | 61 | library(colorspace)
library(doParallel)
library(dplyr)
library(foreach)
library(grid)
library(httr)
library(magick)
library(readr)
library(spacesXYZ)
library(stringr)
library(tibble)
# This file is created by 1_Parse_Articles_from_XML.R.
articles_filepath = "all_eLife_articles.tsv"
# This is where the images download... |
5f5fadb67c7d3d2e376b5f6cc9564f1420726b2bb1fb5f95926b5bcee22740e3 | R | 1,639 | 36 |
test_that("data reduced by keywords", {
pdf(NULL) # to prevent generating an empty RPlots.pdf
path <- tempdir()
on.exit(unlink(path))
write_testyamlfile(path, analyser = c("TimeSlots", "Responses"),
changes = c("DataSettings$Stimulus$Time = 1",
"DataSettin... |
a3ce1e6a2db2c90656fe0f454a439dd0b7c7276c39d0daf7e36e6718cc8b244d | R | 1,639 | 48 | #!/usr/bin/R
# --------------------------------------------------
# Functions to process to individual / region level:
# --------------------------------------------------
library(cbrbase)
aggregatePsbulkIndRegion = function(plt.data){
# Aggregate at the projid x region level (should be single-set already):
p... |
635a416d7951611555bab3968c8316dd567a4431310f7fc56b1e9ae0576456d1 | R | 1,645 | 50 | #bigsnpr to calculate pca
#conda activate /mnt/analysis-psp/users/timchang/programs/miniconda/R3.6.3
.libPaths('/mnt/analysis-psp/users/timchang/programs/R/3.6.3/')
library(bigsnpr);library(bigreadr);library(data.table)
options(bigstatsr.check.parallel.blas = FALSE)
options(default.nproc.blas = NULL)
geno_path='/mnt... |
1cda19d6bfc4d3143d90308361d3f0ea154b06704a67643f685ebc30658de70f | R | 1,653 | 47 | options(bitmapType='cairo')
args <- commandArgs(TRUE)
wd<-args[1]
replicateFile<-args[2]
sampleFile<-args[3]
sampleName<-args[4]
setwd(wd)
rep.data<-read.table(replicateFile,header=T,sep="\t")
rep.data.x<-as.numeric(rep.data[,1])
sample.data<-read.table(sampleFile,header=T,sep="\t")
sample.data.x<-as.... |
d378bbb449048c0136c1398bd28fd1e4337a74f8d625ee96422e2c4d5ebfe5f8 | R | 1,656 | 50 | library(tidyverse)
labeled_data = read_tsv("PMC_Selected_Articles_labeled.tsv") %>%
mutate(image_file_path = str_c("PMC_Images/", Image_Number, "/original.jpg")) %>%
dplyr::rename(Class = `Conclusion (5 types listed in drop down)`) %>%
select(image_file_path, Class)
group_by(labeled_data, Class) %>%
summarize... |
76ab52259acdc0514c7481f2492038c47468eb29c1531c20e42c6be374862bc6 | R | 1,658 | 58 | library(fmri.pipeline)
# note that HPC settings like nodes and batch_code are ignored for local scheduler
w <- R_batch_job$new(
batch_directory="~/batch_test",
job_name="step1",
n_nodes=1,
n_cpus=1,
cpu_time="10:00",
r_code=c(
"Sys.sleep(100)",
"print('hi')",
"x <- 2+2"
),
r_packages=c("lme4... |
cf946246c2ccba93cfde8b011742895575f7f53d96d31241f85b723b8dcecee2 | R | 1,660 | 38 | library(testthat)
test_that("compose_l2_model_data skips identical session-level duplicates already present in run_data", {
gpa <- create_mock_gpa()
gpa$run_data$tr <- 1
gpa$run_data$session_label <- paste0("ses", gpa$run_data$session)
gpa$session_data <- unique(gpa$run_data[, c("id", "session", "tr", "sessio... |
641f20762ece13adf4b822055648b633e94682e5b8c601e8db444a35bd106f84 | R | 1,663 | 48 | test_that("YAML contrasts are nested and roundtrip into contrast_spec", {
skip_if_not_installed("yaml")
gpa <- create_mock_gpa(n_subjects = 1, n_runs = 1, n_trials = 5, output_directory = tempdir())
spec <- list(
onsets = list("onset"),
durations = list("duration"),
events = list(
stim = list(... |
ef52964c4125d4b50533106b28a463a43f2c97fe06f230739c0bb8a23b77aa34 | R | 1,663 | 58 | require(GenomicSEM)
library(data.table)
NAME <- "MetS"
ldsc.out <- "../2_ldsc/ldscout/MetS_ldscout.RData"
sumstat.out <- "../7_sumstat/MetS_sumstat.RData"
load(ldsc.out)
load(sumstat.out)
model <- "F1 =~ 1*BMI_GIANT18 + WC_Watanabe_UKB
F2 =~ 1*T2D_meta_FinR7_Mahajan22_MVP + FG_Lagou_MAGIC_noUKB + HYP_meta_F... |
e5d13097fc936d01320f2643d6695d753eb4ce48fc1b1b43f6f60220f7707bf2 | R | 1,677 | 59 | library(jsonlite)
library(mediation)
# ----------------------------------------------------------------------
# Configuration and data loading
setwd(dirname(rstudioapi::getActiveDocumentContext()$path))
config <- fromJSON("config.json")
source("helpers.R")
dataframes_dir <- config$dataframes_dir
tables_dir <- config... |
b42625faf384a6185ee006575c78f6aca69cdbc4f8b606ac22b45fa80fe7d655 | R | 1,679 | 89 | #' @keywords internal
#' @noRd
#'
.subset <- function(.data, .column) {
# Make col names
.column <- enquo(.column)
# Check if column present
if(quo_names(.column) %in% colnames(.data) %>% all %>% `!`)
stop("sccomp says: some of the .column specified do not exist in the input data frame.")
.data %>%
... |
8a943c057a1678160316c70492ca4bfa3fe8f7cdf22de488905de99b36904391 | R | 1,681 | 57 | require(testthat)
require(Cardinal)
context("SpatialResults")
test_that("SpatialResults + ResultsList", {
require(datasets)
fit1 <- lm(mpg ~ disp, data=mtcars)
fit2 <- lm(mpg ~ disp + wt, data=mtcars)
fit3 <- lm(mpg ~ disp + hp, data=mtcars)
n <- 100
mz <- seq(500, 510, length.out=n)
mdf <- MassDataFrame(mz=... |
81669b4ab4102846eafaae521a69e03ae9acf63699688a9bc82c1da93118f441 | R | 1,682 | 49 | # on cluster, initiate qlogin session with 16 cores.
# qlogin -q trapnell-login.q -l mfree=4G -pe serial 16
# start R (4.0.0)
# basepath = "/net/trapnell/vol1/home/bge/novaseq/210111_Riza_sciATAC3/analyze_out/"
basepath = "/net/trapnell/vol1/HuBMAP/novaseq/210111_Riza_sciATAC3_split_sample/analyze_out/"
# out_path =... |
14377d55ee44ec5d8f3bee2d7045e01fca1f0385acc264f99f643ceeaef15c27 | R | 1,684 | 52 | library("harmony")
library("Seurat")
library("tidyverse")
setwd("./Step4.IterativeCleaning/CleanedClusters.R2")
SeuratObjs <- list.files(pattern = ".rds")
# load the files
Seurat.list <- lapply(SeuratObjs, readRDS)
# Merge into one single Seurat object
Seurat.SNC <- merge(x = Seurat.list[[1]], y = unlist(lapply(2:7,... |
932b7df409e351c42e5bb268cba6949f6f36f98583d0e95358944664e682e3dd | R | 1,684 | 49 | # on cluster, initiate qlogin session with 16 cores.
# qlogin -q trapnell-login.q -l mfree=4G -pe serial 16
# start R (4.0.0)
# basepath = "/net/trapnell/vol1/home/bge/novaseq/210111_Riza_sciATAC3/analyze_out/"
basepath = "/net/trapnell/vol1/HuBMAP/novaseq/210111_Riza_sciATAC3_split_sample/analyze_out/"
# out_path =... |
ce073e5ff65bafae0a4bfa5991a7081a3d8d57cb886931e6cabbf5f07e4dea24 | R | 1,684 | 60 | ---
title: "DeepComBat package tester"
output: html_document
---
# Preprocessing
```{r}
library(tidyverse)
library(torch)
library(neuroCombat)
library(CovBat)
#General
library(tidyverse)
library(reshape2)
library(matlib)
library(matrixStats)
library(forcats)
#DeepComBat
library(torch)
library(torchvision)
library(ne... |
16d6629f4f481e4892c7074e6e1ece49e1b79b75182747f3b010a8bc69c00daa | R | 1,687 | 38 | library(data.table)
library(dplyr)
for(tis in c("Brain", "Lung", "Muscle", "Heart")){
for(dir in c("m6A2ha", "ha2m6A")){
SMR_res <- data.frame()
for(i in 1:22){
SMR_res0 <- fread(paste0("~/SMR/", tis, "_", dir, "_smr/chr", i, ".msmr"), sep = "\t", header = TRUE)
SMR_res <- bind_rows(SMR_res, SMR_res0)
}
... |
261295a57d74ee2bc5a648b85d2cf8a5de119fd8624e1717320b425eb9df3db3 | R | 1,688 | 42 | #' @name palette_colorblind
#' @aliases palette_colorblind colors,palette_colorblind
#'
#' @title Color suggestions for `hyperSpec` users
#'
#' @description
#' In \pkg{hyperSpec} the user may use any color name/format known to `R`.
#' An important fact to keep in mind is that most people with normal vision
#' cannot di... |
3da621c553eec4746e06523f060efc90285c657fb62a2585d7e866b6af5102ad | R | 1,692 | 52 | test_that("mat2df converts numeric matrices like matrix melt", {
mat <- matrix(as.numeric(seq_len(6)), nrow = 2)
row_key <- c(1L, 2L, 1L, 2L, 1L, 2L)
col_key <- c(1L, 1L, 2L, 2L, 3L, 3L)
signal <- as.numeric(seq_len(6))
expect_identical(
fmri.pipeline:::mat2df(mat, value_name = "signal", varnames = c("vn... |
fac5a7f52b27d4c482ef788f0f529acc43bc5e20e49a95442697a749a2bd410b | R | 1,695 | 45 | library(testthat)
test_that("old .sample/.cell_group argument style works with placeholders", {
skip_cmdstan()
suppressPackageStartupMessages({
library(dplyr)
})
test_data <- tibble::tribble(
~orig.ident, ~micro_conf, ~sex, ~age, ~manual_fine, ~count,
"NS031", "yes", "F", 31, "Memory B cells", 1... |
809cbfdb528de44d488caa16d50a558d2ed7537e64ecb8925661354787a76561 | R | 1,698 | 51 | # on cluster, initiate qlogin session with 16 cores.
# qlogin -q trapnell-login.q -l mfree=4G -pe serial 16
# start R (4.0.0)
# basepath = "/net/trapnell/vol1/home/bge/novaseq/210111_Riza_sciATAC3/analyze_out/"
basepath = "/net/trapnell/vol1/HuBMAP/novaseq/210111_Riza_sciATAC3_split_sample/analyze_out/"
# out_path =... |
90de782a31b388eda2b2ac44fc64af29798bfcf56e54fa733e6bdedda79a8b30 | R | 1,701 | 59 |
# Function -------------------------------------------------------------------
#' @name DEPRECATED-options
#' @concept deprecated
#'
#' @title (DEPRECATED)
#' Options for package \pkg{hyperSpec}
#'
#' @description
#'
#' These functions are **deprecated**.
#' Use [hy_get_option()], [hy_get_options()], or [hy_se... |
45f96125f34a555857d92ef318e5b50d79960893d11fd32ff3dc5d591878cfb6 | R | 1,707 | 49 | # This script reformats the output bed files from module 01 with raw call evidence
# to match desired input for de novo SV filtering
# Define args and load libraries
args = commandArgs(trailingOnly=TRUE)
require(plyr)
library(data.table)
library(tidyverse)
input_bed <- args[1]
input_ped <- args[2]
out_probands <- arg... |
21d44798bca70733eb95f348e1e74bda32e56639c32d1573fa5f4cafbe3e6232 | R | 1,710 | 29 |
# plot the number of transcripts unique and common to DN and NeuN
p3 <- class.files$targ_sorted %>% group_by(associated_gene, dataset) %>% tally() %>%
ggplot(., aes(x = associated_gene, y = n, fill = dataset)) + geom_bar(stat = "identity", position = position_dodge()) +
labs(x = "Gene", y = "Number of isoforms")
... |
7acb48813ed2556d60048014ec4217ab9ca8b79ecffc1490bb6bec58002ae531 | R | 1,710 | 58 | require(GenomicSEM)
library(data.table)
NAME <- "MetS_noUKB"
ldsc.out <- "../2_ldsc/ldscout/MetS_noUKB_ldscout.RData"
sumstat.out <- "../7_sumstat/MetS_noUKB_sumstat.RData"
load(ldsc.out)
load(sumstat.out)
model <- "F1 =~ 1*BMI_GIANT15_noUKB + WC_GIANT_noUKB
F2 =~ 1*T2D_meta_FinR7_MVP_noUKB + FG_Lagou_MAGIC... |
1e527c5010eec66e71c0bd91679c19d06e0205ad926e804ab0dad41d8ff20679 | R | 1,714 | 48 | ####################################################################################################
###
### File: 07_hmm_illustration.r
### Purpose: Creating a illustration for the HMM models idea
### Authors: Gabriel Rodrigues Palma, Rafael Moral
### Date: 10/04/23
###
##########################################... |
07a5643587b4932a08367a1cef9635107f1e1a97c04a503bdb2ae26bac297894 | R | 1,715 | 33 | library(tidyr)
library(dplyr)
phenotype_suffix = snakemake@params[['phenotype_suffix']]
linear_model_res_path = snakemake@params[['linear_model_res_path']]
all_combined_metrics = readRDS(file.path(linear_model_res_path, 'plotting_data', paste0('all_recomputed_metrics_test_', phenotype_suffix,'.Rds')))
baseline_btyp... |
747fc28ad39eede1fab9cad4b66a8ad34ea2405fbc51ee349f942005df9d8010 | R | 1,716 | 50 | #! /usr/bin/env Rscript
##meant to generate cutoffs for different copy states##
##first input is a PE file##
## second input is output filename for final matrix of cutoffs##
args <- commandArgs(TRUE)
file=args[1]
outputfile=args[2]
median_matrix=read.table(file)
output_matrix=matrix(,ncol=3,nrow=5)
for (i in 0:3) ... |
940ec79952a9c2f80b2d3a50c10dbc475aa3af16cd06e0ec46463945d6253920 | R | 1,723 | 55 | options(bitmapType='cairo')
args <- commandArgs(TRUE)
wd<-args[1]
inputFile<-args[2]
setwd(wd)
data<-read.table(inputFile,header=F,sep="\t")
data.x<-as.numeric(data[,1])
x.tmp<-sort(data.x)
x.tmp.size<-length(x.tmp)
x.tmp.topIndex=floor(x.tmp.size*.99)
x.tmp.bottomIndex=floor(x.tmp.size*.01)+1
x.tmp.... |
f5bf64b986f99bc2c829154ebc544e54f3cd2593827321828dae1c4d1cb577bd | R | 1,730 | 57 | #' @name DEPRECATED-guess.wavlength
#' @concept deprecated
#'
#' @title (DEPRECATED)
#' Guess wavelengths from character vector
#'
#' @description
#'
#' These \pkg{hyperSpec} functions are **deprecated** and not maintained any
#' more. You should not use these.
#' Currently they are present due to back-compatibi... |
67963d7c63a895bcf22fa9154466e4911b78c8a21600cde5da2e374fef1cc21f | R | 1,734 | 54 | #' Helper function to fit betabin model while handling common warnings/errors
#'
#' Just wraps betabin to return either the fit or warning description. Warnings
#' and errors occur when the model doesn't converge. These will be flagged for
#' removing downstream.
#'
#' @description This function fits a beta-binomial mo... |
d7dbee9fbb2565e317ba0a0a63d7b983cc0d6766e18cb9627eb84e9652617abf | R | 1,739 | 68 | require(testthat)
require(Cardinal)
context("read/write imzML and Analyze 7.5")
test_that("read/write continuous", {
path <- CardinalIO::exampleImzMLFile("continuous")
mse <- readImzML(path)
expect_true(is(mse, "MSImagingExperiment"))
path2 <- paste0(tempfile(), ".imzML")
writeImzML(mse, path2)
mse2 <- readI... |
8c19450ccb25047685b1a24ed6c74b4f1dc93cae1a3909cca997df32e60a0524 | R | 1,745 | 49 | options(bitmapType='cairo')
args <- commandArgs(TRUE)
wd<-args[1]
vector1File<-args[2]
vector2File<-args[3]
sampleName<-args[4]
setwd(wd)
vector1.name<-basename(vector1File)
vector1.data<-read.table(vector1File,header=T,sep="\t")
vector1.data.x<-as.numeric(vector1.data[,1])
vector2.name<-basename(vect... |
dffd5f5aa6a7f79c390c7ac517fab9f8d332bd467e47cb6d8054b1a1ad2fe9e1 | R | 1,747 | 59 | library(GenomicRanges)
library(tidyr)
library(dplyr)
library(regioneR)
setwd('~/hail/hail-files/SV')
inh <- read.table('annot.inhsubset.filter.bed', header=TRUE, comment.char = '')
colnames(inh)[1] <- 'chr'
inhGR <- toGRanges(inh)
args = commandArgs(trailingOnly=TRUE)
bed <- args[1]
CN <- args[2]
pheno <- args[3]
outf... |
663b5bd5770aa6a8ce5f8354db20e23b728f4a3351ace098722b8e43fd8689d9 | R | 1,750 | 37 | ## ----------Script-----------------
##
## Author: Szi Kay Leung (S.K.Leung@exeter.ac.uk)
## Purpose: Generate post-sqanti plots for summary of ONT targeted mouse transcriptome datasets
##
## --------------------------------
## ---------- packages -----------------------------------------
suppressMessages(library("d... |
a089bf623cd75fab470f0a0209f57477865f7f28a05d3e280856cbbc100ca24d | R | 1,753 | 63 | #' @name DEPRECATED-read.mat.Witec
#' @concept moved to hySpc.read.mat
#'
#' @title (DEPRECATED)
#' Read `.mat` file into `hyperSpec` object
#'
#' @description
#'
#' These data input functions are **deprecated** and they will be removed in
#' the next release of \pkg{hyperspec} package.
#' Now functions in packa... |
b817f7431bf5b7d39888c5ea98c972501b82da03b608f36e8cc51947a6bb331c | R | 1,753 | 63 | options(bitmapType='cairo')
minor.ticks.axis <- function(ax,n,t.ratio=0.5,mn,mx){
lims <- par("usr")
if(ax %in%c(1,3)) lims <- lims[1:2] else lims[3:4]
major.ticks <- seq(floor(mn),ceiling(mx),1)
labels <- sapply(major.ticks,function(i)
as.expression(bquote(10^ .(i)))
)
a... |
124d56efda6d3fe35934e433a1af3295ab6d48f419445f4046af88a6166ff780 | R | 1,754 | 61 | ## <----------------- LOAD LIBRARIES
library(data.table)
## <--------------- MAIN
## Store command line argument to variable
args <- commandArgs(trailingOnly=TRUE)
iter <- as.numeric(args[1]) # current iteration
message(iter)
## Get HPO terms with proband N from hpo_sig
get_hpo_n <- fread("/path/to/hpo_prs_int_cou... |
cd153adcb27ebee30d6804b006b888908dccffcb3bf68eea7d7fb60d9a7e6642 | R | 1,758 | 67 | test_that("build_l3_models warns when L2 models are not yet defined", {
gpa <- create_mock_gpa(
n_subjects = 3,
n_runs = 2,
include_l1_models = TRUE,
include_l2_models = FALSE,
include_l3_models = FALSE
)
spec <- list(
l3_models = list(
l3_age = list(
name = "l3_age",
... |
316f1e4800d0f2610d38025dfe98c8623e8751dd1f9ce2da6953fae3d429a25b | R | 1,759 | 55 | #' Helper function to fit quasibinomial model while handling common warnings/errors
#'
#' Just wraps glm to return either the fit or warning description. Warnings
#' and errors occur when the model doesn't converge. These will be flagged for
#' removing downstream.
#'
#' @description This function fits a quasibinomial ... |
18c702aed3c486a37679de85ebb1b72f01d0be3218144c9b2b554866a4e00aa2 | R | 1,766 | 48 | splitgenome <- function(CHR, POS, ref.CHR, ref.breaks, details=T, right=TRUE) {
#' Function to split a set of SNPs by their position using a reference
#' Break points should be given for the reference by chromosome
#' @keywords internal
CHR <- as.character(CHR)
ref.CHR <- as.character(ref.CHR)
POS <- as.... |
9cc21060dfab67603615ecd216803ad03ce820d654ca89e3fca72f22f530bb3d | R | 1,782 | 54 | #1. assign methylation level to different methylation group rank
#methylation level plot rank
#<5% 0
#5-15% 10
#15-25% 20
#25-35% 30
#35-45% 40
#45-55% 50
#55-65% 60
#65-75% 70
#75-85% 80
#85-95% 90
#>95% 100
#sample methylation level visualization with different methylation group rank
##line plot
... |
22593b17ba48b989df82058ad415098ca0fd743224e807c1094fdcacb24af634 | R | 1,784 | 63 | require(GenomicSEM)
library(data.table)
NAME <- "MetS_independent"
ldsc.out <- "../2_ldsc/ldscout/MetS_ldscout.RData"
sumstat.out <- "../7_sumstat/MetS_sumstat.RData"
load(ldsc.out)
load(sumstat.out)
model <- "F1 =~ 1*BMI_GIANT18 + WC_Watanabe_UKB
F2 =~ 1*T2D_meta_FinR7_Mahajan22_MVP + FG_Lagou_MAGIC_noUKB ... |
2865b56f734dea5f0b6ccf4bada9e3aa1e07e8bc3e8a02d5de57a992e6e77c62 | R | 1,784 | 59 | #= # Introduction ----
#' This file was adapted from < https://github.com/yihui/knitr/blob/master/inst/examples/knitr-spin.R>.
#' This is a special R script which can be used to generate a report. You can
#' write normal text in roxygen comments.
#'
#= # Quick Start ----
#= ## Options ----
#' First we set up some optio... |
06ea553ffb22eb9070b988e6c926ef06f81fb0990b9543d1b57fd39690984bb6 | R | 1,785 | 63 | #' Color coding legend for factors
#'
#' Modifies a list of lattice arguments (as for [lattice::levelplot()], etc.) according to
#' the factor levels. The colorkey will shows all levels (including unused), and the drawing colors
#' will be set accordingly.
#'
#' `trellis.factor.key` is used during `levelplot`-based plo... |
b05ec997ac615181839cedf5428deb867089755ff396d0ec09323a9ccf2619c1 | R | 1,791 | 47 | ##AGE gene enrichement analysis
dat <- read.csv("F:\\ATAC\\processFiles\\POE05112023\\MG_AllGenomePeakReadNumber.NoDistal.GroupByGene.csv", header = T, row.names = 1)
geneList <- rownames(dat)
AGE <- read.csv("F:\\RNA_20221101\\02_ModifiedGenome\\D_AGEgeneSelection\\result\\AGE.list.csv", header = T, row.names = 1... |
341ef8b7c36735ce4aeb1ca81a715326f7180779b7e4cea1c23676b1f7728dc6 | R | 1,798 | 51 | setwd("F:\\Manuscript\\RNA\\Ori\\figure\\AGE_POE_TissuesVenn")
library(VennDiagram)
##POE
Brain <- read.table("POE_Brain_bias2.txt", header=F)[,1]
Liver <- read.table("POE_Liver_bias2.txt", header=F)[,1]
Muscle <-read.table("POE_Muscle_bias2.txt", header=F)[,1]
Placenta <-read.table("POE_Placenta_bias2.txt", ... |
3ff70b3dee96a7e26b84b754e29086a50ca7b96d16869398a2ad1eaf01c68c6b | R | 1,800 | 38 | data <- qs::qread("C:/SynologyDrive/Projects/scRNAseqR/results/SB_V1/SB/SB.qs")
selection_markers = c("MAP2", "DCX", "NEUROG2")
# selection_markers = c("VIM", "S100B", "SOX9")
# selection_markers = c("AIF1", "CSF1R", "SPI1")
Seurat::Idents(data) <- data$seurat_clusters
data <- Seurat::FindSubCluster(
object = data,
... |
5b9274eefa89a85e798bee66fe393e832021c329c05d6933bd9ffe675acdb25e | R | 1,801 | 49 | require(GenomicSEM)
library(data.table)
NAME <- "MetS"
log.dir <- "./logs/"
dir.create(log.dir, showWarnings = FALSE)
log.dir <- paste0(log.dir, NAME)
dir.create(file.path(log.dir), showWarnings = FALSE)
setwd(log.dir)
sumstat.dir <- "../../gwas/EasyQC/results/"
reference.file <- "reference.1000G.maf.0.005.txt"
sav... |
09d1db66265210ced085290ddb256c112048d4966a81af0d7907e0948ee49cb6 | R | 1,803 | 63 | require(GenomicSEM)
library(data.table)
NAME <- "MetS_noUKB_independent"
ldsc.out <- "../2_ldsc/ldscout/MetS_noUKB_ldscout.RData"
sumstat.out <- "../7_sumstat/MetS_noUKB_sumstat.RData"
load(ldsc.out)
load(sumstat.out)
model <- "F1 =~ 1*BMI_GIANT15_noUKB + WC_GIANT_noUKB
F2 =~ 1*T2D_meta_FinR7_MVP_noUKB + FG... |
b5ef1a64517c9a28d250fb8141cd728ebd4f0572f83269377b9638198db6e027 | R | 1,805 | 48 | #bigsnpr to calculate pca
#conda activate /mnt/analysis-psp/users/timchang/programs/miniconda/R3.6.3
#conda install r-codetools r-matrix
.libPaths('/mnt/analysis-psp/users/timchang/programs/R/3.6.3/')
#also install bigsnpra, RhpcBLASctl
library(bigsnpr);library(bigreadr);library(data.table)
geno_path='/mnt/analysis-ps... |
f7fccabc9475b3ba6dc79945fffa60d4672c698703de584c0938096d9e9b9206 | R | 1,813 | 59 | #!/usr/bin/R
# -----------------------------------------------------------
# Make the set of shared DEGs "All_All" for every combination
# Updated: 03/27/22
# -----------------------------------------------------------
library(cbrbase)
set_proj('DEVTRAJ', 'multiRegion')
source(paste0(bindir, 'multiRegion/load_metadata.... |
4590046de23dfe56cf5a18b8cf27c35cf1faae8170fe8a13e5178ddc6ffedf93 | R | 1,818 | 41 | setwd("/media/hansruedi/3b32f153-0651-4d56-b863-9b070ac7dd55/home/hansruedi/Brain_region_final")
library(ggplot2)
library(Seurat)
Exc_part1 <- readRDS(file = "Ex_raw_set1_2_subset2000.rds")
Exc_part2 <- readRDS(file = "Ex_raw_set2_2_subset2000.rds")
Inh <- readRDS(file = "In_raw_mscores_integrated2_subset2000.rds"... |
4b471a8b51aa53b0c02967a664b055eee6dca7940d72bc0be71d444082c47628 | R | 1,821 | 79 | ---
title: "Responses Guide for NosaAnalysis"
author: "Julia Thüringer"
date: '`r Sys.Date()`'
output:
html_document: default
pdf_document: null
vignette: >
%\VignetteIndexEntry{Responses Guide for NosaAnalysis}
%\VignetteEngine{knitr::rmarkdown}
\usepackage[utf8]{inputenc}
---
### Description
```{r descrip... |
a710573cf8082cc2eb11ea647d4aeedf4efb39a6e114759b16a1c7fafb978f76 | R | 1,823 | 36 | library(osfr)
source("validation/calculate_performance_function.R")
library(readr)
library(dplyr)
library(ASySD)
# get labelled duplicate sets from OSF project
asysd_validation_project <- osf_retrieve_node("https://osf.io/2b8uq/")
files <- osf_ls_files(asysd_validation_project)
osf_download(files[7,], path="validation... |
7141247b3aaa2ddaadd166bd8c8d9646f087d929a2e5470586eb909b443b6842 | R | 1,824 | 47 | #!/usr/bin/env Rscript
# This script is used to modify the SR bg info for common (freq > 50) SVs with SR support on both breakpoints
# Sets PESR evidence metrics to 0 at common sites where there is SR support on both sides.
library("optparse")
option_list = list(
make_option(c("-p","--pedfile"), type="charact... |
487150af9a0b7a7663ac00aedca7e0755e73fbeeb362c4ce3c5ed6c422d6b2bf | R | 1,827 | 44 | rm(list=ls())
load("CPM_exp.RData")
load("sig_res/markers100.RData")
library(ssgsea.GBM.classification)
source("~/ssgseaMOD.r")
marker <- rep(1,length(markers100$mes))
names(marker) <- markers100$mes
mod.generate(marker,out="mes.mod")
marker <- rep(1,length(markers100$pn))
names(marker) <- markers100$pn
mod.generate(m... |
9901325daa6373d2310be193b69eccf53acd7ddb9eab1028a4e143b74887b743 | R | 1,830 | 63 | #!/usr/bin/R
# ------------------------------------------------------
# Load all of the modules and save supplementary tables:
# Updated 06/20/2022
# ------------------------------------------------------
library(cbrbase)
set_proj('DEVTRAJ', 'multiRegion')
if (!exists("cellmeta")){
source(paste0(sbindir, 'load_meta... |
56eb9c1ed2d5dd624d33177734f66ed14899cf6cdb27659a31086fc6008368cd | R | 1,831 | 36 | # Tmisc()
# setwd(attachroot("/WORK/myRpackages/lassosum/inst/data"))
# Tim.load(Rplink)
# set.seed(1000)
# chr22 <- attachroot("~/DATA/1000G/PLINK/chr22")
# chr21 <- attachroot("~/DATA/1000G/PLINK/chr21")
# subsample(bfile=chr21, out="chr21", maf=0.05, fill.missing.a2=T,
# keep=logical.vector(1:200,2504), p=... |
a031a3e0c2c164704da21a384ea2b23b958f37b831a678150270d64071f19768 | R | 1,838 | 63 | library('RColorBrewer')
library('MAST')
library('data.table')
library('Seurat')
library('biomaRt')
library('lme4')
setwd("./Projects/SNCSynuclein")
# load the seurat object
Seurat.SNC.final <- readRDS("Step5.FinalClustering/Seurat.SNC.final.rds")
# set the levels for factors: Pathological Dx
Seurat.SNC.final$Dx <- N... |
fb7fbe923cc5a756c84d58ed25bfdb9c4892b7e21640ea1baa1b72320f33661d | R | 1,839 | 61 | sink("06_cML_MA_DP.parallel.log")
library(data.table)
library(dplyr)
library(MRcML)
library(foreach)
library(doParallel)
n_parallel <- 5
dir_in <- "cml_ma_input/"
dir_out <- "cml_ma_dp_result/"
dir.create(dir_out, showWarnings = FALSE)
# Metadata
file_in_mr_result <- "tsmr_best_sig_result.csv"
df_mr_result <- fread... |
5c5a706c11471b3ad054f36e5e1e06511e538ba8be4fef8d19f353505eef96c7 | R | 1,846 | 61 | # Gather cognitive tests and confounds into one file.
# Output:
# pred_all.csv cognitive tests and confounds (i.e., Age, Gender).
#Load packages.
library(tidyverse)
#Set outpath.
subgroup <- 'full'
outpath <- paste0('../outputs/c_cognition/',subgroup,'/')
dir.create(outpath,recursive=T)
#Read in subjects.
subjects <... |
d09f50698beb0e2e2f1d2562d3e86701f07c09d6f1acafb00df599bd607e4ef6 | R | 1,846 | 53 |
#' ---
#' title: "Generate a complete library range object"
#' author: "Tomas Bjorklund"
#' output:
#' pdf_document:
#' highlight: tango
#' geometry: margin=0.7in
#' ---
#' This short script generates a lookup scoring table of the AAV plasmid library so that it follows the same structure as the mRNA samples so t... |
471c3b4c3d8a1ebfd72bb9ac221358bf2a1905355390ca65aae809b2aaec2f92 | R | 1,847 | 53 | test_that("FLAME fallback TSV records are promoted to lgr estimation logs", {
tmp <- withr::local_tempdir()
feat_dir <- file.path(tmp, "cope1.feat")
dir.create(feat_dir, recursive = TRUE)
fallback_tsv <- file.path(feat_dir, "flame_runner_fallbacks.tsv")
writeLines(c(
"timestamp_utc\tpid\tflame12_status\t... |
47c18a4b5e2fd6092be902e6bb2338acf6dff36e77a625b94aaaf2389e54aaed | R | 1,847 | 57 | library(Seurat)
library(ggplot2)
library(ggpubr)
options(future.globals.maxSize = 4000 * 1024^20)
Sys.setenv('R_MAX_VSIZE'=2500000000000)
dir<-read.csv(file="sample.lst")
dataList=dir$orig.ident
dataList <- lapply(X = dataList, FUN = function(x) {
print (x)
x <- readRDS(file=paste0( x,".rds"))
})
#print ("d... |
c96dc7d52d21ce29f77446d3dc0caa3487eef7ac26dfb45809cd49ab33135204 | R | 1,850 | 61 | #' @name DEPRECATED-spc-rubberband
#' @concept deprecated
#'
#' @title (DEPRECATED)
#' Rubberband baseline correction
#'
#' @description
#' These \pkg{hyperSpec} functions are **deprecated** and not maintained any
#' more. You should not use these.
#' Currently they are present due to back-compatibility reasons ... |
8356e28f28a1aacdf0d8370cd080abf49a4cdf2433418e40ebdf9ac5a6c2d865 | R | 1,855 | 68 | #!/usr/bin/R
# ---------------------------------------------------
# Plot the RNAscope quantification for the thalamus:
# Updated 12/07/2021
# ---------------------------------------------------
library(cbrbase)
set_proj('DEVTRAJ', 'multiRegion')
source(paste0(bindir, 'multiRegion/load_metadata.R'))
library(tidyr)
l... |
8074acc268c2c55bccae24cc0ab2ba729990be1b8513ced30b84e27048dfff79 | R | 1,858 | 86 |
#' @concept utils
.validate <- function(object) {
ncol <- ncol(object@data$spc)
if (is.null(ncol)) {
ncol <- 0
}
if (length(object@wavelength) != ncol) {
return("Length of wavelength vector differs from number of data points per spectrum.")
}
TRUE
}
# Function --------------------------------... |
d7d11f0ebfb32e0939d3eeb6f8dc0a3218023b932f9065e20221099ffd1e77c0 | R | 1,858 | 48 | # These functions contain some default arguments that worked
# in the past for creating heat maps.
# It also helps with some of the preprocessing.
library(ComplexHeatmap)
library(dplyr)
library(tibble)
library(magrittr)
library(RColorBrewer)
library(circlize)
# Input matrix pretty much needs to be exactly the heatma... |
cfcf5a4e214983f2516487593ac80382a3930bbc77b02e7831af51ad64729a05 | R | 1,859 | 50 | library(tidyverse)
library(ComplexHeatmap)
library(circlize)
library(RColorBrewer)
library(colorRamp2)
# Read in data
protein_data <- read_xlsx("~/VSN_NA_imputed.xlsx")
# Transform to format needed to make heatmap, scale and center data
protein_mat_norm <- protein_data %>%
column_to_rownames("Gene")
protein_mat_no... |
d9a32a075f38568d33fa05df485463593be95890d173d907806955de4b083b62 | R | 1,860 | 49 | require(GenomicSEM)
library(data.table)
NAME <- "MetS_noUKB"
log.dir <- "./logs/"
dir.create(log.dir, showWarnings = FALSE)
log.dir <- paste0(log.dir, NAME)
dir.create(file.path(log.dir), showWarnings = FALSE)
setwd(log.dir) # Place where the logs will be saved
sumstat.dir <- "../../gwas/EasyQC/results/"
reference.f... |
37fee16530ffc98250347b4fb522e3ae3a4448ede5e534a34b264be2669cbc0a | R | 1,862 | 42 | ## ---- include = FALSE---------------------------------------------------------
knitr::opts_chunk$set(
collapse = TRUE,
comment = "#>"
)
## ----eval=FALSE---------------------------------------------------------------
# if (!requireNamespace("BiocManager", quietly = TRUE))
# install.packages("BiocManager")
... |
24ab31f7f6ad9c11bb665d1e6db757777a7e67857186779dc0954b9050ef60c7 | R | 1,869 | 85 | options(bitmapType='cairo')
args <- commandArgs(TRUE)
name<-args[1]
dataColumn<-as.numeric(args[2])
skip<-as.numeric(args[3])
minX<-as.numeric(args[4])
maxX<-as.numeric(args[5])
fileArray=args[6:length(args)]
nFiles=length(fileArray)
cat("found ",nFiles," files.\n")
for (i in 1:nFiles) {
arg<-fileArra... |
ee304f6192696db580a30e8389903f1d458243c7345117617570a4bf36a0eb08 | R | 1,875 | 65 | require(GenomicSEM)
library(data.table)
NAME <- "MetS_firstorder"
ldsc.out <- "../2_ldsc/ldscout/MetS_noUKB_ldscout.RData"
sumstat.out <- "../7_sumstat/MetS_noUKB_sumstat.RData"
load(ldsc.out)
load(sumstat.out)
model <- "F1 =~ 1*BMI_GIANT18 + WC_Watanabe_UKB
F2 =~ 1*T2D_meta_FinR7_Mahajan22_MVP + FG_Lagou_M... |
79e0bc80821b5badaa7ee4e9c633472f8cd82df70df244b2ad8060a210628701 | R | 1,876 | 76 | #library(glmnet::glmnet)
library(testthat)
n <- 1000
p <- 20
# set.seed(1000)
X <- matrix(rnorm(n*p), n, p)
beta <- rnorm(p)
Xb <- X %*% beta
y <- Xb + rnorm(n) * p
y <- scale(y) * sqrt(n/(n-1))
X <- scale(X) * sqrt(n/(n-1))
r <- as.vector(t(X) %*% y) / n
summary(r)
summary(colSums(X^2))
summary(colSums(X))
summary(y)... |
44480bf40ef347f8150050216fcb7e796f89d0f75dea0ab4ab94ffe3019ccddf | R | 1,890 | 59 |
library(here)
suppressPackageStartupMessages({
library(tidyverse)
library(Biobase)
library(ggpubr)
require(janitor)
})
# TIS weights file, with columns for GENE and Weights
TIS_FILE <- here("ref/example_tis_weights_file.csv")
# expression set of normalized gene counts with HGNC gene identifiers saved
# as minimal ro... |
6bebea475aa51faaaa0a3383c8fcdbb84858a7571da5c55deec93ea02ca285c0 | R | 1,893 | 52 | #!/usr/bin/R
# ----------------------------------------
# Write the merged + updated subtype UMAPs
# Updated 01/07/2022
# ----------------------------------------
library(cbrbase)
set_proj('DEVTRAJ', 'multiRegion')
if (!exists("cellmeta")){
source(paste0(sbindir, 'load_metadata.R'))
}
# Create the C1/C2 (subtype ... |
2563ebfbc6aea633ce7666cc937400775d04f47c3aa7d5e3dfaaa975e37707a4 | R | 1,894 | 76 | ---
title: "Using pmlbr"
---
## Install
The [**pmlbr** package](https://github.com/EpistasisLab/pmlb) provides the following user-facing functions and variables in the R environment.
The package works for any recent version of R.
You can install the released version of **pmlbr** from CRAN with:
```{r, eval=FALSE}
i... |
e09f9bc1f05da8fb8cb945268eabf085626e250ecfa9a9624136be9269073c1d | R | 1,899 | 60 | if (identical(.Platform$OS.type, "windows")) {
test_that("compute environment executable tests require POSIX scripts", {
skip("requires executable POSIX shell scripts")
})
} else {
make_fake_executable <- function(bin_dir, name, body = "echo fake") {
path <- file.path(bin_dir, name)
writeLines(c("#!/bin/sh... |
92902f495f40e85614b5bb5e75f3c36925254a3af2bf90c53ed69b13b246b968 | R | 1,900 | 63 | library(pacman)
p_load(tidyverse, lavaan, semTools, MplusAutomation, psych, ggplot2, sjlabelled, janitor,
tidymodels, parsnip, dials, tune, finetune, xgboost, recipes, data.table, doParallel,
vip, DALEX, modelDown, corrgram, hablar, SHAPforxgboost, ADNIMERGE, vetiver, pins,
haven, magrittr, mirt, c... |
ed931bd97327b6fbee0d1e2082b67de5f3d9ec92dbb3ebe27a787260e2c0e317 | R | 1,902 | 34 | library(pacman)
p_load(tidyverse, lavaan, semTools, MplusAutomation, psych, ggplot2, sjlabelled, janitor,
tidymodels, parsnip, dials, tune, finetune, xgboost, recipes, data.table, doParallel,
vip, DALEX, modelDown, corrgram, hablar, SHAPforxgboost, ADNIMERGE, vetiver, pins,
haven, magrittr, mirt, c... |
eaa3c7bbdcc7fdfa83e20d56012da01a88bf347a62ab9f352c09d8f5d9f25370 | R | 1,903 | 87 | options(bitmapType='cairo')
args <- commandArgs(TRUE)
name<-args[1]
dataColumn<-as.numeric(args[2])
skip<-as.numeric(args[3])
minY<-as.numeric(args[4])
maxY<-as.numeric(args[5])
fileArray=args[6:length(args)]
nFiles=length(fileArray)
cat("found ",nFiles," files.\n")
for (i in 1:nFiles) {
arg<-fileArray[i]
cat("\t"... |
f8960569aeb3e517813e84ea4a6f2dceb29edbc17274f292c9a96a51cf0bf213 | R | 1,904 | 66 | #!/usr/bin/R
# --------------------------------------------------------
# Load data for the modules computed on external datasets:
# Updated 12/01/2023
# --------------------------------------------------------
library(cbrbase)
set_proj('DEVTRAJ', 'multiRegion')
library(tidyr)
# Arguments:
args=(commandArgs(TRUE))
if... |
bde6b06f729d37530cad0837d66933989d6c28a8af0c623169470237c941a302 | R | 1,906 | 44 | library("tidyverse")
library("gprofiler2")
library("data.table")
library("BiocParallel")
# load the DEG datasets
setwd("./Projects/SNCSynuclein")
# load the DEG files
DEGFileCombind <- readRDS("Step8.SubCluster.DEG/DEG.random/DEGFileCombind.rds")
Cluser <- names(DEGFileCombind)
for (i in 1:length(Cluser))
tryCatc... |
5a0afd004e6a7c9c3419bad81bf316bd368408ecbc25daf7f5f9a3ca5e106cd1 | R | 1,908 | 51 | library(lmerTest)
# library(sjPlot)
library(glmmTMB)
library(ggplot2)
library(dplyr)
library(ggeffects)
library(effects)
library(readr)
library(ggChernoff)
library(merTools)
library(lattice)
library(stringr)
# library(tidyverse)
# ['moca','lns','hvlt','bjlot','sdmt','sft','pigd','tremor','seadl','updrs3','updrs2','updr... |
c419efbb628c0bff91d7744dbb1dc48ca2a307441e20f1edbb34e69352229958 | R | 1,909 | 68 |
# Commands to set up R 4.1.2 to use
# module unload R/4.0.0
# module unload pcre2/10.35
# module load pcre2/10.39
# module load R/4.1.2
# Working off of a vignette at http://rstudio-pubs-static.s3.amazonaws.com/371411_b572e753d5e94c959cee7f05bc969839.html
# for fitting a beta binomial mixed model using glm... |
1f856ecaefe24d2bf8fd35063dda38740ef0055b4c1a0fec88104e46ecb296b5 | R | 1,910 | 40 | #Once you build your network with metacore see "Build Network using Metacore pdf" (building algorithm: direct interaction) you can run this script
#get the xls file from Metacore for mapepd and interaction convert them to csv file and proceed with the script
library(tidyverse)
cells=c("Astrocyte","Oligodendrocyte... |
15784e9301801491638a1c4dd9bf526c4b849ca1af93b72d6d74a744ddf8831d | R | 1,911 | 59 | library(tidyverse)
library(ComplexHeatmap)
library(colorRamp2)
library(circlize)
library(RColorBrewer)
# Read in data
rna_data <- read_csv("~/nepc_normalized_counts_vst.csv")
# Transform to format needed to make heatmap, scale and center data
rna_mat <- rna_data %>%
column_to_rownames("gene") %>%
t()
rownames(rn... |
a58dd7c61abe1d696a3cb3a336c9ae51305c76665b68575b2a4aca632b2691d8 | R | 1,911 | 44 |
test_that("extract additional values from ggplot_build", {
df <- data.frame( gp = rep(1:15, 2), y = rep(c(3,4), each=15), row.names = NULL)
plot = ggpubr::ggline(df, x="gp", y="y", add="mean_se")
result = data.frame( x = 1:15, y = 3.5, ymin= 3, row.names = NULL)
expect_equal(extract_plot_data(plot, additiona... |
af3b6ea70699ae643e2e2597477660bb93dfc92e3c955d3e71721812cdf527ad | R | 1,911 | 54 | ### Ref links
# http://tuxette.nathalievilla.org/?p=1696
# https://swcarpentry.github.io/r-novice-inflammation/05-cmdline/
## -----------------------------------------------------------------------------
# get the input passed from the shell script.
args <- commandArgs(TRUE)
# test if there is at least one ar... |
1b5e2d56b8e44920697e8c5ca8b0e1328c663462685d0e3e94a32125fd130092 | R | 1,914 | 66 | #!/usr/bin/env Rscript
library(vioplot)
args <- commandArgs(trailingOnly=TRUE)
if (length(args) != 2) {
stop("Usage: plot_variant_counts.R <variant_count_file> <caller>")
}
variant_count_file <- args[1]
caller <- args[2]
if (!file.exists(variant_count_file)) {
stop(paste("File does not exist:", variant_count_fi... |
fe007ff30e16c9c59b19b6834890708e989f450c41f4a66ae100cb592d72000b | R | 1,914 | 47 | library(spacexr)
library(spASE)
library(tibble)
library(data.table)
library(Matrix)
library(dplyr)
library(tidyr)
cerebellum_ref <- readRDS('../inst/extdata/reference_scrna/cerebellum_sn_ref_spacexr.rds')
PATH <- '../inst/extdata/visium/cerebellum_spatial'
counts <- fread(file.path(PATH, 'tagged_bwt2_counts_nm3.csv')... |
9f633a001509f834adc896288321288c4561dc7227a916eda47b733a22090762 | R | 1,916 | 47 | library(spacexr)
library(spASE)
library(tibble)
library(data.table)
library(Matrix)
library(dplyr)
library(tidyr)
cerebellum_ref <- readRDS('../inst/extdata/reference_scrna/cerebellum_sn_ref_spacexr.rds')
PATH <- '../inst/extdata/visium/mixture'
counts <- fread(file.path(PATH, 'tagged_bwt2_counts_nm3.csv'))
positions... |
9abb1f46a3e429ba4a449e80201afc7c25e73a14dca3e0fee05f91a8e5b0e670 | R | 1,923 | 67 | ---
title: "PeakCount Guide for NosaAnalysis"
author: "Julia Thüringer"
date: '`r Sys.Date()`'
output:
html_document: default
pdf_document: null
vignette: >
%\VignetteIndexEntry{PeakCount Guide for NosaAnalysis}
%\VignetteEngine{knitr::rmarkdown}
\usepackage[utf8]{inputenc}
---
### Description
```{r descrip... |
ab1e623eca02efcd5a8b2c97744527e9b6dd4fca92f119ac0a4182df146ea2ec | R | 1,923 | 50 | library("Seurat")
library("tidyverse")
setwd("./Projects/SNCSynuclein")
# Intergrated datasets at the batch level
Seurat.SNC.Ind <- readRDS("Step3.Clustering/Seurat.SNC.Ind.rds")
## Recluster with a higher resolution
Seurat.SNC.Ind <- Seurat.SNC.Ind %>%
FindClusters(resolution = 0.9) %>%
identity()
# visualiz... |
ea1f155e018a53d9a1348fa949335671a9ce8b86e16f24e1ce7ac84946945f8c | R | 1,925 | 68 |
#### Nonnegative matrix factorization ####
## ---------------------------------------
setMethod("NMF", "ANY",
function(x, ncomp = 3, method = c("als", "mult"),
verbose = getCardinalVerbose(), ...)
{
method <- match.arg(method)
msg <- "estimating nonnegative matrix factorization "
if ( method == "als" ) {
.Log... |
2cdcc13b8b06f0f59ef98188d56b684836daa2190e074661fc9feeb1a9ad5af1 | R | 1,931 | 43 | library(Seurat)
library(DAseq)
library(ggpubr)
library(SingleCellExperiment)
options(future.globals.maxSize = 4000 * 1024^20)
Sys.setenv('R_MAX_VSIZE'=2500000000000)
Oli<-readRDS("Oli.rds")
Idents(Oli) <- "DA"
Oli_DEG.DA<-FindMarkers(Oli, slot = "data", assay = "RNA", test.use = "MAST", ident.1 = "DA", ident.2 = "no... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.