I made a change for rtracklayer 1.9.2, so that this is possible:

track1 <- import("http://129.94.136.7/bw/Bre12p3_MBD2IP_1.bw", ranges =
"hg18")

This works, because BigWigSelection() now takes a genome identifier as its
'ranges' parameter. That will bring in the score column by default. Easier?

Michael

On Mon, May 10, 2010 at 8:12 PM, Michael Lawrence <michafla@gene.com> wrote:

> I mean GenomicSelection("hg18", colnames = "score")
>
>
> On Mon, May 10, 2010 at 8:08 PM, Michael Lawrence <michafla@gene.com>wrote:
>
>> Correction: GenomicRanges("hg18", colnames = "score")
>>
>>
>> On Mon, May 10, 2010 at 7:59 PM, Michael Lawrence <michafla@gene.com>wrote:
>>
>>> You need to tell it to read the scores in from the BigWig file, i.e.
>>> GenomicSelection("hg18", "score").
>>>
>>> Michael
>>>
>>>
>>>
>>> On Mon, May 10, 2010 at 7:48 PM, Dario Strbenac <
>>> D.Strbenac@garvan.org.au> wrote:
>>>
>>>> Ah, right. I did a bit of inversigating, and I think it doesn't seem to
>>>> like BigWigs. Here's my reproducible example :
>>>>
>>>> library(rtracklayer)
>>>> track1 <- import("http://129.94.136.7/bw/Bre12p3_MBD2IP_1.bw",
>>>> selection = GenomicSelection("hg18"))
>>>>
>>>> > track1@values$chr1
>>>> DataFrame with 2928039 rows and 0 columns
>>>>
>>>> I don't think there would be a problem with the .bw file being corrupted
>>>> or anything. We've seen it in UCSC browser before and it looks good.
>>>>
>>>> Thanks,
>>>>        Dario.
>>>>
>>>> ---- Original message ----
>>>> >Date: Mon, 10 May 2010 19:25:50 -0700
>>>> >From: Michael Lawrence <lawrence.michael@gene.com>
>>>> >Subject: Re: [BioC] rtracklayer GraphTrackLine
>>>> >To: D.Strbenac@garvan.org.au
>>>> >Cc: Michael Lawrence <lawrence.michael@gene.com>,
>>>> bioconductor@stat.math.ethz.ch
>>>> >
>>>> >   On Mon, May 10, 2010 at 7:12 PM, Dario Strbenac
>>>> >   <D.Strbenac@garvan.org.au> wrote:
>>>> >
>>>> >     Hello again,
>>>> >
>>>> >     I'm really close to having it all working now.
>>>> >     It's just that when I try to pass some parameters
>>>> >     to track() that you'd expect to be available, they
>>>> >     don't seem to.
>>>> >
>>>> >     e.g.
>>>> >
>>>> >     > track(session, "Bre12 P3", priority = 1,
>>>> >     viewLimits = c(0, 10), color =
>>>> >     as(col2rgb("green"), "integer")) <- track1
>>>> >
>>>> >     Error in .local(object, con, variant, color,
>>>> >     append, ...) :
>>>> >      unused argument(s) (viewLimits = c(0, 10))
>>>> >
>>>> >     Is this something that is still in development
>>>> >     perhaps ?
>>>> >
>>>> >   This is not a fully reproducible example, but my
>>>> >   guess is that your 'track1' does not have a numeric
>>>> >   "score" column. Thus, rtracklayer assumes you want
>>>> >   to upload it as a BED track rather than as a graph
>>>> >   track (either wig or bedGraph, depending on some
>>>> >   complex logic). In that case, the graph-specific
>>>> >   parameters are invalid.
>>>> >
>>>> >   You can check this by calling as(track1, "UCSCData)
>>>> >   and then checking the class of the 'trackLine' slot.
>>>> >   To force the use of wig/bedGraph, simply pass
>>>> >   format="wig" or format="bedGraph" to the track<-
>>>> >   function.
>>>> >
>>>> >   Michael
>>>> >
>>>> >
>>>> >     Thanks,
>>>> >           Dario
>>>>
>>>>
>>>> --------------------------------------
>>>> Dario Strbenac
>>>> Research Assistant
>>>> Cancer Epigenetics
>>>> Garvan Institute of Medical Research
>>>> Darlinghurst NSW 2010
>>>> Australia
>>>>
>>>
>>>
>>
>

	[[alternative HTML version deleted]]

