<div dir="ltr">Dear all,<div><br></div><div>I have a raster map with all categories (~50)</div><div>and I have about 500 spatial subsets of the same</div><div>original map. As is expected, each of spatial subset</div><div>
map have less categories than the original map.</div><div><br></div><div>I can check the list of categories for each subset</div><div>map using r.stats. But I need to generate a new</div><div>set of maps with the spatial range of original map,</div>
<div>but keeping only those classes of my original map.</div><div><br></div><div>Just supose that &quot;r.stats mysubset1&quot; result something</div><div>like:</div><div><br></div><div>2</div><div>4</div><div>9</div><div>
11</div><div>43</div><div><br></div><div>So, I would like that my new map with my full spatial</div><div>range keep only these 5 categories, and all other</div><div>categories come to be &quot;no data&quot;.</div><div><br>
</div><div>I know if I generate a rule file with&nbsp;</div><div>2=2</div><div>4=9</div><div>11=11</div><div>43=43</div><div>I can get the desired results, but as the number</div><div>of spatial subsets is very large I would like turn it</div>
<div>more operational.</div><div><br></div><div>Is there a suggestion of how can I do this using pipe like</div><div>r.stats mysubset1 | r.reclass mysubset1 mysubset1_fullrange rules= -??</div><div><br></div><div>Thanks for all</div>
<div>Best regards</div><div><br></div><div>Miltinho Brazil</div></div>