I am dealing with a data frame as shown below. x and y are the Mercator x, y coordinates of trajectories with time. Rows with same VoyageIDs are the points belonging to the same trajectory. As we can see the rows with all 0's are separating different trajectories.
VoyageID X Y Time
27 2 -7.35857534 2.09175178 1.29471228
28 2 -7.35863779 2.09167080 1.29471234
29 2 -7.35882203 2.09156224 1.29471240
30 2 -7.35908808 2.09147633 1.29471246
31 2 -7.35941313 2.09134900 1.29471252
32 2 -7.35970112 2.09123810 1.29471258
33 0 0.0000000 0.0000000 0.0000000
34 3 -7.34769342 2.09628155 1.29498270
35 3 -7.34811254 2.09626864 1.29498282
36 3 -7.34853711 2.09625315 1.29498288
37 3 -7.34889255 2.09622732 1.29498294
38 0 0.0000000 0.0000000 0.0000000
39 4 -7.35857089 2.09176469 1.29531606
40 4 -7.35862989 2.09169697 1.29531612
41 4 -7.35869312 2.09162679 1.29531618
42 4 -7.35876692 2.09158959 1.29531624
43 0 0.0000000 0.0000000 0.0000000
I would kindly request to suggest me the best way to visualize these trajectories in the following two ways:
How can I plot x, y coordinates on a simple 2d line plot ?
How can I plot the trajectories with x,y coordinates on a leaflet map (Using Folium or any other real map) ?
Also, how do I manage the points of different trajectories (They are separated by 0's). I am new to python as well as matplotlib, so please provide me with little detailed answers if possible. Thanks in advance.