rajatrn wrote:

> I have two layer lists, NDVIFILES and VIQALIST, both developed using g.mlist
> command in GRASS.
> Each file has 22 items in it. I would like to perform a simple raster
> calculation of the following form,
> Mask$NDVIFILES [i] = NDVIFILES[i] * VIQALIST[i]
> I'm unable to create a loop which can sequentially produce the required
> outputs.
> I will be grateful if anyone can help me with creating a loop using
> bash/shell script.

        while read ndvi <&3 ; do
            read viqa <&4
            r.mapcalc "Mask$ndvi = $ndvi * $viqa"
        done 3< NDVIFILES 4< VIQALIST

-- 
Glynn Clements <[email protected]>
_______________________________________________
grass-user mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/grass-user

Reply via email to