Explainnation of featureCounts in-built annotation?
1
0
Entering edit mode
Jack ▴ 20
@jack-14069
Last seen 5.1 years ago

Hi all,

I use featurecounts first to get the summary of the counts and the annotation, below are the codes:

test<-featureCounts(files="test.bam", annot.inbuilt="mm10", annot.ext=NULL, isGTFAnnotationFile=FALSE, GTF.featureType="exon", GTF.attrType="gene_id", chrAliases=NULL, useMetaFeatures=TRUE,  strandSpecific=1, isPairedEnd=TRUE, requireBothEndsMapped=FALSE, checkFragLength=FALSE, minFragLength=0,maxFragLength=600, countChimericFragments=TRUE, autosort=TRUE,verbose=FALSE)
write.table(x=data.frame(test$annotation[,c("GeneID","Chr","Start","End","Strand","Length")],test$counts,stringsAsFactors=FALSE),file="/home/test-counts.txt", quote=FALSE, sep="\t", row.names = FALSE)

 

The results are like this:

 

For the "Chr", "Start","End","Strand" annotation there are serveral values for each gene. Are they the location of  different exons of the same gene?

How can I get the location of the gene(for each geneid there is only one value in the "Chr", "Start","End","Strand") not the exons?

Thank you for your help!

 

 

 

rnaseq annotation featurecounts • 2.8k views
ADD COMMENT
3
Entering edit mode
Wei Shi ★ 3.6k
@wei-shi-2183
Last seen 8 hours ago
Australia/Melbourne

Yes the annotations are for each exon, not for genes. You can work out the transcriptional start and end positions of genes by using the coordinates of exons belonging to the same gene and the strand information.

An easier way might be to use the getInBuiltAnnotation function in Rsubread. This function returns a data frame in which each row is an exon and columns are annotation data.

ADD COMMENT

Login before adding your answer.

Traffic: 953 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6