[BioC] spot-types color assignment in limma
J.delasHeras at ed.ac.uk
J.delasHeras at ed.ac.uk
Mon Feb 11 14:25:55 CET 2008
Quoting Dana Sevak <dana.sevak at yahoo.com>:
> Dear BioC mailing list members,
>
> I am using limma to generate MA-plots for Agilent arrays. In these
> plots I would like to highlight the positive controls in red and the
> negative controls in blue. To do this, in accordance with the
> limma User's guide, I am following these steps:
>
> # reading the arrays in limma (from two files specified in targets.txt)
>> datadir = ("...")
>> targets <- readTargets("targets.txt", sep="\t", quote="\"")
>> RG <- read.maimages(targets$FileName, source="agilent",
>> path=datadir, names=targets$Sample, columns= list(R =
>> "rMeanSignal", G ="gMeanSignal", Rb = "rBGUsed", Gb = "gBGUsed",
>> Rb.real = "rBGMeanSignal", Gb.real = "gBGMeanSignal"), annotation =
>> c("FeatureNum","Row","Col","ProbeName","ControlType","GeneName"))
>
> The files are read (with an warning message)
> Warning message:
> In read.maimages(targets$FileName, source = "agilent", path = datadir, :
> non-standard columns specified
>
> Please note the presence of the fields ProbeName and ControlType in
> "annotation". ControlType has three types of values: 0 for probes,
> -1 for negative controls and 1 for positive controls.
>
> # reading a tab-delimited STF file (named SpotTypes.txt) of the form
> SpotType ControlType ProbeName Color
> probe 0 * yellow
> neg -1 * blue
> pos 1 * red
>
> I am setting the color to yellow for probes in order to test if the
> color assignment is performed in the following steps:
>
>> setwd = (datadir)
>> spottypes = readSpotTypes()
>> RG$genes$ControlType = controlStatus(spottypes, RG)
> Matching patterns for: ControlType ProbeName
> Found xxx probe
> Found yyy neg
> Found zzz pos
> Setting attributes: values Color
>> plotMA(RG[,1])
>
> However, in the resulting MA-plot all points are black suggesting
> that the color assignment did not take place properly. I checked
> the data structures and the commands and they seem to be correct.
>
> I do not understand why this does not work and I would very much
> appreciate your help in solving the issue.
>
> SessionInfo() is:
> R version 2.6.1 (2007-11-26)
> i386-pc-mingw32
> locale:
> LC_COLLATE=English_United States.1252;LC_CTYPE=English_United
> States.1252;LC_MONETARY=English_United
> States.1252;LC_NUMERIC=C;LC_TIME=English_United States.1252
> attached base packages:
> [1] stats graphics grDevices utils datasets methods base
> other attached packages:
> [1] limma_2.12.0
>
>
> Thank you very much,
> Dana
Hi Dana,
I use limma but I don't like the spot-types approach to highlight
genes on MA plots. What I do is do MA plots with the 'plot' function,
and then add coloured points with the 'points' function. As long as
you have a way to define a vector with the index of the interesting
spots, that's all you need. Then use 'legend' to add a legend as
required.
I find this to be a simpler approach, which I prefer.
Jose
--
Dr. Jose I. de las Heras Email: J.delasHeras at ed.ac.uk
The Wellcome Trust Centre for Cell Biology Phone: +44 (0)131 6513374
Institute for Cell & Molecular Biology Fax: +44 (0)131 6507360
Swann Building, Mayfield Road
University of Edinburgh
Edinburgh EH9 3JR
UK
--
The University of Edinburgh is a charitable body, registered in
Scotland, with registration number SC005336.
More information about the Bioconductor
mailing list