I've been trying to play catch-up on R-help since DSC2005. This one must
have slipped through...
This is what I'd do:
iris.sub - subset(iris, Species %in% c(setosa, virginica))
iris.sub$Species - factor(iris.sub$Species)
That last line drops the empty level in the factor. You can then run
Hi,
Since I've had no replies on my previous post about my
problem I am posting it again in the hope someone
notice it. The problem is that the randomForest
function doesn't take datasets which has instances
only containing a subset of all the classes. So the
dataset with instances that either
Look at ?[.factor:
finaldataset$Species - finaldataset$Species[,drop=TRUE]
solves this.
On Fri, 26 Aug 2005, Martin Lam wrote:
Hi,
Since I've had no replies on my previous post about my
problem I am posting it again in the hope someone
notice it. The problem is that the
Thank you for this and earlier help Mr. Ripley.
Martin
--- Prof Brian Ripley [EMAIL PROTECTED] wrote:
Look at ?[.factor:
finaldataset$Species -
finaldataset$Species[,drop=TRUE]
solves this.
On Fri, 26 Aug 2005, Martin Lam wrote:
Hi,
Since I've had no replies on my