melolp wrote:

> grass.run_command("r.profile",-g,input= teste1,output = teste, [12244.256 
> -295112.597,12128.012 -295293.77])

> However I'm having the following error mesage:
> 
> "non-keyword arg after keyword arg grass.run_command"

All arguments except the first are keyword arguments, i.e. "arg = val".

        grass.run_command(
                "r.profile",
Okay
                -g,

This should be: flags = 'g'. "-g" would be the negative of a Python
variable namd "g".

                input= teste1,
                output = teste,
Okay
                [12244.256 -295112.597,12128.012 -295293.77])

This should be:
                profile = [12244.256,-295112.597,12128.012,-295293.77]
or:
                profile = [(12244.256,-295112.597),(12128.012,-295293.77)]

i.e. you need to provide the keyword, and the argument must be a valid
Python expression. run_command() etc accept lists and tuples.

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

Reply via email to