search for: varimp

Displaying 20 results from an estimated 22 matches for "varimp".

2009 May 16
5
bagged importance estimates in earth problem
I was trying to produced bagged importance estimates of attributes in earth using the caret package with the following commands:   fit2 <- bagEarth(loyalty ~ ., data=model1, B = 10)   bagImpGCV <- varImp(fit2,value="gcv") My bootstrap estimates are produced however the second command "varImp" produces the following error:    Error in UseMethod("varImp") : no applicable method for "varImp" Not sure what is going on, any advice would be appreciated, Thanks,...
2011 Mar 07
2
use "caret" to rank predictors by random forest model
...s: rf.fit<-randomForest(x,y,ntree=500,importance=TRUE) ## "x" is matrix whose columns are predictors, "y" is a binary resonse vector ## Then I got the ranked predictors by ranking "rf1$importance[,"MeanDecreaseAccuracy"]" ## Then draw the importance plot varImpPlot(rf.fit) As you can see, all the functions I used are directly from the package "randomForest", instead of from "caret". so I'm wondering if the package "caret" has some functions who can do the above ranking and ploting. In fact, I tried functions "train...
2011 Oct 17
0
Party package: varimp(..., conditional=TRUE) error: term 1 would require 9e+12 columns (fwd)
...some of the others are environmental parameters > such > as water temperature. For this reason I would like to follow the advice > of > Strobl et al. (2008) and try the authors' conditional variable > importance > measure. This is implemented in the party package by calling varimp(..., > conditional=TRUE). Unfortunately, when I call that on my forest I > receive > the error: > >> varimp(myforest, conditional=TRUE) > Error in model.matrix.default(as.formula(f), data = blocks) : > term 1 would require 9e+12 columns > > Does anyone know what is w...
2011 Oct 14
1
Party package: varimp(..., conditional=TRUE) error: term 1 would require 9e+12 columns
...them is the day of the year and some of the others are environmental parameters such as water temperature. For this reason I would like to follow the advice of Strobl et al. (2008) and try the authors' conditional variable importance measure. This is implemented in the party package by calling varimp(..., conditional=TRUE). Unfortunately, when I call that on my forest I receive the error: > varimp(myforest, conditional=TRUE) Error in model.matrix.default(as.formula(f), data = blocks) : term 1 would require 9e+12 columns Does anyone know what is wrong? I noticed a post in June 2011 wher...
2008 Sep 25
0
varimp in party (or randomForest)
...", "loc"))] my_cforest_control <- cforest_control(teststat = "quad", testtype = "Univ", mincriterion = 0, ntree = 50, mtry = 3, replace = TRUE) my_cforest <- cforest(edit ~ ., data = arabidopsis, controls = my_cforest_control) varimp_cforest <- varimp(my_cforest) By the way, the same issue arises for the randomForest package. Does anyone have any suggestions? I'm more interested in the variable importance than the tree per se. Thanks, Jason Jason Jones, PhD Medical Informatics j.jones at imail.org 801.707.6898
2012 Apr 29
1
CForest Error Logical Subscript Too Long
...ND <- factor(OLDDATA$ND, label=c("Yes", "No"))? attach(OLDDATA) defaults <- cbind(YD, ND) set.seed(47) data.controls <- cforest_unbiased(ntree=500, mtry=3) data.cforest <- cforest(defaults~LN+LV+LT+RV+MR+TL+DIA+CB, data = OLDDATA, controls=data.controls) data.cforest.varimp <- varimp(data.cforest, conditional = TRUE) barplot(sort(data.cforest.varimp)) And this is the error I get: > data.cforest <- cforest(defaults~LN+LV+LT+RV+MR+TL+DIA+CB, data = OLDDATA, controls=data.controls) Error in xt[[j]][nas, drop = FALSE] <- 0 :? ? (subscript) logical subscrip...
2008 Apr 04
1
random forest varimp
Friends, I have noticed that many publications that use RF report variable importance as a function of mean decrease in accuracy rather than mean decrease in gini. Am I correct that the mean decrease in accuracy is just the mean decrease in gini divided by 100? Thanks, Helen Mills Poulos Yale School of Forestry
2012 Oct 11
0
Error with cForest
...ed(ntree=500, mtry=5) > > for (i in 1:4){ ## Climate subset + occupied <- subset(Dynamic, WDOccupancy == 1 & Climate == i, select = c(DataSet:DGI)) + Dynamic.cf <- cforest(Fan ~ FormH + FormV + Uratio + Void + Transmis, data = occupied, control = ctrl) + print(Dynamic.cf) + ## round(varimp(Dynamic.cf), 4) + ## Standard importance values __________________________ + imp=varimp(Dynamic.cf, conditional = TRUE) #use varimp defaults + ## plot(imp) + print(imp) + + ## predict variables _________________________________________ + predicted=predict(Dynamic.cf,OOB = TRUE) + print(occupied$Fan...
2005 Jan 27
0
how to evaluate the significance of attributes in tree gr owing
FWIW, I wrote a little function to extract variable importance as defined in the CART book a while ago. It's rather limited: Only works for regression problem, and you need to set maxsurrogate=0 and maxcompete=0. It may (or may not) help you: varimp.rpart <- function(x) { dev <- x$frame[, c("var", "dev")] dev <- dev[dev$var != "<leaf>", ] improve <- x$split[, "improve"] imp <- tapply(dev[, 2] * improve, dev$var, sum)[-1] if (any(is.na(imp))) imp[is.na(imp...
2009 Feb 06
0
party package conditional variable importance
Hello, I'm trying to use the party package function varimp() to get conditional variable importance measures, as I'm aware that some of my variables are correlated. However I keep getting error messages (such as the example below). I get similar errors with three separate datasets that I'm using. At a guess it might be something to do with the v...
2011 Jun 16
1
Fwd: varimp_in_party_package
> > Hello everyone, > > I use the following command lines to get important variable from training > dataset. > > > data.controls <- cforest_unbiased(ntree=500, mtry=3) > data.cforest <- cforest(V1~.,data=rawinput,controls=data.controls) > data.cforest.varimp <- varimp(data.cforest, conditional = TRUE) > > I got error: "Error in model.matrix.default(as.formula(f),data = blocks): > term 1 would require 4e+17 columns" > there is a factor with (too) many levels in your data frame `rawinput'. summary(rawinput) will tell you...
2012 Dec 11
2
VarimpAUC in Party Package
Greetings! I'm trying to use function varimpAUC in the party package (party_1.0-3 released September 26th of this year). Unfortunately, I get the following error message: > data.cforest.varimp <- varimpAUC(data.cforest, conditional = TRUE) Error: could not find function "varimpAUC" Was this function NOT included in the Windo...
2013 Feb 14
1
party::cforest - predict?
...orest classifier. The method predict seems to be a method of the class RandomForest objects of which are returned by cforest. --------------------------- > cf.model = cforest(...) > methods(class=class(cf.model)) [1] predict.RandomForest* predictors.RandomForest* print.RandomForest* [4] varImp.RandomForest* weights.RandomForest* Non-visible functions are asterisked --------------------------- But I could not find the list of arguments that predict for cforest accepts. The link on the function "predict" in the vignette (wherever it is mentioned) just takes you to the f...
2012 Nov 22
1
Partial dependence plot in randomForest package (all flat responses)
...always get a plot with a straight line (a completely flat response). Similarly, If I set a categorical variable as predictor, I get a barplot with all the bar with the same height. I suppose I'm doing something wrong here because all other analysis on the same rforest object seem correct (e.g. varImp or MDSplot). Is it possible it is related to some option set in random forest object? Can somebody see the problem here? Thanks for your time -- View this message in context: http://r.789695.n4.nabble.com/Partial-dependence-plot-in-randomForest-package-all-flat-responses-tp4650470.html Sent from...
2010 Mar 23
1
caret package, how can I deal with RFE+SVM wrong message?
...> rf.RFE<-rfe(trx,try,sizes=subsets,rfeControl=rfectrl,method="rf",tuneGrid=rfGrid) Loading required package: class Attaching package: 'class' The following object(s) are masked from package:reshape : condense Fitting: mtry=1 Fitting: mtry=2 Error in varImp.randomForest(object$finalModel, ...) : subscript out of bounds In addition: Warning message: package 'e1071' was built under R version 2.10.1 At the same time, If I want to use RFE+SVM, RFE+nnet, and so on ,how can I do? I have try RFE+SVM, also wrong message:> set.seed(1) > s...
2012 Dec 06
0
Package party Error in model.matrix.default(as.formula(f), data = blocks) :allocMatrix: too many elements specified
...a commond error like others did from the past. > lu = read.csv(file=file.choose()) > lu.cf <- cforest(Target ~ ., data = lu, control = cforest_unbiased(mtry = 2, ntree = 50)) > lu.cf <- cforest(Target ~ ., data = lu, control = cforest_unbiased(mtry = 2, ntree = 100)) > cvi_lu = varimp(lu.cf,threshold = 0.2,conditional= TRUE,OOB=TRUE) Error in model.matrix.default(as.formula(f), data = blocks) : allocMatrix: too many elements specified Anybody please given suggestion? Thanks a lot! [[alternative HTML version deleted]]
2013 Jan 11
0
Error with looping through a list of strings as variables
...(k in c(1,0)){ for (i in c(1,2)){ ## Data subset filtered <- subset(hsb2, schtyp == i & female == k, select = c(id:socst)) rank.cf <- cforest(h ~ write + math + science + socst, data = filtered, control = ctrl) print(rank.cf) ## Standard importance values __________________________ imp=varimp(rank.cf, conditional = TRUE) print(imp) ## predict variables _________________________________________ predicted=predict(rank.cf,OOB = TRUE) residual=filtered$h-predicted mse=mean(residual^2) rsq=1-mse/var(filtered$h) ##Correlation between fitted values and original values: ____ correl <- pas...
2011 Jan 24
1
How to measure/rank “variable importance” when using rpart?
Hello all, When building a CART model (specifically classification tree) using rpart, it is sometimes interesting to know what is the importance of the various variables introduced to the model. Thus, my question is: *What common measures exists for ranking/measuring variable importance of participating variables in a CART model? And how can this be computed using R (for example, when using the
2007 Aug 24
0
Wine release 0.9.44
.../tests: Skip VarDiv tests if there is no I8 and/or UI8 support. opengl32/tests: Be a bit more verbose when doing wglGetProcAddress. mshtml/htmltextcont: Initialize value (Coverity). oleaut32/tests: Skip VarIdiv tests if there is no I8 and/or UI8 support. oleaut32/tests: Skip VarImp tests if there is no I8 and/or UI8 support. oleaut32/tests: Skip VarCat and VarAnd tests a bit better if there is no I8 and/or UI8 support. msvcrt/tests: Wait for spawned processes to finish. ntdll/tests: Do GetModuleHandle only once and add a few skip's. ntdll/tests: Us...
2007 Nov 09
0
Wine release 0.9.49
...of non-empty string. Alexander Nicolaysen S?rnes (2): mscat32: Add stub dll. shell32: Update Norwegian Bokm?l translation. Alexandre Julliard (45): winealsa.drv: Avoid the alsa alloca macros that cause compiler warnings. oleaut32: Properly initialize the result variant in VarImp. mscat32: Forward calls to wintrust where possible. server: Remove failed ioctls from the queue as soon as the result is set. pdh: Fix a couple of race conditions in the thread handling. user32: Fix a slightly incorrect assert. server: Add the generated files missing f...