I imported a gtf-file using
makeTxDbFromGFF() and made a GRangesList of introns by:
introns = intronsByTranscript(object, use.names=TRUE)
But I get an error trying to export the introns as gff/gtf file:
export.gff(introns, "introns.gff", format="gff") Error in .local(x, ...) : Elements in a group must be on same sequence and strand
If I for instance extract genes the export works fine. How can the introns be on different strands/sequences when the genes are not? Btw, all the features in my imported gtf-file are on the same strand.
Edit: I converted the introns object to a GRanges object and it seems to work...
> sessionInfo() R version 3.2.1 (2015-06-18) Platform: x86_64-apple-darwin10.8.0 (64-bit) Running under: OS X 10.10.5 (Yosemite) locale:  C attached base packages:  stats4 parallel stats graphics grDevices utils datasets methods base other attached packages:  BiocInstaller_1.18.4 rtracklayer_1.28.10 seqinr_3.1-3 ade4_1.7-2 Biostrings_2.36.4  XVector_0.8.0 GenomicFeatures_1.20.5 AnnotationDbi_1.30.1 Biobase_2.28.0 GenomicRanges_1.20.8  GenomeInfoDb_1.4.3 IRanges_2.2.7 S4Vectors_0.6.6 BiocGenerics_0.14.0 loaded via a namespace (and not attached):  zlibbioc_1.14.0 GenomicAlignments_1.4.1 BiocParallel_1.2.21 tools_3.2.1  DBI_0.3.1 lambda.r_1.1.7 futile.logger_1.4.1 futile.options_1.0.0  bitops_1.0-6 RCurl_1.95-4.7 biomaRt_2.24.1 RSQLite_1.0.0  Rsamtools_1.20.4 XML_3.98-1.3