zwdzwd / sesame

🍪 SEnsible Step-wise Analysis of DNA MEthylation BeadChips
Other
63 stars 33 forks source link

opensesame() behind the scene #165

Closed altuda closed 6 months ago

altuda commented 6 months ago

Hello, I would like to kindly ask you why there is a difference in betas between the opensesame and the supposedly equivalent function. Were there some changes inside the opensesame()?

betas=do.call(cbind,mclapply(searchIDATprefixes(idat_dir), function(px) getBetas(dyeBiasNL(noob(pOOBAH(readIDATpair(px))))), mc.cores=2)) head(betas) 4207113116_A 4207113116_B cg00000292 0.89670032 0.21734243 cg00002426 0.02775268 0.96295625 cg00003994 0.03310098 0.05221246 cg00005847 0.45003310 0.37307742 cg00006414 0.08853971 0.13978757 cg00007981 0.02775176 0.02527006 betas2 = openSesame(idat_dir) head(betas2) 4207113116_A 4207113116_B cg00000292 0.89382957 0.21242243 cg00002426 0.02624318 0.96299515 cg00003994 0.03059269 0.05339756 cg00005847 0.44972050 0.37410379 cg00006414 0.09228522 0.13570582 cg00007981 0.02626539 0.02593596 all(betas == betas2, na.rm=T) [1] FALSE

zwdzwd commented 6 months ago

Hi the slight difference might come from qualityMask. See more details at openSesame's prep= argument. https://bioconductor.org/packages/release/bioc/vignettes/sesame/inst/doc/sesame.html#Data_Preprocessing and here https://bioconductor.org/packages/release/bioc/vignettes/sesame/inst/doc/sesame.html#Preprocessing_Function_Code

altuda commented 6 months ago

Hello, Thank you for your response.