similar to: rpart puzzle

Displaying 20 results from an estimated 7000 matches similar to: "rpart puzzle"

2001 Jul 25
1
Floating point "fuzz" and rpart?
I've been using rpart with R (1.3.0 Windows) for some time. I recently ran one of my research data sets through the rpart routine and produced a classification tree. I tried to replicate the results of the rpart analysis on another machine of mine and discovered some startling differences in the results. Puzzled, I went back to the raw data residing on both machines. I printed out
2001 Aug 12
2
rpart 3.1.0 bug?
I just updated rpart to the latest version (3.1.0). There are a number of changes between this and previous versions, and some of the code I've been using with earlier versions (e.g. 3.0.2) no longer work. Here is a simple illustration of a problem I'm having with xpred.rpart. iris.test.rpart<-rpart(iris$Species~., data=iris[,1:4], parms=list(prior=c(0.5,0.25, 0.25))) + ) >
2000 Mar 08
1
Coercing character to factor
I just downloaded version 1.0.0 and several binary libraries (VR, rpart, norm, stataread) - WinNT version. I then converted a file from Stata 6.0 to R format by using the stataread library. The file converts perfectly and I was able to use the VR function lda on the dataframe without difficulty. I then tried to use the same dataframe with RPART. The model statement:
2001 Sep 14
0
rpart or Postscript problem?
I've run into another postscript/rpart problem unrelated to the issues I've mentioned in a previous query. I'm using 1.3.1 on a Win2K box. >plotcp(some.rpart.object) draws a very nice plot on the windows graphic device. If I save this as a postscript file, either by opening a postscript device before calling plotcp, or by saving the graphics window as a postscript file, the
2001 Sep 13
3
OT: ps -> eps -> MS Word
I've created a bunch of postscript trees (post.rpart), which I subsequently edit in Adobe Acrobat 4.05 (I need additional labelling that isn't easy to add with R). After editing the labels and annotations using Acrobat, I then export the file to Adobe's .eps format so I can insert the picture into a Microsoft Word 2000 document. The .pdf file distilled from the .ps file is
2002 Jul 03
2
"Best" Out of box Linux distro for R
At the risk of starting a holy war, I'd like opinions on the "best" current Linux distribution to run "out of box" with current versions of R. I note rpms for various versions of RedHat, SUSE, Mandrake, and Debian. I've had experience with RH 7.1 & 7.2 and it hasn't been entirely pretty. I understand that 7.3 is a bit "better", but have also
2003 May 17
5
how to construct tree under R
Hello. I have a hudge problem, don't know how to deal with it... I'm supposed to implement a tree structure in R, without using rpart library... I don't have any clue about appropriate approach... Anyway, I can't use pointers under R...so how to to it? lists, vectors... Anyway, does anybody knows how the regression tree in rpart was implemented... Someone please help! Thanks, ana
2001 Oct 03
1
R != S-Plus
David Brahm's initial post seems to me to be filled with a mixture of bugs, wants, and needs coupled with a desire to "make" R become S-Plus. David, if S-Plus works for you, why are you bothering to convert all your code to R? No one has ever asserted that R==S (or S-Plus), and there is no reason to expect this equality to hold, ever. R is open source. If you want to change
2002 Jul 12
2
Crosstabs in R
Before I reinvent the wheel, I have need for a relatively straightforward crosstabulation (2 x n) function. I know that R has table(), ftable(), xtabs(), and summary(xtabs()), but none of these produce a fully "tricked" out cross-tabulation with marginal totals, expected cell frequencies, and an array of statistics about the contingency table. Is there a more complete (something
2000 May 02
1
Graph superimposition
I'm running a four-group, 15-variable discriminant analysis using the MASS function lda(). Discriminant functions 1 and 2 explain about 93% of the variance. I would like to plot the group scatters in a single scatterplot, identify each group's centroid, and encircle the group scatter with a 90% bivariate confidence ellipse. I can do this for each group on a separate plot, but I
2008 Jan 29
2
rpart error when constructing a classification tree
I am trying to make a decision tree using rpart. The function runs very quickly considering the size of the data (1742, 163). When I call the summary command I get this: > summary(bookings.cart) Call: rpart(formula = totalRev ~ ., data = bookings, method = "class") n=1741 (1 observation deleted due to missingness) CP nsplit rel error 1 0 0 1 Error in yval[, 1] :
2006 Sep 19
3
Problem with rpart
Not sure if anyone has posted on this problem ... I want to use rpart to build a binary tree on a relatively large dataset with ~1400 data points and 15 predictors. But I've noticed that rpart fails almost immediately in the call to C_s_to_rp, as that code returns nonsense. Looking at the code itself isn't terribly helpful, and there don't seem to be any hard limits coded anywhere.
2010 Oct 12
6
Rpart query
Hi, Being a novice this is my first usage of R. I am trying to use rpart for building a decision tree in R. And I have the following dataframe Outlook Temp Humidity Windy Class Sunny 75 70 Yes Play Sunny 80 90 Yes Don't Play Sunny 85 85 No Don't Play Sunny 72 95 No Don't Play Sunny 69 70 No Play Overcast 72 90 Yes Play Overcast 83 78 No Play Overcast 64 65 Yes Play Overcast 81 75
2011 Apr 08
4
Rpart decision tree
Dear useRs: I try to plot an rpart object but cannot get a nice tree structure plot. I am using plot.rpart and text.rpart (please see below) but the branches that connect the nodes overlap the text in the ellipses and rectangles. Is there a way to get a clean nice tree plot (as in the Rpart Mayo report)? I work under Windows and use R2.11.1 with rpart version 3.1-46. Thank you. Tudor ...
2000 Jun 25
1
renaming columns
I frequently get data sets with cryptically-named variables. The datasets are more useful to me with informative variable names. I know that I can rename variables using the following command: dimname(dataset[[2]][index.of.variable.to.be.renamed]<-new.variable.name If I want to do this inside a function (say something I call RenameCol) what is the best way to communicate the
2000 Aug 01
1
Testing for parallel slopes
I'm running a series of simple bivariate linear regressions on grouped data. I want to test the slopes to see if they are parallel. I normally use analysis of covariance to do so, looking at interaction between the covariate and the factor to make this determination. VR3 pp.149 - 154 has a very nice example of an ANOCOVA, ending with a discussion of this very operation. My question has
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
2010 Jun 06
1
I need help in analyzing
I'm sory for my weak english. I need to analyze this subject : x1 x2 x3 x4 x5 x6 x7 x8 x9 x10 y 0 0 1 0 0 1 0 0 1 0 czarne 1 1 0 0 0 0 1 0 0 0 rude 0 0 1 0 0 1 1 0 0 0 braz 0 0 1 0 1 0 1 0 0 0 blond 1 0 0 0 0 1 0 0 0 1 rude 1 1 0 0 0 0 0 0 0 1 blond 0 0 1 1 0 0 0 0 1 0 czarne 1 0 0 1 0 0 1 0 0 0 blond 0 0 1 0 0 1 1 0 0 0 blond 1 0 0 0 0 1 1 0 0 0 czarne 0 0 1 0 0 1 0 0 0 1 czarne 1 0 1 0 0 0
2001 Feb 26
1
Difference between S-Plus & R 1.2.1
Sorry for the uninformative subject. The following piece of code gives different output in S-Plus (2K & 6) vs R 1.2.1 (Win) apply(apehum[,6:15], 2, function(x) which(is.na(x))) S-Plus results: > apply(apehum[,6:15], 2, function(x) which(is.na(x))) $latsupri: numeric(0) $medepico: numeric(0) $pdhtcapi: numeric(0) $mlhtcapi: numeric(0) $aphttroc: [1] 151 152 $mlhttroc: numeric(0)
2001 Apr 02
2
Is it possible to...
I have a matrix (1000 x 224) that contains the output from the function boot.array. For each row, there are 224 columns that represent the case numbers of the selected individuals from a bootstrap. The cases are listed in selection order, not numerical order. I'd like to rearrange the cells so that every row has the column entries listed ascending numeric order. I've been able to