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/TranscriptDb>
>>
>> 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]]

