Roleren / ORFik

MIT License
33 stars 9 forks source link

computeFeatures() doesn't not work with GAlignmentPairs #126

Closed matanel-y closed 1 year ago

matanel-y commented 1 year ago

Hello,

I have paired-end RNA-seq data and single-end RFPs. I used ORFikQC() to create the .ofst files.

I am trying to use computeFeatures() as in the Ribo-Seq tutorial vignette with my data

dt_ctl1 <- computeFeatures(cds, RFP = fimport(filepath(df.rfp[5,], "pshifted")), RNA = fimport(filepath(df.rna[5,], "ofst")), Gtf = df.rfp, grl.is.sorted = TRUE, faFile = df.rfp, weight.RFP = "score", weight.RNA = "score", uorfFeatures = FALSE)

Error in checkRNA(class(RNA)) : RNA must be either GAlignments or GRanges

Class check:

RNA = fimport(filepath(df.rna[5,], "ofst")) class(RNA)

[1] "GAlignmentPairs" attr(,"package") [1] "GenomicAlignments"

If I try to change class:

class(RNA) = "GAlignments" Error in start(x) : no slot of name "start" for this object of class "GAlignments"

Any help would be appreciated! Thank you!

Roleren commented 1 year ago

ops, yes, that one is easy to fix, as paired end reads should be accepted, I just made the filter there a bit too strict, will let you know when I push a fix

Roleren commented 1 year ago

pushed, let me know if there is anything wrong downstream, else I will close the issue tomorrow

matanel-y commented 1 year ago

Works great! Thank you!