Thanks for your email Markus. That's a necessary fix <br>to r.kappa - one that may not be immediately<br>obvious if the errors of omission and commission are more<br>evenly dispersed between classes. <br><br>Regarding the individual class errors, would it make sense to<br>
simplify or standardise the values: -999.0000; -nan and NA<br>that are each reported within the r.kappa output?<br><br>Regards,<br>Daniel.<br><br><div class="gmail_quote">On Fri, Apr 1, 2011 at 3:42 PM, Markus Metz <span dir="ltr"><<a href="mailto:markus.metz.giswork@googlemail.com">markus.metz.giswork@googlemail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;"><div class="im">On Fri, Apr 1, 2011 at 2:45 PM, daniel mcinerney<br>
<<a href="mailto:daniel.o.mcinerney@gmail.com">daniel.o.mcinerney@gmail.com</a>> wrote:<br>
> Hi list,<br>
><br>
> I have a query regarding the error matrix produced<br>
> using r.kappa (in GRASS 6.4.0 RC6) and hoping that<br>
> the following will help someone to replicate my findings.<br>
> From what I see, the error matrix is mis-labeling the<br>
> rows/columns in the matrix.<br>
><br>
</div>Right, I noticed that some months ago, but fixed it only in grass 7.<br>
Now also fixed in 6.5 and 6.4 (r45818 and r45819, respectively).<br>
<br>
Markus M<br>
<div><div></div><div class="h5"><br>
> Using the spearfish dataset, I digitised 18 points<br>
> to create a reference dataset to validate<br>
> the classification, in this case the raster 'landcover.orig'<br>
> For the purposes of the test and simplicity, I ensured<br>
> that the points were located within two landcover classes<br>
> (raster values 42 and 81). The following steps were carried out<br>
> to generate the output from r.kappa<br>
><br>
><br>
> #Create reference dataset<br>
> d.where | r.what input=landcover.orig > kappa_test.txt<br>
><br>
> For the purposes of this test, I deliberately changed the<br>
> landcover class from 42 to 32 in the validation dataset [1]<br>
> This will create an off-diagonal value in the error matrix.<br>
><br>
> #Create the vector point from ascii and convert to raster<br>
> v.in.ascii input=kappa_test output=kapp_test cat=4<br>
> v.to.rast input=kapp_test output=validation use=cat<br>
><br>
> #Run r.kappa<br>
> r.kappa classification=landcover.orig reference=validation<br>
> output=validation.txt<br>
><br>
> The output from r.kappa (validation.txt) is below, however, it appears<br>
> to me that the matrix is transposed, i.e. the horizontal values<br>
> (MAP1) should in fact be vertical. From my interpretation, the error<br>
> matrix indicates that 8 validation points with the value 42 were<br>
> classified as 32, but in fact it should state that 8 points with<br>
> the value of 32 were classified as 42? Can anyone confirm<br>
> my findings?<br>
><br>
> Thanks in advance.<br>
><br>
> Regards,<br>
> Daniel.<br>
><br>
><br>
> ACCURACY ASSESSMENT<br>
> LOCATION: spearfish60 Fri Apr 1 12:45:42 2011<br>
> MASK: none<br>
> MAPS: MAP1 = Categories (validation in user1)<br>
> MAP2 = (untitled) (landcover.orig in PERMANENT)<br>
><br>
> Error Matrix<br>
> Panel #1 of 1<br>
> MAP1<br>
> cat# 32 42 81 Row Sum<br>
> M 32 0 8 0 8<br>
> A 42 0 0 0 0<br>
> P 81 0 0 10 10<br>
> Col Sum 0 8 10 18<br>
><br>
><br>
> Cats % Commission % Ommission Estimated Kappa<br>
> 32 100.000000 -nan -999.000000<br>
> 42 NA NA NA<br>
> 81 0.000000 0.000000 1.000000<br>
><br>
> Kappa Kappa Variance<br>
> 0.357143 0.002343<br>
><br>
> Obs Correct Total Obs % Observed Correct<br>
> 10 18 55.555556<br>
><br>
><br>
><br>
> [1]<br>
> #validation input<br>
> 590188.6875|4919453.8125||32<br>
> 590188.6875|4918947||32<br>
> 590307.9375|4918350.75||32<br>
> 590576.25|4917694.875||32<br>
> 590307.9375|4917694.875||32<br>
> 590546.4375|4919364.375||32<br>
> 590874.375|4919364.375||32<br>
> 590904.1875|4919483.625||32<br>
> <a href="tel:603604.3125">603604.3125</a>|4922047.5||81<br>
> 603336|4922315.8125||81<br>
> 603514.875|4922464.875||81<br>
> <a href="tel:603604.3125">603604.3125</a>|4922256.1875||81<br>
> 603634.125|4922107.125||81<br>
> 603693.75|4921987.875||81<br>
> <a href="tel:603962.0625">603962.0625</a>|4921987.875||81<br>
> 603753.375|4921600.3125||81<br>
> <a href="tel:603962.0625">603962.0625</a>|4922047.5||81<br>
> 598983.375|4922256.1875||81<br>
><br>
><br>
><br>
><br>
</div></div>> _______________________________________________<br>
> grass-user mailing list<br>
> <a href="mailto:grass-user@lists.osgeo.org">grass-user@lists.osgeo.org</a><br>
> <a href="http://lists.osgeo.org/mailman/listinfo/grass-user" target="_blank">http://lists.osgeo.org/mailman/listinfo/grass-user</a><br>
><br>
><br>
</blockquote></div><br>