Entering edit mode
3.3 years ago
harshraje19
▴
40
Hi Friends,
I am performing the differential methylation analysis using methylkit but it is throwing error in data frame. " Error in [.data.frame
(data, , 6) : undefined columns selected". Can anyone help me to solve this error. Following is my R cmmand lnes. Thanks
Raj
> library(methylKit)
> library(methylKit)
> file.list=list( "CpG_context_ST12_B1_F_bismark_hisat2_pe.txt","CpG_context_ST12_B2_F_bismark_hisat2_pe.txt","CpG_context_ST12_B3_F_bismark_hisat2_pe.txt","CpG_context_ST2_B1_F_bismark_hisat2_pe.txt","CpG_context_ST2_B2_F_bismark_hisat2_pe.txt","CpG_context_ST2_B3_F_bismark_hisat2_pe.txt")
>
> myobj=methRead(file.list,
+ sample.id=list("test1","test2","test3","ctrl1","ctrl2","ctrl3"),
+ assembly="Edwards",
+ treatment=c(1,1,1,0,0,0),
+ context="CpG",
+ mincov = 10,
+ pipeline = "bismark"
+ )
Received list of locations.
Reading file.
|--------------------------------------------------|
|==================================================|
Error in `[.data.frame`(data, , 6) : undefined columns selected
Maybe your file format is not the adequate for the import of the files by methylKit with the method
pipeline = "bismark"
? It says in themethRead
documentation that it expects a tabular format as shown in the github:Are the files you're imputting in that format? If not, you may input Bismark coverage or cytosine report files using the other
pipeline
options available in the functionHi. Thank you for your response.
My file look like this. Do you think it is wrong format?
Hmm no it does not look like the same format. As I said, I would suggest imputing either Bismark coverage or cytosine report files and using
pipeline = "bismarkCoverage"
or"bismarkCytosineReport"
. You can recognize the files from Bismark by doinghead
and checking with the Bismark manual.]Can i use these files,
Use either those ending in "bismark.cov.gz" or "CpG_report.txt.gz" with
pipeline = "bismarkCoverage"
orpipeline = "bismarkCytosineReport"
, respectively.It worked i used "bismark.cov.gz" file with pipeline = "bismarkCoverage". Thank you so much, i was struggling with this for week