Your plot only shows part of the tree provided by print(fit).
I would like to plot the entire tree.
Original Message
Subject: Re: [R] help with plot.rpart
From: Joshua Wiley <[1]jwiley.ps...@gmail.com>
Date: Fri, July 29, 2011 8:25 am
To
Mark,
The below is not directly reproducible. There is no "MV" or "PT"
variable in the dataset you reference. I am assuming you meant:
dat <- read.table("http://statcourse.com/research/boston.csv";, ,
sep=",", header = TRUE)
fit <- rpart(MEDV ~ CRIM + ZN + INDUS + CHAS + NOX + RM + AGE + DIS
Ah, now we're getting somewhere. Think how easy this would be if
you'd provided this information initially.
On Fri, Jul 29, 2011 at 11:11 AM, wrote:
> Ø data=read.table("http://statcourse.com/research/boston.csv";, , sep=",",
> header = TRUE)
> Ø library(rpart)
> Ø fit=rpart (MV~ CRIM+ZN+INDU
à data=read.table("http://statcourse.com/research/boston.csv";, , sep=",",
header = TRUE)
à library(rpart)
à fit=rpart (MV~ CRIM+ZN+INDUS+CHAS+NOX+RM+AGE+DIS+RAD+TAX+ PT+B+LSTAT)
Please: Show me the tree.
Mark
Original Message
Subject: Re: [R] help
4 matches
Mail list logo