<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<style type="text/css">body p { margin-bottom: 0cm; margin-top: 0pt; } </style>
</head>
<body bidimailui-charset-is-forced="true" text="#000000"
bgcolor="#FFFFFF">
<br>
<div class="moz-cite-prefix">On 31/10/2019 22:20, Markus Metz wrote:<br>
</div>
<blockquote type="cite"
cite="mid:CAG+h=FGJYqKV==3HGZrvEVjgzcW89VUvMu-z7oadjxe9bGMnfg@mail.gmail.com">
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<div dir="ltr"><br>
<br>
On Tue, Oct 29, 2019 at 7:40 PM Veronica Andreo <<a
href="mailto:veroandreo@gmail.com" moz-do-not-send="true">veroandreo@gmail.com</a>>
wrote:<br>
><br>
> Hi Daniel,<br>
><br>
> I agree that if there's a NULL in the column, there should
be NULL in the resulting raster. I suggest to open a ticket
here: <a href="https://trac.osgeo.org/grass/"
moz-do-not-send="true">https://trac.osgeo.org/grass/</a><br>
<div><br>
</div>
<div>easy solution: v.to.rast where="<attribute_column> is
not null"</div>
<div><br>
</div>
<div>or the new PR #173</div>
<div><a href="https://github.com/OSGeo/grass/pull/173"
moz-do-not-send="true">https://github.com/OSGeo/grass/pull/173</a></div>
<div>if an attribute value is null, the corresponding vector
features will not be rasterized</div>
<div><br>
</div>
<div>Markus M</div>
<div><br>
</div>
</div>
</blockquote>
<p><br>
</p>
<p>I'm not sure I agree with the approach that a polygon with
missing attribute should become NULL. In my view, NULL should be
used only for pixels not covered at all by any polygon. </p>
<p>Perhaps an additional input parameter "missing_attribute" so the
user can choose a value to enter into the raster if the attribute
is missing. If no parameter is supplied, and the chosen attribute
column has missing values, I'd prefer that the script exit
gracefully, with a message that a "missing_attribute" value is
required.</p>
<p><br>
</p>
<p><br>
</p>
<blockquote type="cite"
cite="mid:CAG+h=FGJYqKV==3HGZrvEVjgzcW89VUvMu-z7oadjxe9bGMnfg@mail.gmail.com">
<div dir="ltr">
<div>></div>
> Cheers,<br>
> Vero<br>
><br>
> El jue., 24 oct. 2019 a las 14:40, Daniel Victoria (<<a
href="mailto:daniel.victoria@gmail.com" moz-do-not-send="true">daniel.victoria@gmail.com</a>>)
escribió:<br>
>><br>
>> Hi list,<br>
>><br>
>> I have a vector polygon map that I'm converting to
raster. The attribute column that I process has some empty rows
(no data / null). When I run v.to.rast, these empty rows become
0 (zero) on my resulting raster map.<br>
>><br>
>> Shouldn't v.to.rast respect the empty attribute table
and create null values for those polygons?<br>
>><br>
>> For now I'll use r.null to fix this problem. But what
if 0 is a valid value?<br>
>><br>
>> Cheers<br>
>> Daniel<br>
>><br>
>> PS - Running Grass 7.6.1 on Ubuntu<br>
>> _______________________________________________<br>
>> grass-user mailing list<br>
>> <a href="mailto:grass-user@lists.osgeo.org"
moz-do-not-send="true">grass-user@lists.osgeo.org</a><br>
>> <a
href="https://lists.osgeo.org/mailman/listinfo/grass-user"
moz-do-not-send="true">https://lists.osgeo.org/mailman/listinfo/grass-user</a><br>
><br>
> _______________________________________________<br>
> grass-user mailing list<br>
> <a href="mailto:grass-user@lists.osgeo.org"
moz-do-not-send="true">grass-user@lists.osgeo.org</a><br>
> <a
href="https://lists.osgeo.org/mailman/listinfo/grass-user"
moz-do-not-send="true">https://lists.osgeo.org/mailman/listinfo/grass-user</a></div>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<pre class="moz-quote-pre" wrap="">_______________________________________________
grass-user mailing list
<a class="moz-txt-link-abbreviated" href="mailto:grass-user@lists.osgeo.org">grass-user@lists.osgeo.org</a>
<a class="moz-txt-link-freetext" href="https://lists.osgeo.org/mailman/listinfo/grass-user">https://lists.osgeo.org/mailman/listinfo/grass-user</a></pre>
</blockquote>
<pre class="moz-signature" cols="72">--
Micha Silver
Ben Gurion Univ.
Sde Boker, Remote Sensing Lab
cell: +972-523-665918</pre>
</body>
</html>