[BioC] Concordance correlation coefficient and data manipulation
James W. MacDonald
jmacdon at med.umich.edu
Mon Mar 30 16:09:10 CEST 2009
Hi John,
How you remove things depends on what you want as your end result. If
you want to remove all reporters that have an NaN or Inf then you would
do something like this:
Assuming you have a data.frame or matrix called 'dat'
ind <- apply(dat, 1, function(x) any(is.nan(x)) || any(x == Inf))
dat <- dat[!ind,]
Will get rid of all rows with NaN or Inf in it.
Best,
Jim
John Herbert wrote:
> Hi All.
> I want to compare array expression data between arrays and samples of similar test conditions.
> My data contains NaN and inf values and I want to remove these so they are not included in the tests. How is best to do this?
> I am a Perl-er and new to R, there does not seem an easy way to do it with subset or grep.
>
> Any advice appreciated. I wrote my own concordance routine but there could be a good one in a package somewhere? I am using Agilent single colour data.
>
> Thanks a lot for any advice.
>
> John.
>
> _______________________________________________
> Bioconductor mailing list
> Bioconductor at stat.math.ethz.ch
> https://stat.ethz.ch/mailman/listinfo/bioconductor
> Search the archives: http://news.gmane.org/gmane.science.biology.informatics.conductor
--
James W. MacDonald, M.S.
Biostatistician
Douglas Lab
5912 Buhl
1241 E. Catherine St.
Ann Arbor MI 48109-5618
734-615-7826
More information about the Bioconductor
mailing list