[BioC] Possible to set alternative colnames on read.flowSet (flowCore)
Aric Gregson
a.gregson at ucla.edu
Sat Mar 7 02:02:56 CET 2009
Florian,
On Fri, 06 Mar 2009 16:50:49 -0800
Florian Hahne <fhahne at fhcrc.org> wrote:
> One way of getting the keywords out is this (assuming that foo is
> your flowSet):
> keyword(foo[[1]], function(x) keyword(x, grep("\\$P[0-9]*S",
> names(description(x)), value=TRUE)))
>
> Or, even simpler
> colnames(foo) <- pData(parameters(foo[[1]]))$desc
>
> If you think that this is an important enough use case I can add an
> option to read.FCS that allows to chose a PnS to be used as
> colnames, however this might introduce more trouble than it is worth
> since only PnN is guaranteed to be unique for each channel, and is
> has to be in order to work as a colname.
I think that you are correct in that it will lead to more problems than
it is worth. I'm sorry, but I had no idea the parameter of interest was
called $desc! That takes care of the problem right away!
BTW, using Data(wf[["view"]]) in plots works exactly as expected. It is
just the wf[["view"]] alone that is odd. Now that I realize that Data()
is necessary, it is just great. This is not really documented in the
newer flowCore section discussing use of wf views for plotting.
Thanks!
Aric
--
Aric Gregson <a.gregson at ucla.edu>
More information about the Bioconductor
mailing list