Hi,
Take a matrix with missing values:
> X = matrix(rnorm(10), ncol = 5)
> X[2,4]=NA
> X
[,1] [,2] [,3] [,4] [,5]
[1,] -0.1566427 -0.7382232 -1.0564624 -0.8412139 0.9370319
[2,] -1.0289865 -0.8452054 -0.1349459 NA -0.1749113
I want to apply a custom fu
Behalf Of Jeffrey Spies
Sent: Friday, October 01, 2010 10:13 AM
To: Ochsner, Scott A
Cc: r-help@r-project.org
Subject: Re: [R] Need to incorporate the use of na.rm into custom function
You can use na.omit on x after it is passed into your apply function if na.rm
== T, or simply pass your na.rm to
John,
First, why are you trying to cluster so many rows? Presumably, if this is a
gene expression array dataset, most of the array features are not going to
change across treatments/conditions and will be relatively uninformative. Try
using a filter which does not use treatment/condition info
3 matches
Mail list logo