I am attempting to use methylkit to analyse my RRBS data but cannot seem to be able to import my files. I have .bam files generated from bismark. I read I can use function processBismarkAln to read these kind of files into methylkit, but R encounters a fatal error when I try.
Here is my code:
file.list = list("Final_145A.sorted.dedup.bam") myobj = processBismarkAln(location = file.list, sample.id = list("test145"), assembly = "btaUMD3", save.folder = NULL, save.context = c("CpG"), read.context = "CpG", nolap = FALSE, mincov = 10, minqual = 20, phred64 = FALSE, treatment = c(0))
not sure of what is going on. Do I need to do any extra processing in the bismark .bam file before importing it into methylkit? If yes, what should I do? Specific codes would be appreciated since I am very new to this.
R version 3.3.3 (2017-03-06) Platform: x86_64-apple-darwin13.4.0 (64-bit) Running under: OS X Yosemite 10.10.5 locale:  en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8 attached base packages:  parallel stats4 stats graphics grDevices utils datasets methods base other attached packages:  methylKit_1.0.0 devtools_1.12.0 GenomicRanges_1.26.3 GenomeInfoDb_1.10.3  IRanges_2.8.1 S4Vectors_0.12.1 BiocGenerics_0.20.0 loaded via a namespace (and not attached):  Rcpp_0.12.9 plyr_1.8.4 XVector_0.14.0  R.methodsS3_1.7.1 bitops_1.0-6 R.utils_2.5.0  tools_3.3.3 zlibbioc_1.20.0 mclust_5.2.2  digest_0.6.12 memoise_1.0.0 tibble_1.2  gtable_0.2.0 lattice_0.20-34 fastseg_1.20.0  Matrix_1.2-8 coda_0.19-1 rtracklayer_1.34.2  withr_1.0.2 stringr_1.2.0 gtools_3.5.0  Biostrings_2.42.1 grid_3.3.3 Biobase_2.34.0  data.table_1.10.4 qvalue_2.6.0 emdbook_1.3.9  XML_3.98-1.5 BiocParallel_1.8.1 limma_3.30.12  ggplot2_2.2.1 reshape2_1.4.2 magrittr_1.5  GenomicAlignments_1.10.0 scales_0.4.1 Rsamtools_1.26.1  MASS_7.3-45 splines_3.3.3 SummarizedExperiment_1.4.0  assertthat_0.1 bbmle_1.0.18 colorspace_1.3-2  numDeriv_2016.8-1 stringi_1.1.2 RCurl_1.95-4.8  lazyeval_0.2.0 munsell_0.4.3 R.oo_1.21.0