1

currently I am trying to visualize some GPS data based on a time-series. After research I found a video in youtube which is used R+leaflet+Time dimension plug-in. I think this video is what exactly I want. https://www.youtube.com/watch?v=fabaVT6TSTU

My problem is, when I run the following script, the R show me error: could not find function "addTimeDimension", my question is how to run leaflet(javascript) plug in in leaflet (R).

Really appreciate your help

 leaflet(withTime)%>%
+   addTiles()%>%
+   setView(lng=103.8260,lat=1.2502,zoom=14)%>%
+   addCircles()%>%
+   addTimeDimension(
+       options=timeDimensionOptions(
+         timeInterval="2017-12-11 12:23:40/2017-12-11 15:54:40"
+       )
+   )
SymbolixAU
  • 25,502
  • 4
  • 67
  • 139
  • R's [leaflet package](https://cran.r-project.org/web/packages/leaflet/leaflet.pdf) don't have any option of `addTimeDimension` but [this](https://stackoverflow.com/a/36587525/6779509) might help you – parth Jan 22 '18 at 06:21
  • Hi, Parth, thanks for fast response, what I want is to visualize gps data using time-series animation...something like what BK did in video – shufang song Jan 22 '18 at 06:36
  • @shufong: i got your point, but i couldn't the relevant _time-functions_ like `addTimeDimension`,`addTimeDimensionSupport` used in video in relevant package, so exporting [Leaflet TimeDimension](https://github.com/socib/Leaflet.TimeDimension) using [`htmlwidget`](http://www.htmlwidgets.org/) seems to be the long-walk here – parth Jan 22 '18 at 09:06
  • ok, thanks for answering~~I think I better use javascript for my visulization – shufang song Jan 23 '18 at 01:30

0 Answers0