admin 管理员组

文章数量: 1086019


2023年12月23日发(作者:jealousvue成熟45)

source("/biocLite.R")biocLite('BiocInstaller')biocLite("DESeq2")es(c("gplots", "amap", "ggplot2"))A distributional assumption is needed because we want to estimate theprobability of extreme events (large fold change just appearing bychance) from limited replicates. The negative binomial (-Poisson) is a good choice for RNA-seq experiments becauseThe observed data at gene level is inherently counts or estimatedcounts of fragments for each feature andThe spread of values among biological replicates is more than givenby a simpler, one parameter distribution, the Poisson; and it seemsto be captured by the NB sufficiently well加载包library(DESeq2)## Loading required package: S4Vectors## Loading required package: stats4## Loading required package: BiocGenerics## Loading required package: parallel##

## Attaching package: 'BiocGenerics'## The following objects are masked from 'package:parallel':##

## clusterApply, clusterApplyLB, clusterCall, clusterEvalQ,## clusterExport, clusterMap, parApply, parCapply, parLapply,## parLapplyLB, parRapply, parSapply, parSapplyLB## The following objects are masked from 'package:stats':##

## IQR, mad, sd, var, xtabs## The following objects are masked from 'package:base':##

## anyDuplicated, append, , cbind, colMeans,## colnames, colSums, , duplicated, eval, evalq, Filter,## Find, get, grep, grepl, intersect, ed, lapply,## lengths, Map, mapply, match, mget, order, paste, pmax,## , pmin, , Position, rank, rbind, Reduce,## rowMeans, rownames, rowSums, sapply, setdiff, sort, table,## tapply, union, unique, unsplit, which, , ##

## Attaching package: 'S4Vectors'## The following object is masked from 'package:base':##

## ## Loading required package: IRanges## Loading required package: GenomicRanges## Loading required package: GenomeInfoDb

批次效应模拟#Make some simulated data with a batch effect:dds <- makeExampleDESeqDataSet(betaSD=1,interceptMean=10)dds$batch <- factor(rep(c("A","B"),each=6))#VST, remove batch effect, then plotPCA:vsd <- vst(dds)plotPCA(vsd, "batch")imageassay(vsd) <- limma::removeBatchEffect(assay(vsd), vsd$batch)plotPCA(vsd, "batch")


本文标签: 模拟 效应