Calculating classification accuracy manually using rpart output

Hi all,

I was wondering would anyone be able to manually calculate the classification accuracy of a model from just the following rpart output.

  1. root 18 10 Grigolino (0.1666667 0.4444444 0.3888889)
    2) Sugar>=19.29943 2 0 Barolo (1.0000000 0.0000000 0.0000000) *
    3) Sugar< 19.29943 16 8 Grigolino (0.0625000 0.5000000 0.4375000)
  2. Phentanol>=25.76422 10 3 Grigolino (0.1000000 0.7000000 0.2000000)
    12) Phentanol< 35.72422 6 0 Grigolino (0.0000000 1.0000000 0.0000000) *
    13) Phentanol>=35.72422 4 2 Barbera (0.2500000 0.2500000 0.5000000)
    26) Zinc< 1.42099 1 0 Barolo (1.0000000 0.0000000 0.0000000) *
    27) Zinc>=1.42099 3 1 Barbera (0.0000000 0.3333333 0.6666667) *
    7) Phentanol< 25.76422 6 1 Barbera (0.0000000 0.1666667 0.8333333)
    14) Sugar>=16.56456 1 0 Grigolino (0.0000000 1.0000000 0.0000000) *
    15) Sugar< 16.56456 5 0 Barbera (0.0000000 0.0000000 1.0000000) *

It is a simple made up dataset with just 18 observations but I do not think there is a way to group the incorrectly classified observations?

Thanks in advance
Marco

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.