<div dir="ltr"><p style="color:rgb(48,48,48);font-family:Verdana,Tahoma,Arial,sans-serif;font-size:12px">Hi Anita,</p><p style="color:rgb(48,48,48);font-family:Verdana,Tahoma,Arial,sans-serif;font-size:12px">It took me a bit of trial and error to figure out how to get case statements to work in Pyculator (there is no direct case equivalent in Python). You have to define a function in the Global expression section, and then implement it using the relevant attribute fields in the Formula section. So if you've managed to get Pyculator working but are still struggling with the formula, you could try the following (I haven't tested it):</p>
<p style="color:rgb(48,48,48);font-family:Verdana,Tahoma,Arial,sans-serif;font-size:12px"><strong>Global expression:</strong><br><code>def f(x): return {None:0,}.get(x,1)</code></p><p style="color:rgb(48,48,48);font-family:Verdana,Tahoma,Arial,sans-serif;font-size:12px">
<strong>Formula</strong><br><code>value = f( <maxspeed> )</code></p><p style="color:rgb(48,48,48);font-family:Verdana,Tahoma,Arial,sans-serif;font-size:12px">You might get more clarity on how to translate a case statement for Pyculator by looking at the following issues on the bug tracker:</p>
<p><font color="#303030"><font face="Verdana, Tahoma, Arial, sans-serif"><span style="font-size:12px"><a href="http://hub.qgis.org/issues/6374#note-4">http://hub.qgis.org/issues/6374#note-4</a></span></font><br></font><a href="http://hub.qgis.org/issues/6578" style="font-family:Verdana,Tahoma,Arial,sans-serif;font-size:12px;color:rgb(48,48,48)">http://hub.qgis.org/issues/6578</a></p>
<p>See also:<br><a href="http://stackoverflow.com/questions/60208/replacements-for-switch-statement-in-python">http://stackoverflow.com/questions/60208/replacements-for-switch-statement-in-python</a> (case statements in Python)<br>
<a href="http://stackoverflow.com/questions/7030029/python-is-it-reasonable-to-use-none-as-a-dictionary-key">http://stackoverflow.com/questions/7030029/python-is-it-reasonable-to-use-none-as-a-dictionary-key</a><br></p><p>
<br></p><p style>Kind regards,<br>Rudi</p></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Mon, Jan 7, 2013 at 2:23 PM, Nathan Woodrow <span dir="ltr"><<a href="mailto:madmanwoo@gmail.com" target="_blank">madmanwoo@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">No you can upload as many versions as you like. Just mark the plugin as experimental so that people know that it is under development.<span class="HOEnZb"><font color="#888888"><div>
<br></div><div>- Nathan</div></font></span></div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br>

<br><div class="gmail_quote">On Mon, Jan 7, 2013 at 10:22 PM, Victor Olaya <span dir="ltr"><<a href="mailto:volayaf@gmail.com" target="_blank">volayaf@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">


But that will create a huge number of versions in the plugin page. I<br>
thought that it was meant to be used for stable versions, not for<br>
daily ones, right?<br>
<br>
Victor<br>
<br>
2013/1/7 Paolo Cavallini <<a href="mailto:cavallini@faunalia.it" target="_blank">cavallini@faunalia.it</a>>:<br>
<div><div>> Il 05/01/2013 16:31, Victor Olaya ha scritto:<br>
><br>
>> I am thinking about creating daily versions of the SEXTANTE code, so<br>
><br>
> can't you just publish it through <a href="http://plugins.qgis.org" target="_blank">plugins.qgis.org</a>?<br>
> a simple script to zip and upload it should do the trick.<br>
> all the best.<br>
> --<br>
> Paolo Cavallini - Faunalia<br>
> <a href="http://www.faunalia.eu" target="_blank">www.faunalia.eu</a><br>
> Full contact details at <a href="http://www.faunalia.eu/pc" target="_blank">www.faunalia.eu/pc</a><br>
> Nuovi corsi QGIS e PostGIS: <a href="http://www.faunalia.it/calendario" target="_blank">http://www.faunalia.it/calendario</a><br>
> _______________________________________________<br>
> Qgis-user mailing list<br>
> <a href="mailto:Qgis-user@lists.osgeo.org" target="_blank">Qgis-user@lists.osgeo.org</a><br>
> <a href="http://lists.osgeo.org/mailman/listinfo/qgis-user" target="_blank">http://lists.osgeo.org/mailman/listinfo/qgis-user</a><br>
_______________________________________________<br>
Qgis-user mailing list<br>
<a href="mailto:Qgis-user@lists.osgeo.org" target="_blank">Qgis-user@lists.osgeo.org</a><br>
<a href="http://lists.osgeo.org/mailman/listinfo/qgis-user" target="_blank">http://lists.osgeo.org/mailman/listinfo/qgis-user</a><br>
</div></div></blockquote></div><br></div>
</div></div><br>_______________________________________________<br>
Qgis-user mailing list<br>
<a href="mailto:Qgis-user@lists.osgeo.org">Qgis-user@lists.osgeo.org</a><br>
<a href="http://lists.osgeo.org/mailman/listinfo/qgis-user" target="_blank">http://lists.osgeo.org/mailman/listinfo/qgis-user</a><br>
<br></blockquote></div><br></div>