[GRASS-SVN] r66229 - grass-addons/grass7/raster/r.mcda.topsis
svn_grass at osgeo.org
svn_grass at osgeo.org
Mon Sep 14 12:19:29 PDT 2015
Author: gianluca
Date: 2015-09-14 12:19:29 -0700 (Mon, 14 Sep 2015)
New Revision: 66229
Modified:
grass-addons/grass7/raster/r.mcda.topsis/r.mcda.topsis.py
Log:
-clean work files
Modified: grass-addons/grass7/raster/r.mcda.topsis/r.mcda.topsis.py
===================================================================
--- grass-addons/grass7/raster/r.mcda.topsis/r.mcda.topsis.py 2015-09-14 19:15:09 UTC (rev 66228)
+++ grass-addons/grass7/raster/r.mcda.topsis/r.mcda.topsis.py 2015-09-14 19:19:29 UTC (rev 66229)
@@ -60,7 +60,7 @@
for criterion,weight in zip(attributes,weights):
gscript.mapcalc("critPow=pow(${criterion},2)",criterion=criterion,overwrite='True')
stats=gscript.parse_command("r.univar",map='critPow',flags='g')
- nameMap="_%s" % criterion.split("@")[1]
+ nameMap="_%s" % criterion
gscript.mapcalc("${nameMap}=(${criterion}/sqrt(${sum}))*${weight}", \
nameMap=nameMap,criterion=criterion,sum=stats['sum'],weight=weight,overwrite='True')
criteria.append(nameMap)
More information about the grass-commit
mailing list