PrInDTregAll {PrInDT} | R Documentation |
Regression tree based on all observations
Description
Regression tree based on the full sample; interpretability is checked (see 'ctestv').
The relationship between the target variable 'regname' and all other factor and numerical variables
in the data frame 'datain' is modeled based on all observations.
Usage
PrInDTregAll(datain, regname, ctestv=NA, conf.level=0.95)
Arguments
datain |
Input data frame with class factor variable 'classname' and the |
regname |
name of regressand variable (character) |
ctestv |
Vector of character strings of forbidden split results; |
conf.level |
(1 - significance level) in function |
Details
Standard output can be produced by means of print(name)
or just name
as well as plot(name)
where 'name' is the output data
frame of the function.
Value
- treeall
tree based on all observations
- R2All
goodness of fit of 'treeall' based on all observations
- interpAll
criterion of interpretability of 'treeall' (TRUE / FALSE)
Examples
data <- PrInDT::data_vowel
data <- na.omit(data)
ctestv <- 'vowel_maximum_pitch <= 320'
outreg <- PrInDTregAll(data,"target",ctestv)
outreg
plot(outreg)