R での limma を用いた Differential Expression 解析
John Blischak
Instructor
x_sub <- x[1000, 1:10]
f_sub <- f[1000, ]
p_sub <- p[1:10, ]
カンマ1つのミスがデバッグの悪夢になる可能性があります:
x_sub <- x[1000, 1:10]
f_sub <- f[1000, ]
p_sub <- p[, 1:10]
# Oh no! *
クラス - 複雑なデータを格納する構造を定義する
オブジェクト - クラスの具体的なインスタンス
メソッド - 特定のクラスに作用する関数
install.packages("BiocManager")
BiocManager::install("Biobase")
# Load package library(Biobase) # Create ExpressionSet object eset <- ExpressionSet(assayData = x, phenoData = AnnotatedDataFrame(p), featureData = AnnotatedDataFrame(f))# View the number of features (rows) and samples (columns) dim(eset)
Features Samples
22283 344
?ExpressionSet
発現行列
x <- exprs(eset)
特徴量データ
f <- fData(eset)
表現型データ
p <- pData(eset)
x_sub <- x[1000, 1:10]
f_sub <- f[1000, ]
p_sub <- p[1:10, ]
eset_sub <- eset[1000, 1:10]
nrow(exprs(eset_sub)) == nrow(fData(eset_sub))
TRUE
ncol(exprs(eset_sub)) == nrow(pData(eset_sub))
TRUE
boxplot(<y-axis> ~ <x-axis>, main = "<title>") boxplot(<gene expression> ~ <phenotype>, main = "<feature>")boxplot(exprs(eset)[1, ] ~ pData(eset)[, "er"], main = fData(eset)[1, "symbol"])

R での limma を用いた Differential Expression 解析