best_travel: The best travel function

Description Usage Arguments Value Examples

Description

This function calculates the index of the minimum travel as long as the difference between the best travel and the current don't extrapolate the time limit and the interval between the current travel schedule and the best travel schedule

Usage

1
2
best_travel(prev_travel, curr_travel, next_travel, diff_prev_schedule,
  diff_next_schedule, duration_limit, time_limit)

Arguments

prev_travel

length of the previous travel in minutes

curr_travel

length of the main travel in minutes

next_travel

length of the next travel in minutes

diff_prev_schedule

difference in minutes between the current travel and the previous

diff_next_schedule

difference in minutes between the current travel and the next

duration_limit

time limit applied on the difference between the best travel duration and the current travel duration

time_limit

headway maximum time in order that a travel can be considered the best

Value

-1 or 0 or 1

Examples

1
2
3
best_travel(50,32,20,25,35,5,45)
best_travel(50,32,20,25,35,5,30)
best_travel(26,32,20,25,35,5,30)

analytics-ufcg/bestBus documentation built on May 12, 2019, 2:38 a.m.