distance to TSS upstream/downstream
1
0
Entering edit mode
d r ▴ 150
@d-r-5459
Last seen 6.2 years ago
Israel
Hello I want to calculate the distance between HumanMethylation450k probes and their nearest TSS using refseq hg19 genes, in such a way that if the probe is downstream from the TSS the distance will be assigned a positive value, and if the probe is upstream from the TSS, the distance will be assigned a negative value. The idea is that both strands will be considered. The distance is to be positive if the nearest TSS is either on the '+ strand and its coordinate is greater than the probe's, or of the nearest TSS is on the '-' strand and its coordinate is smaller than the probe's. likewise, the distance is to be negative if the nearest TSS is on the '+' strand and its coordinate is smaller than the probe's or on the '-' strand and its coordinate is grater then the probe's. It may be possible to do this with transcripts(), but unfortunately my dat is not on TranscriptDb <http: 127.0.0.1:37980="" help="" library="" genomicfeatures="" help="" transcriptdb=""> objects. Is there a way to this using the distanceToNearest method of GRanges? thanks Dolev Rahat [[alternative HTML version deleted]]
probe probe • 4.7k views
ADD COMMENT
0
Entering edit mode
@michael-lawrence-3846
Last seen 2.4 years ago
United States
distanceToNearest is going to return a distance, which is always going to be absolute. If you want to make things positive and negative, then you will need to call precede and follow and perform a similar calculation. As long as you have the TSSs in a GRanges, this should work fine. There is no need for a TranscriptDb. Michael On Tue, Aug 21, 2012 at 8:29 AM, d r <dolevrahat@gmail.com> wrote: > Hello > > I want to calculate the distance between HumanMethylation450k probes > and their nearest TSS using refseq hg19 genes, in such a way that if > the probe is downstream from the TSS the distance will be assigned a > positive value, and if the probe is upstream from the TSS, the > distance will be assigned a negative value. The idea is that both > strands will be considered. > > The distance is to be positive if the nearest TSS is either on the '+ > strand and its coordinate is greater than the probe's, or of the > nearest TSS is on the '-' strand and its coordinate is smaller than > the probe's. > > likewise, the distance is to be negative if the nearest TSS is on the > '+' strand and its coordinate is smaller than the probe's or on the > '-' strand and its coordinate is grater then the probe's. > > It may be possible to do this with transcripts(), but unfortunately my > dat is not on TranscriptDb > <http: 127.0.0.1:37980="" help="" library="" genomicfeatures="" help="" transcript="" db=""> > objects. > > Is there a way to this using the distanceToNearest method of GRanges? > > > > thanks > > Dolev Rahat > > [[alternative HTML version deleted]] > > _______________________________________________ > Bioconductor mailing list > Bioconductor@r-project.org > https://stat.ethz.ch/mailman/listinfo/bioconductor > Search the archives: > http://news.gmane.org/gmane.science.biology.informatics.conductor > [[alternative HTML version deleted]]
ADD COMMENT
0
Entering edit mode
Thank you Michael On Tue, Aug 21, 2012 at 9:41 PM, Michael Lawrence <lawrence.michael@gene.com> wrote: > distanceToNearest is going to return a distance, which is always going to > be absolute. If you want to make things positive and negative, then you > will need to call precede and follow and perform a similar calculation. As > long as you have the TSSs in a GRanges, this should work fine. There is no > need for a TranscriptDb. > > Michael > > On Tue, Aug 21, 2012 at 8:29 AM, d r <dolevrahat@gmail.com> wrote: > >> Hello >> >> I want to calculate the distance between HumanMethylation450k probes >> and their nearest TSS using refseq hg19 genes, in such a way that if >> the probe is downstream from the TSS the distance will be assigned a >> positive value, and if the probe is upstream from the TSS, the >> distance will be assigned a negative value. The idea is that both >> strands will be considered. >> >> The distance is to be positive if the nearest TSS is either on the '+ >> strand and its coordinate is greater than the probe's, or of the >> nearest TSS is on the '-' strand and its coordinate is smaller than >> the probe's. >> >> likewise, the distance is to be negative if the nearest TSS is on the >> '+' strand and its coordinate is smaller than the probe's or on the >> '-' strand and its coordinate is grater then the probe's. >> >> It may be possible to do this with transcripts(), but unfortunately my >> dat is not on TranscriptDb >> <http: 127.0.0.1:37980="" help="" library="" genomicfeatures="" help="" transcrip="" tdb=""> >> >> objects. >> >> Is there a way to this using the distanceToNearest method of GRanges? >> >> >> >> thanks >> >> Dolev Rahat >> >> [[alternative HTML version deleted]] >> >> _______________________________________________ >> Bioconductor mailing list >> Bioconductor@r-project.org >> https://stat.ethz.ch/mailman/listinfo/bioconductor >> Search the archives: >> http://news.gmane.org/gmane.science.biology.informatics.conductor >> > > [[alternative HTML version deleted]]
ADD REPLY

Login before adding your answer.

Traffic: 703 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