Error When Using The Qualityscaledbstringset Function In Bioconductor
Dear All,
I am using a script to visualize/analyze BAM files which works for all the files that i have....but now I got some published data and the problems start....
So in total here is my script.....
chr <- '19'
fileName<-c("/data/lena/GG/file_1.bam")
fragment.size=200
chr.size<-seqlengths(Mmusculus)[]
which <- GRanges(seqnames=chr,IRanges(1,chr.size))
what <- c("rname", "strand", "pos", "qwidth","seq","qual")
param <- ScanBamParam(which = which,what=what)
chip.bam <- scanBam(fileName, param=param)
name <- names(chip.bam)
name
[1] "19:1-197195432" "19:1-181748087" "19:1-159599783" "19:1-155630120"
[5] "19:1-152537259" "19:1-149517037" "19:1-152524553" "19:1-131738871"
[9] "19:1-124076172" "19:1-129993255" "19:1-121843856" "19:1-121257530"
[13] "19:1-120284312" "19:1-125194864" "19:1-103494974" "19:1-98319150"
[17] "19:1-95272651" "19:1-90772031" "19:1-61342430" "19:1-166650296"
[21] "19:1-15902555" "19:1-16299" "19:1-1231697" "19:1-41899"
[25] "19:1-160594" "19:1-357350" "19:1-362490" "19:1-849593"
[29] "19:1-449403" "19:1-400311" "19:1-3994" "19:1-628739"
[33] "19:1-1785075" "19:1-58682461" "19:1-5900358"
Normally here for all the other ChIP-seqs I get one value....something like that
chr19:1-61342430
so then I do that
chip.qual <-QualityScaledBStringSet(chip.bam[[name]]$seq, chip.bam[[name]]$qual)
Error in XStringSet("B", x, start = start, end = end, width = width, use.names = use.names) :
error in evaluating the argument 'x' in selecting a method for function 'XStringSet': Error in chip.bam[[name]] : no such index at level 2
So what am I doing wrong? could you please help me?
Thank you in advance
Best regards Eleni
• 237 views
•
link
0 answers
No answers yet.
Log in to answer this question.
You might want to mention that this is R code. Better still, tag the question.