Entering edit mode
Gayatri Iyer
▴
20
@gayatri-iyer-5681
Last seen 5.2 years ago
Hi,
I am trying to run my microarray data through ComBat(in sva
packge).Below
is my sampleinfo file.
When I run it with these commands
batch = sampleinfo$Batch
mod = model.matrix(~as.factor(Covariate), data=sampleinfo)
combat_edata = ComBat(dat=edata, batch=batch, mod=mod, par.prior=TRUE,
prior.plots=FALSE)
I dont get any error and it runs with this message.
Found 10 batches
Found 3 categorical covariate(s)
Standardizing Data across genes
Fitting L/S model and finding priors
Finding parametric adjustments
Adjusting the Data
But the problem is I have 4 covariate not three.
I even ran the example dataset in SVA package
## Load data
library(bladderbatch)
data(bladderdata)
## Obtain phenotypic data
pheno = pData(bladderEset)
edata = exprs(bladderEset)
batch = pheno$batch
mod = model.matrix(~as.factor(cancer), data=pheno)
## Correct for batch using ComBat
combat_edata = ComBat(dat=edata, batch=batch, mod=mod,
par.prior=TRUE,
prior.plots=FALSE)
This also give
Found 2 categorical covariate(s) when there are three covariates in
this
dataset.
Please help,
Thank you,
Gayatri
Array name Sample name Batch Covariate C3D1 1 1 1 C3D2 2 1 1 C3D3
3 1 1
C3D5 4 2 1 C3D14 5 6 1 C3D15 6 6 1 C3D16 7 7 1 C3D17 8 7 1 C3D18
9 7 1
S3D7 10 3 2 S3D8 11 4 2 S3D9 12 4 2 S3D10 13 4 2 S3D11 14 5 2
S3D12 15
5 2 S3D19 16 8 2 S3D20 17 8 2 S3D21 18 9 2 S3D22 19 9 2 S3D23 20
10 2
S3D24 21 10 2 C25D1 22 1 3 C25D2 23 1 3 C25D3 24 2 3 C25D5 25 3 3
C25D14 26 6 3 C25D15 27 6 3 C25D16 28 7 3 C25D17 29 7 3 C25D18 30
8 3
S25D7 31 3 4 S25D8 32 4 4 S25D9 33 4 4 S25D10 34 5 4 S25D11 35 5 4
S25D12 36 5 4 S25D19 37 8 4 S25D21 38 9 4
S25D23
39 10
4
[[alternative HTML version deleted]]