BSmooth.tstat error due to NA
1
0
Entering edit mode
6.9 years ago
ttsutsui1028 ▴ 20

Dear All,

I use bsseq package for WGBS data analysis. After smoothing, I had tried to BSmooth.tstat for computing t-statistics. But BSmooth.tstat gave me following error.

bis.fit.you.tstat <- BSmooth.tstat(data, 
                group1 = c("test", "test", "test") 
                group2 = c("cont", "cont", "cont"), 
                estimate.var = "paired", verbose = T, local.correct = TRUE, mc.cores=1)

    [BSmooth.tstat] preprocessing ... done in 30.6 sec
    [BSmooth.tstat] computing stats within groups ... done in 64.8 sec
    [BSmooth.tstat] computing stats across groups ...  approxfun(xx, yy) : 
      need at least two non-NA values to interpolate

I found that several CpG site methylation has NA. Does anyone know how to remove NA containing row from bisseq object?

Best Regards, Taiki

WGBS BSmooth R bsseq • 2.4k views
ADD COMMENT
0
Entering edit mode

hello,Taiki I use bsseq package for WGBS data analysis. and i meet the same problem just as you,do you find any solution?would you please give me some advice? i am really need your help. Best wishes xia

ADD REPLY
1
Entering edit mode
6.0 years ago
ttsutsui1028 ▴ 20

Hello xia,

My solution may not be good. Since na.omit doesn't work for bsmooth out put file, I converted it to matrix and then use na.omit to remove na containing rows.

best

ADD COMMENT
0
Entering edit mode

hello,Taiki,after you give me such advice, i try to converted it to matrix,but i gives me such error message:Error in as.vector(x),There is no way to force this S4 category to become a vector, here is my command:bsseq_data <- as.matrix(bsseq_bsmooth), would you please give me some suggestion? what is your command? best wishes xia

ADD REPLY

Login before adding your answer.

Traffic: 1620 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6