Professional Documents
Culture Documents
bs report on iris
bs report on iris
No of Rows: 150
Names:
Number of columns: 5
Objectives:
Obj.1
Decision trees are constructed to know the influencing variables on Species
Obj.2
To use the decision tree model for prediction and classification.
Interpretation:
1.If the Petal. Length Is less than 2.5, the observation is classified as Setosa. This is the root node, and
it represents the initial decision point.
2. After the root node next decision depends on Petal width.
If Petal. Width is less than 1.8, the observation is classified as versicolor.
3. For observations where Petal. Width is greater than or equal to 1.8, it predicts virginica.
This tree clearly separates Setosa from the other two species based on Petal. Length. For flowers with
longer petals (>= 2.5), it further distinguishes between Versicolor and Virginica based on Petal. Width.
Description of the rules:
Rules for Setosa
If Petal. Length is less than 2.5
Then species= Setosa
Confidence: 100%
Data Coverage is 33%
Rule for Versicolor
If Petal. Length greater than or equal to 2.5 and petal width is less than 1.8
Then species = Versicolor
Confidence:91%
Data Coverage IS 36%
Rule for Virginica
If Petal. Length greater than 2.5 and Petal. Width greater than 1.8
Then Species = Virginica
Confidence:98%
Data Coverage is 31%
Prediction:
True positives (TP): occur when the model accurately predicts a positive data point.
True negatives (TN): occur when the model accurately predicts a negative data point.
False positives (FP): occur when the model predicts a positive data point incorrectly.
False negatives (FN): occur when the model mispredicts a negative data point.
Package Caret is used for Confusion Matrix