Note that there are some explanatory texts on larger screens.

plurals
  1. POPlotting a visualization of different categories of observation in R
    primarykey
    data
    text
    <p>Using R, I want to plot a map of several observations (where an observation is a particular vehicle given by its registration plate) of speeding over defined distances along several different roads. I also want to color code the observations according to how much above the speed limit a vehicle traveled (red- +30mph, yellow- 20-30mph, blue- 0-20mph).</p> <p><strong>INPUT</strong></p> <ol> <li>For each vehicle: <ul> <li>the road on which it was found speeding </li> <li>the locations (start and end) for the given road along which it was speeding (can be multiple times on one road) </li> <li>the category of speeding (red, yellow or blue as above).</li> </ul></li> <li>For each road <ul> <li>the distance of the road. </li> </ul></li> </ol> <p>Data</p> <pre><code>$Vehicle1 Road Start End 1 157398137 166811234 1 216984017 238298694 1 238298694 247249719 2 0 8794530 2 8794530 26703134 2 59852594 73085123 2 206737339 218577503 2 218695178 231142027 3 96301465 115456078 3 116345621 126898764 $Vehicle2 Road Start End 1 157398137 166811234 1 216984017 238298694 1 238298694 247249719 2 0 8794530 2 8794530 26703134 2 59852594 73085123 2 206737339 218577503 3 3469683 56797911 3 96301465 115456078 3 116345621 126898764 $Vehicle3 Road Start End 1 157398137 166811234 1 216984017 238298694 1 238298694 247249719 2 0 8794530 2 8794530 26703134 2 59852594 73085123 2 206737339 218577503 2 218695178 231142027 2 231142027 241946296 3 3469683 56797911 3 96301465 115456078 3 116345621 126898764 Road Length 1 529290651 2 249139323 3 298024420 </code></pre> <p><strong>EXPECTED OUTPUT</strong></p> <p><img src="https://i.stack.imgur.com/lPujM.png" alt="enter image description here"></p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload