Displaying 20 results from an estimated 2000 matches similar to: "random forest problem when calculating variable importance"
2004 Oct 14
0
random forest problem when calculating variable importanc e
Are the results dramatically different?
The result would be expected to be somewhat different, as setting
importance=TRUE would make many calls to the random number generator (for
permuting OOB data in each variable), making all but the first tree in the
forest different than if importance=FALSE.
Cheers,
Andy
> From: Scott Gilpin
>
> Hi -
>
> When using the randomForest
2008 Jun 15
1
randomForest, 'No forest component...' error while calling Predict()
Dear R-users,
While making a prediction using the randomForest function (package
randomForest) I'm getting the following error message:
"Error in predict.randomForest(model, newdata = CV) : No forest component
in the object"
Here's my complete code. For reproducing this task, please find my 2 data
sets attached ( http://www.nabble.com/file/p17855119/data.rar data.rar ).
2012 Dec 03
2
Different results from random.Forest with test option and using predict function
Hello R Gurus,
I am perplexed by the different results I obtained when I ran code like
this:
set.seed(100)
test1<-randomForest(BinaryY~., data=Xvars, trees=51, mtry=5, seed=200)
predict(test1, newdata=cbind(NewBinaryY, NewXs), type="response")
and this code:
set.seed(100)
test2<-randomForest(BinaryY~., data=Xvars, trees=51, mtry=5, seed=200,
xtest=NewXs, ytest=NewBinarY)
The
2012 Mar 08
2
Regarding randomForest regression
Sir,
This query is related to randomForest regression using R.
I have a dataset called qsar.arff which I use as my training set and
then I run the following function -
rf=randomForest(x=train,y=trainy,xtest=train,ytest=trainy,ntree=500)
where train is a matrix of predictors without the column to be
predicted(the target column), trainy is the target column.I feed the same
data
2004 Jan 20
1
random forest question
Hi,
here are three results of random forest (version 4.0-1).
The results seem to be more or less the same which is strange because I
changed the classwt.
I hoped that for example classwt=c(0.45,0.1,0.45) would result in fewer
cases classified as class 2. Did I understand something wrong?
Christian
x1rf <- randomForest(x=as.data.frame(mfilters[cvtrain,]),
2010 Aug 16
0
Help for using nnet in R for NN training and testing
Hello,
I want to use nnet package in R, to train and simulate a NN and get the
value of MSE.
I am reading in a file which has 19 input variables and one output variable
and has a total of 2000 observations. The first column in the file is a
column just for giving the serial numbers of the observations.
I have already read in the file and also extracted the different values into
the matrices to
2012 Oct 22
1
random forest
Hi all,
Can some one tell me the difference between the following two formulas?
1. epiG.rf <-randomForest(gamma~.,data=data, na.action = na.fail,ntree =
300,xtest = NULL, ytest = NULL,replace = T, proximity =F)
2.epiG.rf <-randomForest(gamma~.,data=data, na.action = na.fail,ntree =
300,xtest = NULL, ytest = NULL,replace = T, proximity =F)
[[alternative HTML version deleted]]
2005 Oct 11
1
a problem in random forest
Hi, there:
I spent some time on this but I think I really cannot figure it out, maybe I
missed something here:
my data looks like this:
> dim(trn3)
[1] 7361 209
> dim(val3)
[1] 7427 209
> mg.rf2<-randomForest(x=trn3[,1:208], y=trn3[,209], data=trn3, xtest=val3[,
1:208], ytest=val3[,209], importance=T)
my test data has 7427 observations but after prediction,
> dim(mg.rf2$votes)
2004 Oct 25
1
Ref: Variable scope or function behaviour or array reassign
Dear R- helpers
Following a draft structure of the R script for which I am facing problem
Step 1
x <- of type array with original values
y <- of type array with original values
Step 2
for (ctr in 1:10) {
# my problem here the both x and y still show the original values from step 1
# in spite of making changes to the old values of the arrays x and y in the function
function
2002 Oct 04
1
items in Rd file
Dear R-devel,
I'm encountering a strange problem in a Rd file that I'm working on. In the
"Value" section, I have something like:
=====================
\value{
An object of class \code{randomForest}, which is a list with the
following components:
\item{call}{the original call to \code{randomForest}}
...
For classification problem, the following are also included:
2003 Aug 01
1
shading in image()
Is there a way to make a shading interpolation on an image plot?
Something similar to matlab 'shading interp', I think it is called Gouraud
shading.
What I want is to make a image plot look nicer. with image() it looks very
facetted, and I would like to make it look smoother.
I've tried with interp.surface() in fields package but it (obviously) makes
nan values at the borders and
2010 Jan 07
0
setting different environments
Hallo,
I have a set of S4 and S3 classes together in one script.
While running this script I create a lot of new functions and objects
An example for S3 and S4 classes:
## S3 classes
pt <- list(x=1,y=2)
class(pt) <- "xypoint"
xpos <- function(x, ...) UseMethod("xpos")
xpos.xypoint <- function(x) x$x
ypos <- function(x, ...) UseMethod("ypos")
2009 Apr 04
1
error in trmesh (alphahull package)
Hello R community,
I have cross-posted with r-sig-geo as this issue could fall under either
interest group I believe.
I just came accross the alphahull package and am very pleased I may not
need to use CGAL anymore for this purpose. However, I am having a
problem computing alpha shapes with my point data, and it seems to have
to do with the spatial configuration of my points (which form
2006 Apr 17
0
autoscall the y-axis
Dear R users
I need to auto scale the left y axis in the code below, so that when
I scroll left or right the left y-axis scale changes to accumulate the
range of the displayed data with in the max hight of the y-axis.
also how can I make the crosshair horizontal since it is only
vertical in this code. this code with a kind help from
"Gregory (Greg) L. Snow Ph.D."
just
2008 Jul 25
0
Error in vector("double", length)
Please see the code below.
When I try to run the variogram - vg.deft<-variog(rd,uvec=10)
I keep getting this error-
variog: computing omnidirectional variogram
Error in vector("double", length) : vector size specified is too large
Also, when I try to define distance-based neighborhood -
nb.tr=dist.neighbors(tr.locs,2)
I get this error -
Error in vector("double", length) :
2009 Dec 10
2
different randomForest performance for same data
Hello,
I came across a problem when building a randomForest model. Maybe someone can help me.
I have a training- and a testdataset with a discrete response and ten predictors (numeric and factor variables). The two datasets are similar in terms of number of predictor, name of variables and datatype of variables (factor, numeric) except that only one predictor has got 20 levels in the training
2006 Jul 29
1
fancier plotting
Hi
thank you for talking the time to help me with this.
I have a sequence of numbers in a file and an equal sequence of various character, say(a b c d) each occurs more than once. I need to plot the numbers so that numbers corresponding to a in the other sequence would have green dots, those corresponding to b a red dot, nothing on c and blue square for d. i.e
2 a show a green dot
4 b show a
2004 Oct 11
0
scoping problem when calling step inside a function
Hi everyone -
I'm trying to do a forward stepwise regression (I've tried both step
and stepAIC) inside of a function. I can do it outside the function
with no problems (first example in code below). I can also do a
backward stepwise regression inside a function (second example), but
forward stepwise regression ( third example ) fails with the error:
"Error in
2010 Aug 13
2
Unable to retrieve residual sum of squares from nls output
Colleagues,
I am using "nls" successfully (2.11.1, OS X) but I am having difficulties retrieving part of the output - residual sum of squares. I have assigned the output to FIT:
> > FIT
> Nonlinear regression model
> model: NEWY ~ PMESOR + PAMPLITUDE * cos(2 * pi * (NEWX - POFFSET)/PERIOD)
> data: parent.frame()
> PMESOR PAMPLITUDE POFFSET
>
2003 Dec 09
1
How to append to a data.frame?
Hi,
I have a data.frame that I need to construct iteratively.
At the moment, I'm doing:
d<-data.frame(x=c(),y=c(),z=());
# {and, within some loop}
d<-rbind(d,data.frame(x=newx,y=newy,z=newz);
While this works, it is horribly verbose and probably not efficient, either.
My real data.frame has, of course, many more columns, which can be of
different modes.
I vaguely recall that