Hi, utr=threeUTRsByTranscript(txdb,use.names=FALSE)So,utr is GRangesList of length 33381 Then as u said,I did the following: txBygene <- transcriptsBy(txdb, "gene") geneID <- rep(names(txBygene), elementLengths(txBygene)) df <- data.frame(geneID=geneID, txID=values(unlist(txBygene))[["tx_id"]]) This gives me a dataframe with 40,780 rows with gene ID and txID from txBygene object. geneID txID40775 9994 1173140776 9994 1173040777 9997 3849140778 9997 3848940779 9997 3849640780 9997 38497 Since my utr object is of length 33,381 ,my counts length is same i.e 33,381So I am not able to map the counts to the above data frame which has transcript and gene IDs.
--- On Fri, 23/9/11, Valerie Obenchain <[email protected]> wrote: From: Valerie Obenchain <[email protected]> Subject: Re: [Bioc-sig-seq] Reads in 3'utr To: "rohan bareja" <[email protected]> Cc: [email protected] Date: Friday, 23 September, 2011, 10:50 PM Hi Rohan, You can relate the counts for 3UTR regions to gene IDs through the transcript IDs. txdb_file <- system.file("extdata", "UCSC_knownGene_sample.sqlite", package="GenomicFeatures") txdb <- loadFeatures(txdb_file) utr=threeUTRsByTranscript(txdb,use.names=FALSE) The transcript names can be matched to the gene ID's through, txBygene <- transcriptsBy(txdb, "gene") geneID <- rep(names(txBygene), elementLengths(txBygene)) df <- data.frame(geneID=geneID, txID=values(unlist(txBygene))[["tx_id"]]) Now you know what gene ID each tx count belongs to. You can split your counts by gene ID ... Valerie On 09/20/2011 12:13 PM, rohan bareja wrote: Hi everyone, I am doing NGS analysis using bam files.I have counted reads in 3'utr region using utr=threeUTRsByTranscript(txdb,use.names=FALSE) countsUTR <- countOverlaps(utr,reads) I have got the transcript level counts from this.How can I get the gene level counts??It might sound silly but Does anybody have an idea on what type of anaylses we can do from this countsUTR ? Thanks,Rohan [[alternative HTML version deleted]] _______________________________________________ Bioc-sig-sequencing mailing list [email protected] https://stat.ethz.ch/mailman/listinfo/bioc-sig-sequencing [[alternative HTML version deleted]]
_______________________________________________ Bioc-sig-sequencing mailing list [email protected] https://stat.ethz.ch/mailman/listinfo/bioc-sig-sequencing
