HW3 use randomForest

作者: jyyuch (jyyuch)   2006-03-14 00:20:36
Call:
randomForest(x = usps.train[, -1], y = as.factor(usps.train[,1]),
xtest = usps.test[, -1], ytest = as.factor(usps.test[,1]))
Type of random forest: classification
Number of trees: 500
No. of variables tried at each split: 16
OOB estimate of error rate: 2.99%
Confusion matrix:
1 2 3 4 5 6 7 8 9 10 class.error
1 1181 1 3 2 2 1 3 0 1 0 0.010887772
2 0 998 1 0 0 1 1 1 3 0 0.006965174
3 0 1 717 4 3 0 1 3 1 1 0.019151847
4 0 1 8 624 0 10 0 1 11 3 0.051671733
5 2 2 9 0 632 0 4 0 0 3 0.030674847
6 9 0 3 6 2 521 6 1 5 3 0.062949640
7 5 2 1 0 3 2 649 0 2 0 0.022590361
8 0 0 3 0 8 0 0 614 3 17 0.048062016
9 2 4 0 3 6 4 3 2 515 3 0.049815498
10 0 1 0 3 8 0 0 5 5 622 0.034161491
Test set error rate: 6.13%
Confusion matrix:
1 2 3 4 5 6 7 8 9 10 class.error
1 353 0 3 0 1 0 1 0 0 1 0.01671309
2 0 253 0 0 4 0 5 1 1 0 0.04166667
3 2 0 185 4 0 0 1 1 5 0 0.06565657
4 1 0 4 148 0 10 0 0 3 0 0.10843373
5 0 2 5 0 187 0 1 1 0 4 0.06500000
6 4 0 0 4 2 144 0 0 2 4 0.10000000
7 2 0 3 0 2 2 161 0 0 0 0.05294118
8 0 0 2 0 6 0 0 136 1 2 0.07482993
9 1 0 1 5 1 8 0 0 147 3 0.11445783
10 0 0 0 0 4 0 0 0 3 170 0.03954802

Links booklink

Contact Us: admin [ a t ] ucptt.com