Michael,
thank you very much for the explanation!
I will definitely try the weighted coverage option.

Thanks again and all the best!

Ales Maver, MD
Institute of Medical Genetics, Department of Obstetrics and Gynaecology
UMC Ljubljana
Šlajmerjeva 3
SI-1000 Ljubljana
Slovenia
Tel/ fax +38615401137
GSM: +38631710721
E-mail: Ales.Maver@gmail.com <Ales.Maver@gmail.com>


2012/6/27 Michael Lawrence <lawrence.michael@gene.com>

>
>
> On Wed, Jun 27, 2012 at 11:39 AM, Aleš Maver <ales.maver@gmail.com> wrote:
>
>> Dear BioConductors!
>>
>> I have been using functions in GenomicRanges package to find overlaps
>> between multiple genomic tracks stored as GRanges objects. In the metadata
>> section of the GRanges object, I store the feature's score data and I have
>> been wondering if you can perform any operations with this data. For
>> example, I would like to perform a sliding window analysis, where score
>> values would be averaged for every window of a defined range? Is this
>> possible using GenomicRanges?
>> Even if I use the reduce function, the metadata gets lost from the
>> resulting object - is there any possibility to retain or operate on
>> metadata?
>>
>>
> The metadata is discarded, since the features may have been fundamentally
> altered by the reduce operation.
>
> As far as window-based computations, there is no easy way. If your data
> makes sense as a genome-length vector, with zeros between the features, you
> could use coverage(gr, weight = "score") to get the score as an RleList.
> Then use functions like runmean(). If zeros in the gaps do not make sense,
> you will need to somehow set them to NA to exclude them.
>
> Michael
>
>
>> Thank you for any input on this!
>>
>> I wish you all a good day,
>> Ales
>>
>> ******************
>> Ales Maver
>> Institute of Medical Genetics, Department of Obstetrics and Gynaecology
>> UMC Ljubljana
>> Šlajmerjeva 3
>> SI-1000 Ljubljana
>> Slovenia
>> Tel/ fax +38615401137
>> GSM: +38631710721
>> E-mail: Ales.Maver@gmail.com <Ales.Maver@gmail.com>
>>
>>        [[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]]

