I tried with above example and no luck for me either. But one thing you can also consider is to convert gff to sqlite (if there are no other answers) and load it. txdb object is basically sqlite object.
GenomicFeatures makeTxDbFromGFF: Select by columns in gtf file
Hi,
I am trying to create a function to extract the promoter regions from a gtf file only for "lincRNA" and "antisense" (under "type" column in the gtf file).
I think I need to start by using GenomicFeatures to first import the gtf file:
library("GenomicFeatures")
txdb = makeTxDbFromGFF("file.gtf", format="gtf")
But I don't think the column in the gtf file called "type" was imported.
How can I import and select the columns "lincRNA" and "antisense" from the TxDb file?
(Then I think would need to select only the exons and then the regions up and downstream by gene (which I think is done by the function "promoters" in GenomicRanges))
Thank you
• 6,420 views
•
link
1 answer
Yes of course, the gtf looks like this:
#!genome-build GRCh37.p13
#!genome-version GRCh37
#!genome-date 2009-02
#!genome-build-accession NCBI:GCA_000001405.14
#!genebuild-last-updated 2013-09
1 pseudogene gene 11869 14412 . + . gene_id "ENSG00000223972"; gene_name "DDX11L1"; gene_source "ensembl_havana"; gene_biotype "pseudogene";
1 processed_transcript transcript 11869 14409 . + . gene_id "ENSG00000223972"; transcript_id "ENST00000456328"; gene_name "DDX11L1"; gene_source "ensembl_havana
• 0 views
•
link
• 0 views
•
link
Thank you for your reply, I will try that!
• 0 views
•
link
Log in to answer this question.
Could you please paste 3-4 lines from your gtf file here?