smnorris / fwapg

PostgreSQL tools for working with British Columbia's Freshwater Atlas
https://smnorris.github.io/fwapg
MIT License
9 stars 5 forks source link

FWA_IndexPoint - round measures? #61

Open smnorris opened 3 years ago

smnorris commented 3 years ago

This level of precision is tiresome. Is it practical to round the outputs? Certainly distance_to_stream can be rounded to nearest cm or mm, but rounding the route measure may get fussy. If adjusting all fwapg dependent scripts to use FWA_IndexPoint rather than custom queries it might be ok.

 stream_crossing_id | blue_line_key | downstream_route_measure | distance_to_stream 
--------------------+---------------+--------------------------+--------------------
                  1 |     360884282 |        866.1525308411424 |  6.945908761529624
                  1 |     360825762 |                        0 |  94.80438292808357
                  2 |     360866620 |        36032.59046348071 | 3.7025663441681003
smnorris commented 3 years ago

distance_to_stream now rounded to nearest mm. https://github.com/smnorris/fwapg/commit/ae7846ab6bac6fbc7e2b369811aa0f7fd69d774a