Le Fri, 10 Feb 2017 19:15:25 +0100, Paulo van Breugel <p.vanbreu...@gmail.com> a écrit :
> On 10-02-17 18:41, Moritz Lennert wrote: > [...] > [...] > [...] > [...] > [...] > [...] > [...] > [...] > [...] > >> Besides, manually, I calculated > >> Moran's I and Intrasegment Variance by i.segment with 8 instead of > >> 4 neighbors (default). Even if the object looks kind of " > >> pixelated" at the border, I received smaller Moran's I and > >> Intrasegment Variance values with i.segment 8 NB in comparison to > >> 4 NB (same settings for minsize and threshold). Maybe the "-d" > >> flag of i.segment could also be added to i.segment.uspo... > > > > That shouldn't be too difficult. Internally, i.segment.uspo uses > > the addon r.neighborhoodmatrix which has a '-d' flag. I just really > > do not have the time to implement this right now. You could try > > yourself by opening the i.segment.uspo (or on Windows > > i.segment.uspo.py) file and adding "flags='d'" to the call to > > r.neighborhoodmatrix (lines 535 and following): > > > > res = gscript.read_command('r.neighborhoodmatrix', > > input_=mapname, > > output='-', > > sep='comma', > > flags='d', > > quiet=True) > > > > > > This will always apply the flag. When I have time I can add this as > > a flag to i.segment.uspo. > > > > A slightly larger project I have is to actually extract the code > > for the calculation of the spatial autocorrelation and create a > > "r.spatialautocorrelation" module. But not now... ;-) > > +1 (or make that a double plus) that would be really great! r70696: r.object.spatialautocor: new addon to calculate global spatial autocorrelation for raster objects Moritz _______________________________________________ grass-user mailing list grass-user@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/grass-user