Software Open Access

otpr: An API wrapper for OpenTripPlanner

Young, Marcus

otpr is an R package that provides a wrapper for the OpenTripPlanner (OTP) API. To use otpr you will need a running instance of OTP. The purpose of the package is to submit a query to the relevant OTP API resource, parse the OTP response and return useful R objects. The package is aimed at both new and expert users of OTP. The key parameters needed to query each supported API resource are provided as (or via) otpr function arguments. The argument values submitted by the user are comprehensively checked prior to submission to OTP to ensure that they are valid and make sense in combination, with feedback provided as appropriate. This makes the package ideal for new users of OTP (especially when used with the accompanying tutorial). Advanced users can provide any additional API parameters they wish via the extra.params argument. These parameters are passed directly to the OTP API without checks.

otpr currently supports the following OTP API resources:

  • PlannerResource - retrieve one or more trip itineraries between supplied origin and destination by the designated mode(s).
  • LIsochrone Resource (OTPv1 only) - generate isochrone maps (the area accessible from or to a point within specified time thresholds).
  • SurfaceResource (OTPv1 only) - create and evaluate travel time surfaces (extremely efficient one-to-many analysis and generation of accessibility measures)

This package will be useful to researchers and transport planners who want to use OTP to generate trip data for accessibility analysis or to derive variables for use in transportation models.

Files (140.4 MB)
Name Size
otpr-0.5.0.zip
md5:cdfc30692f9cd589f75159925e0e460c
140.4 MB Download
98
2
views
downloads
All versions This version
Views 9842
Downloads 21
Data volume 203.9 MB140.4 MB
Unique views 7241
Unique downloads 21

Share

Cite as