User:Kentsmith9/WME segment length display View history

(updates)
(Updated tables and text)
Line 5: Line 5:
| text = The following information is only focused on the WME application and will not be covering the impact on the client app.
| text = The following information is only focused on the WME application and will not be covering the impact on the client app.
}}
}}


== Overview ==
== Overview ==
Line 12: Line 13:
When a user selects the [[metric|metric unit measurement system from WME]], the interface displays a whole metric unit rounded (up or down), not truncated.
When a user selects the [[metric|metric unit measurement system from WME]], the interface displays a whole metric unit rounded (up or down), not truncated.


When a user selects the imperial unit measurement system from WME, the interface simply translates the already rounded metric units as imperial units. WME displays two decimal places of accuracy for the translation from the rounded numbers, giving a false sense of precision.
When a user selects the [[imperial|imperial unit measurement system from WME]], the interface simply translates the already rounded metric units into imperial units. WME displays two decimal places of accuracy for the translation from the rounded numbers, giving a false sense of precision. Note that any third decimal unit is also rounded as needed.


== Metric precision and rounding ==
== Metric precision and rounding ==
The internal units are stored with an accuracy of 0.01 meters (0.0328 ft) or about 3/8-inch accuracy. However, the displayed units will be rounded up or down as needed to produce only whole meters. When the segment length reaches more than 999 meters, it switches to kilometers and changes the precision to 0.01 km (or 10 m). This means, you might nudge the end of a segment slightly, but the displayed length may not change if the nudge was inside of the 10 meter range of the kilometer display.
The internal units are stored with an accuracy of 0.01 meters (0.0328 ft) or about 3/8-inch accuracy. However, the displayed units will be rounded up or down as needed to produce only whole meters. When the segment length reaches more than 999 meters, it switches to kilometers and changes the precision to 0.01 km (or 10 m). This means, you might nudge the end of a segment slightly, but the displayed length may not change if the nudge was inside of the 10 meter range of the kilometer display.


