[GRASS-dev] Parsing output of r.category which includes labels
Nikos Alexandris
nik at nikosalexandris.net
Tue Aug 21 04:29:03 PDT 2018
* Moritz Lennert <mlennert at club.worldonline.be> [2018-08-21 12:57:01 +0200]:
>On 21/08/18 12:47, Stefan Blumentrath wrote:
>>Hi Nikos,
>>
>>If you are interested in dictionary output you could do:
>>
>>category_labels = grass.parse_command('r.category', map='youmap', delimiter='\t')
>
>Right, nice solution !
>
>For those not very familiar with the scripting library: the
>"delimiter" option here is an option to parse_command, not to
>r.category. It decides which delimiter parse_command should use for
>deciding what is a key and what is a value.
Fantastic. I read that 'delimiter' somewhere... :-)
Nikos
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 228 bytes
Desc: not available
URL: <http://lists.osgeo.org/pipermail/grass-dev/attachments/20180821/df76c95b/attachment.sig>
More information about the grass-dev
mailing list