From d5befee58bfa0899420b63d02f4bfa92d7290999 Mon Sep 17 00:00:00 2001 From: rldhont Date: Tue, 31 May 2016 19:09:05 +0200 Subject: [PATCH] [BUGFIX][Processing] R: Extent from raster package is "xmin, xmax, ymin, ymax" Extent from raster package is like in Processing http://www.inside-r.org/packages/cran/raster/docs/Extent --- python/plugins/processing/algs/r/RAlgorithm.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/python/plugins/processing/algs/r/RAlgorithm.py b/python/plugins/processing/algs/r/RAlgorithm.py index 7fa2b3c91177..f01f4bd5e73a 100644 --- a/python/plugins/processing/algs/r/RAlgorithm.py +++ b/python/plugins/processing/algs/r/RAlgorithm.py @@ -352,7 +352,9 @@ def getImportCommands(self): elif isinstance(param, ParameterExtent): if param.value: tokens = unicode(param.value).split(',') - commands.append(param.name + ' = extent(' + tokens[0] + ',' + tokens[2] + ',' + tokens[1] + ',' + tokens[3] + ')') + # Extent from raster package is "xmin, xmax, ymin, ymax" like in Processing + # http://www.inside-r.org/packages/cran/raster/docs/Extent + commands.append(param.name + ' = extent(' + tokens[0] + ',' + tokens[1] + ',' + tokens[2] + ',' + tokens[3] + ')') else: commands.append(param.name + ' = NULL') elif isinstance(param, ParameterCrs):