The meters displayed are rounded to the nearest whole number, with a minimum savable segment size of 1 meter (3.28 feet). Drawing or shrinking a segment any shorter than that will result in a save error. Segments shorter than {{:Segment length/Minimum}} will not accurately track speed data and should be avoided. See this discussion on [[Segment_length#Too_short|minimum segment length ]] for more information.
The meters displayed are rounded to the nearest whole number, with a minimum savable segment size of 1 meter (3.28 feet). Drawing or shrinking a segment any shorter than that will result in a save error. Segments shorter than {{:Segment length/Minimum}} will not accurately track speed data and should be avoided. See this discussion on [[Segment_length#Too_short|minimum segment length]] for more information.


Meters are rounded with the following formula:<br />
Meters are rounded with the following formula:<br />
Line 23: Line 24:


This results in the following:
This results in the following:
{| class="wikitable"
{| class="wikitable" style="text-align: center;"
|-
|-
! colspan="4" | Meters
! colspan="4" | Meters
Line 64: Line 65:


The formula for the kilometer range is more complex. Note the precision is still based on the 2 decimal places for the meters:<br />
The formula for the kilometer range is more complex. Note the precision is still based on the 2 decimal places for the meters:<br />
:<code>Int( ( ( TrueSegmentLength + 0.5 ) / 10  ) / 100 </code><br />
:<code>Interger( ( ( TrueSegmentLength + 0.5 ) / 10  ) / 100 </code><br />
:''Int = Interger''
:''Int = Interger in the table below''


This results in the following:
This results in the following:
{| class="wikitable"
{| class="wikitable" style="text-align: center;"
|-
|-
! colspan="6" | Kilometers
! colspan="6" | Kilometers
Line 124: Line 125:


== Imperial precision and rounding ==
== Imperial precision and rounding ==
When changing the WME display to [imperial]], there is no change to the underlying segment unit value. The WME interface simply translates all the already rounded metric displayed values into the equivalent imperial values out to two decimal places. This has the negative impact of purporting a high degree of precision when in fact it is without basis.
When changing the WME display to [[imperial]], there is no change to the underlying segment unit value. The WME interface simply translates all the already rounded metric displayed values into the equivalent imperial values out to two decimal places. This has the negative impact of purporting a high degree of precision when in fact it is without basis.


The translation from metric to imperial is done by the following formula:
The translation from metric to imperial is done by the following formula:
Line 130: Line 131:


This results in the following:
This results in the following:
{| class="wikitable"
{| class="wikitable" style="text-align: center;"
|-
|-
! colspan="5" | Feet
! colspan="5" | Feet
Line 145: Line 146:
|-
|-
|5
|5
| Interger( 5 * 328.084 +0.5 ) / 100
| Interger( 5 * 328.084 + 0.5 ) / 100
| Interger( 1640.92) / 100
| Interger( 1640.920) / 100
| 1640 / 100
| 1640 / 100
| 16.4
| 16.4
|-
|-
|6
|6
| Interger( 6 * 328.084 +0.5) / 100
| Interger( 6 * 328.084 + 0.5) / 100
| Interger( 1969.004) / 100
| Interger( 1969.004) / 100
| 1969 / 100
| 1969 / 100
Line 158: Line 159:


Now look at what happened to the original unit as measured in feet after it is rounded in metric and then converted back to imperial:
Now look at what happened to the original unit as measured in feet after it is rounded in metric and then converted back to imperial:
FINISH TABLE UPDATES


This results in the following:
This results in the following:
{| class="wikitable"
{| class="wikitable" style="text-align: center;"
|-
|-
! colspan="3" | Feet
! colspan="4" | Feet
|-
|-
! True length (ft)
! True length (ft)
! True length (m)
! Rounded metric
! Rounded metric
! Displayed result (ft)
! Displayed result (ft)
|-
|-
|4.49
| 14.73
| Interger(4.99)
| 4.49
| 4
| 4
| 13.12
|-
|-
|4.50
| 14.76
| Interger(5.0)
| 4.50
| 5
| 5
| 16.4
|-
|-
|4.99
| 16.37
| Interger(5.49)
| 4.99
| 5
| 5
| 16.4
|-
|-
|16.4
| 5.00
| 5.00
| Interger(5.5)
| 5
| 5
| 16.4
|-
|-
| 18.01
| 5.49
| 5.49
| Interger(5.99)
| 5
| 5
| 16.4
|-
|-
| 18.04
| 5.50
| 5.50
| Interger(6.0)
| 6
| 6
| 19.69
|-
|-
|}
|}


 
Because WME will show the value 5 meters or 16.4 feet for wide range of values both above and below 5 meters, that value cannot reliably be used to ensure a segment is above or below a server threshold of 5 meters or 16.4 feet. Therefore, to guarantee you are above a 5 meter threshold you must select 6 meters or 19.69 feet. Similarly, if you want to ensure you are below a 5 meter threshold you must select 4 meters or 13.2 feet.
MORE HERE EXPLAINING THE TRANSLATION


== Custom precision script for WME ==
== Custom precision script for WME ==
Users in the Waze editing community have developed scripts that can be loaded into the browser to enable additional functionality not available in the basic WME available from Waze. One such script is the [[Scripts/WME_True_Segment_Length|WME True Segment Length]]. This script will display the true length of the segment in both metric and imperial units with two decimal places of accuracy.
Users in the Waze editing community have developed scripts that can be loaded into the browser to enable additional functionality not available in the basic WME available from Waze. One such script is the [[Scripts/WME_True_Segment_Length|WME True Segment Length]]. This script will display the true length of the segment in both metric and imperial units with two decimal places of accuracy.

Revision as of 01:45, 21 May 2017

The Waze platform is based on metric units and each Waze application (WME and the client app) translates that into imperial units as required. Both display interfaces have a loss of accuracy in the displayed segment length due to rounding.

The following information is only focused on the WME application and will not be covering the impact on the client app.


Overview

All Waze segment length information is based on metric unit measurements.

When a user selects the metric unit measurement system from WME, the interface displays a whole metric unit rounded (up or down), not truncated.

When a user selects the imperial unit measurement system from WME, the interface simply translates the already rounded metric units into imperial units. WME displays two decimal places of accuracy for the translation from the rounded numbers, giving a false sense of precision. Note that any third decimal unit is also rounded as needed.

Metric precision and rounding

The internal units are stored with an accuracy of 0.01 meters (0.0328 ft) or about 3/8-inch accuracy. However, the displayed units will be rounded up or down as needed to produce only whole meters. When the segment length reaches more than 999 meters, it switches to kilometers and changes the precision to 0.01 km (or 10 m). This means, you might nudge the end of a segment slightly, but the displayed length may not change if the nudge was inside of the 10 meter range of the kilometer display.

The meters displayed are rounded to the nearest whole number, with a minimum savable segment size of 1 meter (3.28 feet). Drawing or shrinking a segment any shorter than that will result in a save error. Segments shorter than 19.69 ft (6 m) will not accurately track speed data and should be avoided. See this discussion on minimum segment length for more information.

Meters are rounded with the following formula:

Interger( TrueSegmentLength + 0.5 )

This results in the following:

Meters
True length (m) Formula Steps Displayed result (m)
4.49 Interger(4.49 + 0.5) Interger(4.99) 4
4.50 Interger(4.5 + 0.5) Interger(5.0) 5
4.99 Interger(4.99 + 0.5) Interger(5.49) 5
5.00 Interger(5 + 0.5) Interger(5.5) 5
5.49 Interger(5.49 + 0.5) Interger(5.99) 5
5.50 Interger(5.5 + 0.5) Interger(6.0) 6

The formula for the kilometer range is more complex. Note the precision is still based on the 2 decimal places for the meters:

Interger( ( ( TrueSegmentLength + 0.5 ) / 10 ) / 100
Int = Interger in the table below

This results in the following:

Kilometers
True length (m) Formula Steps Displayed result (km)
1004.99 Int( ( 1004.99 + 5 ) / 10 ) / 100 Int( 1009.99 / 10 ) / 100 Int( 100.999 ) / 100 100 / 100 1.00
1005.00 Int( ( 1005 + 5 ) / 10 ) / 100 Int( 1010 / 10 ) / 100 Int( 101 ) / 100 101 / 100 1.01
1009.99 Int( ( 1009.99 + 5 ) / 10 ) / 100 Int( 1014.99 / 10 ) / 100 Int( 101.499 ) / 100 101 / 100 1.01
1010.00 Int( ( 1010 + 5 ) / 10 ) / 100 Int( 1015 / 10 ) / 100 Int( 101.5 ) / 100 101 / 100 1.01
1014.99 Int( ( 1014.99 + 5 ) / 10 ) / 100 Int( 1019.99 / 10 ) / 100 Int( 101.999 ) / 100 101 / 100 1.01
1015.00 Int( ( 1015 + 5 ) / 10 ) / 100 Int( 1020 / 10 ) / 100 Int( 102 ) / 100 102 / 100 1.02


Drawing of the reality of segment lengths compared to the stepped output of the whole numbers including the rounding.

Imperial precision and rounding

When changing the WME display to imperial, there is no change to the underlying segment unit value. The WME interface simply translates all the already rounded metric displayed values into the equivalent imperial values out to two decimal places. This has the negative impact of purporting a high degree of precision when in fact it is without basis.

The translation from metric to imperial is done by the following formula:

Interger( ( RoundedMetricDisplayUnit * 3.28084 + 0.5 ) / 100

This results in the following:

Feet
Rounded length (m) Formula Steps Displayed result (ft)
4 Interger( 4 * 328.084 + 0.5 ) / 100 Interger( 1312.836) / 100 1312 / 100 13.12
5 Interger( 5 * 328.084 + 0.5 ) / 100 Interger( 1640.920) / 100 1640 / 100 16.4
6 Interger( 6 * 328.084 + 0.5) / 100 Interger( 1969.004) / 100 1969 / 100 19.69

Now look at what happened to the original unit as measured in feet after it is rounded in metric and then converted back to imperial:

This results in the following:

Feet
True length (ft) True length (m) Rounded metric Displayed result (ft)
14.73 4.49 4 13.12
14.76 4.50 5 16.4
16.37 4.99 5 16.4
16.4 5.00 5 16.4
18.01 5.49 5 16.4
18.04 5.50 6 19.69

Because WME will show the value 5 meters or 16.4 feet for wide range of values both above and below 5 meters, that value cannot reliably be used to ensure a segment is above or below a server threshold of 5 meters or 16.4 feet. Therefore, to guarantee you are above a 5 meter threshold you must select 6 meters or 19.69 feet. Similarly, if you want to ensure you are below a 5 meter threshold you must select 4 meters or 13.2 feet.

Custom precision script for WME

Users in the Waze editing community have developed scripts that can be loaded into the browser to enable additional functionality not available in the basic WME available from Waze. One such script is the WME True Segment Length. This script will display the true length of the segment in both metric and imperial units with two decimal places of accuracy.