YuanTian1991 / ChAMP

21 stars 23 forks source link

champ.DMP return empty df #1

Open klevdiamanti opened 6 years ago

klevdiamanti commented 6 years ago

Hi, When running champ.DMP with champ.DMP(beta = dtTmp, pheno = as.factor(phenos), compare.group = NULL, arraytype = "450K", adjPVal = 0.05, adjust.method = "BH") I see a message that there were some 289k DMPs. However, the resulting dataframe is empty.

When I perform the analysis manually following the code from your scripts: df <- data.frame(pheno=pheno) model.matrix <- model.matrix(~ pheno, data=df) fit1 <- lmFit(beta,model.matrix) fit2 <- eBayes(fit1) DMP <- topTable(fit2,coef=2,number=nrow(beta),adjust.method=adjust.method,p.value=adjPVal) the dataframe DMP contains the 289k sites.

There seems to be a minor bug in your steps after you calculate the DMP dataframe which I do not have time to debug now. Please take a look at it so that others do not face the same issue.

YuanTian1991 commented 5 years ago

Thanks for your remind, I will have a look.

And sorry for the late replay, I used to answer questions via email, so ignored GitHub issue. Will start here as well in the future