Greetings
I'm planning on using r.resamp.stats in order to resample a grid to a coarser resolution. Since I'm using this function with classes I will use mode method (more frequentclass to fall into a destination cell is the chosen). My question is: when I have a tie between two classes, how does GRASS decides which class shall be chosen?
Thanks
Antonio
__________ Information from ESET NOD32 Antivirus, version of virus signature database 5906 (20110225) __________
The message was checked by ESET NOD32 Antivirus.
http://www.eset.com
António Rocha wrote:
I'm planning on using r.resamp.stats in order to resample a grid to a
coarser resolution. Since I'm using this function with classes I will
use mode method (more frequentclass to fall into a destination cell is
the chosen). My question is: when I have a tie between two classes, how
does GRASS decides which class shall be chosen?
In the event of a tie, the lowest-numbered category is chosen.
--
Glynn Clements <glynn@gclements.plus.com>
Hi Glynn.
Thanks for your answer. Is there any other alternative, to resample data, that uses another approach to solve tie events?
THanks
Antonio
Glynn Clements wrote:
António Rocha wrote:
I'm planning on using r.resamp.stats in order to resample a grid to a coarser resolution. Since I'm using this function with classes I will use mode method (more frequentclass to fall into a destination cell is the chosen). My question is: when I have a tie between two classes, how does GRASS decides which class shall be chosen?
In the event of a tie, the lowest-numbered category is chosen.
__________ Information from ESET NOD32 Antivirus, version of virus signature database 5912 (20110227) __________
The message was checked by ESET NOD32 Antivirus.
http://www.eset.com
António Rocha wrote:
>> I'm planning on using r.resamp.stats in order to resample a grid to a
>> coarser resolution. Since I'm using this function with classes I will
>> use mode method (more frequentclass to fall into a destination cell is
>> the chosen). My question is: when I have a tie between two classes, how
>> does GRASS decides which class shall be chosen?
>>
>
> In the event of a tie, the lowest-numbered category is chosen.
Thanks for your answer. Is there any other alternative, to resample
data, that uses another approach to solve tie events?
What mechanism do you want?
If you wanted e.g. the highest-numbered category, you could use
r.mapcalc to create a map with the categories negated, run
r.resamp.stats on that, then negate the result.
Some other possibilities could reasonably be handled with a
combination of pre- and post-processing.
For others, the only practical solution is to modify
lib/stats/c_mode.c.
--
Glynn Clements <glynn@gclements.plus.com>