search for: xlost

Displaying 2 results from an estimated 2 matches for "xlost".

Did you mean: lost
2008 Jul 22
2
rpart$where and predict.rpart
Hello there. I have fitted a rpart model. > rpartModel <- rpart(y~., data=data.frame(y=y,x=x),method="class", ....) and can use rpart$where to find out the terminal nodes that each observations belongs. Now, I have a set of new data and used predict.rpart which seems to give only the predicted value with no information similar to rpart$where. May I know how
2008 Jul 31
1
predict rpart: new data has new level
...nd frame$yval at the node is the prediction. " Many thanks. > mod <- rpart(y~., data=data.frame(y=y,x=x), method="anova", + cp=0.05, minsplit=100, minbucket=50, maxdepth=5) > predictLost <- predict(mod, newdata=data.frame(y=yLost, x=xLost), type="vector") Error in model.frame.default(Terms, newdata, na.action = act, xlev = attr(object, : factor 'x.Incoterm' has new level(s) MTD ---- Chua Siang Li Consultant - Operations Research Acceval Pte Ltd Tel: 6297 8740 Email: siang.li.chua...