Prof Brian Ripley wrote:
>
> On Sun, 12 Dec 2010, jagdeesh_mn wrote:
>
>> Hi,
>>
>> Suppose i have generated an object using the following :
>> fit <- rpart(Kyphosis ~ Age + Number + Start, data=kyphosis)
>>
>> And when i print fit, i get the fol
Hi,
Suppose i have generated an object using the following :
fit <- rpart(Kyphosis ~ Age + Number + Start, data=kyphosis)
And when i print fit, i get the following :
n= 81
node), split, n, loss, yval, (yprob)
* denotes terminal node
1) root 81 17 absent (0.7901235 0.2098765)
2)
Here is the complete dataset:
Outlook TempHumidityWindy Class
Sunny 2 2 Yes Play
Sunny 2 1 Yes Don't Play
Sunny 3 1 No Don't Play
Sunny 2 1 No Don't Play
Sunny 1 2 No Play
Overcast2
@Above,
Thanks. That certainly helps.
I understand that the rpart splits only in binary. Is there any support in R
to make the split have more than 2 nodes?
Cheers,
Jagdeesh
--
View this message in context:
http://r.789695.n4.nabble.com/Rpart-query-tp2991198p2991643.html
Sent from the R help m
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 TempHumidityWindy Class
Sunny 75 70 Yes Play
Sunny 80 90 Yes Don't Play
Sunny 85 85
5 matches
Mail list logo