Altair slc simple random forest classification example using iris dataset
PROBLEM
Identify the species of iris flowers given Sepal_Length, Sepal_Width, Petal_Length, and Petal_Width.
Too long to post here see github
https://github.com/rogerjdeangelis/altair-slc-r-simple-random-forest-classification-example-using-iris-dataset
This is just a template; the iris dataset is too small with 4 fact variables to yield an improvement
over a single tree CART software.
Be skeptical of this post. Github is a software development site where
issues are welcome.
CONTENTS
i OVERVIEW SIMPLE PROGRAM
1 Inputs
a training
d:/wpswrkx/iris20260101_train.sas7bdat
b holdout (validation)
d:/wpswrkx/iris20260101_holdout.sas7bdat
2 confusion datasets and predictions
a Training
d:/wpswrkx/train_cm.sas7bdat
b Holdout
d:/wpswrkx/holdout_cm.sas7bdat
c Training and Holdout
d:/wpswrkx/combined_cm.sas7bdat
d combined model predictions
d:/wpswrkx/combined_pred.sas7bdat
3 combinrd model saved to r file
d:/rds/iris_rf_model.rds
4 Apply classifier to next weeks data
a next week inputs
d:/wpswrkx/iris20260105.sas7bdat
d:/rds/iris_rf_model.rds
b next week pedictions
d:/wpswrkx/iris20260105_pred.sas7bdat
c species frequency of next week data
ii SIMPLIFIED PROCESS FOR OVERVIEW
1 inputs
2 model build verfify and save
3 build output
iii THEORY AND DIAGMOSTICS
1 comments
2 inputs
3 gridplot of histogrames and scatterplots
d:/pdf/gridplot.pdf
4 multi-dimensional scaling plot
d:/pdf/mds.pdf
vey useful for undestanding the trees
5 randomforest process
d:/txt/rf_gini.txt
d:/txt/training.txt
d:/txt/rf_classifier_train.txt
d:/txt/gettree.txt
d:/txt/rcasewhen.txt
d:/txt/rcasewhen.txt
d:/pdf/rocr_holdout.pdf
d:/pdf/gini_training.pdf
d:/pdf/errorbytree_training.pdf
6 apply saved model
input: d;/wpswrk/iris20260105.sas7bdat
output: d;/wpswrk/iris20260105_pred.sas7bdat
d;/wpswrk/iris20260105_species_freq
7 freq next week
8 calc confusion by hand
9 roc auc analysis
d:/pdf/rocr_holdout.pdf
10 out of bag error
d:/pdf/errorbytree_training.pdf
11 gini
d:/pdf/gini_training.pdf
12 1st tree case/when
d:/txt/rcasewhen.sas
13 execute case/when
d;/wpswrk/iris_from_tree.sas7bdat
14 1st tree confusion
15 randomforest objects
16 sample tree