Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>This isn't perfect as you don't have the speed in your data but it should get you to where you want with a few aesthetic changes:</p> <p><strong>Reshaping your data into a dataframe:</strong></p> <pre><code>dat1 &lt;- read.table(text=" 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", header=T) dat2 &lt;- read.table(text=" 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", header=T) dat3 &lt;- read.table(text=" 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", header=T) lst &lt;- list(dat1, dat2, dat3) dat &lt;- data.frame(Vehicle = rep(paste0("Vehicle", 1:3), sapply(lst, nrow)), do.call(rbind, lst)) dat$Road &lt;- factor(dat$Road) dat </code></pre> <p><strong>Plotting the data:</strong></p> <pre><code>library(ggplot2) ggplot(dat) + geom_segment(aes(x=Start, xend=End, y=Vehicle, yend=Vehicle), size=3) + coord_flip() + facet_grid(Road~.) </code></pre> <p><img src="https://i.stack.imgur.com/0u28W.png" alt="enter image description here"></p>
    singulars
    1. This table or related slice is empty.
    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.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      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