[Qgis-user] raster calculator functions
Carlos Cerdán
sig.upagu at gmail.com
Thu Oct 17 12:53:49 PDT 2013
Something is wrong. Let's see:
1. ("alt at 1">0 or "alt at 1"=<0) is a logical sentence. If value in a cell
complies this condition (it's true) then value will be 1, else 0. So, if
you do ("alt at 1">0 or "alt at 1"=<0)*n, you would have a layer with value "n"
Aaaah, I see: it's the operator. It must be: ("alt at 1">0 or "alt at 1"<=0):
it's better if you use the buttons of calculator raster to make this
sentence.
Gook luck
Carlos
Spanish note: Sergio el operador debe ser <=, en QGIS mejor usa los botones
de la calculadora para construir la sentencia. Yo probé con un DEM y he
tenido buenos resultados en QGIS y GRASS.
2013/10/17 Sergio A Estay <sergio.estay at uach.cl>
> Hi everybody,
>
> I am trying to convert a raster layer "alt" into exp(alt) or log(alt).
> Using the raster calculator it was impossible. Carlos Cerdán suggested me
> this workaround:
>
> 1. *("alt at 1">0 or "alt at 1"=<0)*2* gets a raster layer with value 2 per
> cell (let's put name =value2).
>
> 2. *"value2"^"alt at 1"* must be a layer with each cell elevated to some
> value on "alt at 1". If value in cell of "alt at 1" is big, you get "inf"
> (infinite?) values
>
> However, in step 1 I obtained a layer with just NaN values (for example
> with the attached layer and many others). Also trying 2^"alt at 1" I
> obtained just NaN values.
>
> I tried with grass plugin r.mapcaculator function, but also it didn't work.
>
> Any ideas how can I make this operations inside Qgis or Grass? (In the
> meantime I proccess my layers in R without problems, raster package).
>
> the link to the example layer:
>
>
> http://biogeo.ucdavis.edu/data/climate/worldclim/1_4/grid/cur/alt_10m_bil.zip
>
> best
>
>
> --
> Sergio A. Estay
> Inst. Ciencias Ambientales y Evolutivas
> Universidad Austral de Chile
> Casilla 567, Valdivia, Chile
> Phone: 5663-293913http://www.ciencias.uach.cl/instituto/ciencias_ambientales_evolutivas/academicos/sergio-estay.php
>
>
> _______________________________________________
> Qgis-user mailing list
> Qgis-user at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/qgis-user
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-user/attachments/20131017/0fde07c4/attachment.html>
More information about the Qgis-user
mailing list