Opened 10 years ago

Closed 10 years ago

#2179 closed defect (duplicate)

r.li.shannon - r.li.pielou

Reported by: matmar Owned by: grass-dev@…
Priority: normal Milestone: 6.4.4
Component: Default Version: unspecified
Keywords: Cc:
CPU: Unspecified Platform: Unspecified

Description

Hi,

r.li.shannon (and consequently r.li.pielou) returns the wrong output when "Whole Maplayer / Select areas from the overlayed vector map" option is used to build the configuration file. I attached the example that I used to replicate the error (with r.li.shannon).

example.ascii Simulated Landcover map.

example_vect Polygon used to calculate the index.

conf r.li.setup configuration file built using "Selet areas from the overlayed vector map" option. (Wrong shannon index).

conf_whole_whole r.li.setup configuration file built using "Whole Maplayer / Whole Maplayer" option. (Correct Shannon index).

Formula to calculate the correct Shannon index for the example landscape (paste it in R):

-(((10/16)*log(10/16))+((2/16)*log(2/16))+((1/16)*log(1/16))+((3/16)*log(3/16)))

Change History (1)

comment:1 by matmar, 10 years ago

Resolution: duplicate
Status: newclosed

please see #2180

Note: See TracTickets for help on using tickets.