conveyal / otp.js

OTP Javascript Client & Data Bindings
MIT License
19 stars 20 forks source link

Add ability to display nearby stops departures using device position, or arbitrary set position #79

Closed kalon33 closed 4 years ago

kalon33 commented 8 years ago

It would be great to be able to display the next departures at nearby stops (within a given or set radius) from the device position, but also be able to do this to an arbitrary position (for helping someone travelling, or simply to display that information for some place we're are not yet).

tuukka commented 8 years ago

You may want to describe the feature with more detail. At least in Digitransit, it hasn't been easy to define what this means exactly: how to cluster, sort, and filter stops, patterns and trips, and which columns to display.

All that aside, the new GraphQL endpoint can give you stopsByRadius, and for those, stoptimesForPatterns or stoptimesWithoutPatterns. clustersByRadius for stations seems to be missing. patternsByRadius might be nice.

kalon33 commented 8 years ago

@tuukka thanks for helping me to be clearer.

1) I want to sort by distance first, and then by time, with a "group" item for each stop. 2) If possible, yes. It is tricky for the user to find the proper line when bus stops and stations for each line have different names or stop locations, whereas they are in the same ~50m radius. 3) Sure, it would be nice, but not mandatory. 4) Yes, and I think you're doing this because it is very useful when you will miss the next bus due to a few minutes, and know when is the next one, or have to hurry to get it (because the next one is too late). 5) No, I think that the good limit would be one hour or two, not later. Or, you provide a mean to set a time when you want to know next departures.

I know, and that would make it easier. But currently due to this bug https://github.com/opentripplanner/OpenTripPlanner/issues/2170 I'm still stuck to OTP 0.18.x, as it make me unable to properly run the OTP instances I have on the same server.