[GRASS-user] loops
    Hamish 
    hamish_nospam at yahoo.com
       
    Tue Jul 10 23:10:48 EDT 2007
    
    
  
goldneaa at onid.orst.edu wrote:
> I was able to create a loop in csh.  I am now trying to take averages 
> 
> and in order to do so I need to have "sep=," put into my command in  
> order to seperate my data with a comma.  When I try to put this into  
> my loop it says
> 
> foreach raster ( "`g.mlist rast pattern='ts_19*' sep=,`" )
> csh: Word too long.
> 
> This command works if I do not have the sep=, in it.  The problem is I
>  
> need to seperate my data by commas in order to  use r.series  
> method=average in my loop.
> 
> foreach? r.series input=$raster output=Run_Avg method=average
> As of right now my output only averages one of my rasters.
setenv INMAPS "`g.mlist rast pattern='ts_19*' sep=,`"
r.series input="$INMAPS" output=Run_Avg method=average
or
r.series input=`g.mlist rast pattern='ts_19*' sep=,` \
  output=Run_Avg method=average
?
Hamish
    
    
More information about the grass-user
mailing list