CT = read.csv(header = TRUE,"CT.csv")
model = C5.0(CT[1:14,-5],CT[1:14,5])
print(summary(model))
##
## Call:
## C5.0.default(x = CT[1:14, -5], y = CT[1:14, 5])
##
##
## C5.0 [Release 2.07 GPL Edition] Fri Jul 26 15:35:52 2019
## -------------------------------
##
## Class specified by attribute `outcome'
##
## Read 14 cases (5 attributes) from undefined.data
##
## Decision tree:
##
## Age = 31-40: yes (4)
## Age = <=30:
## :...Student = no: no (3)
## : Student = yes: yes (2)
## Age = >40:
## :...Credit_rating = excellent: no (2)
## Credit_rating = fair: yes (3)
##
##
## Evaluation on training data (14 cases):
##
## Decision Tree
## ----------------
## Size Errors
##
## 5 0( 0.0%) <<
##
##
## (a) (b) <-classified as
## ---- ----
## 5 (a): class no
## 9 (b): class yes
##
##
## Attribute usage:
##
## 100.00% Age
## 35.71% Student
## 35.71% Credit_rating
##
##
## Time: 0.0 secs
plot(model)
