src/main/java/com/conveyal/gtfs/stats/FeedStats.java
public int getDailyAverageHeadway (LocalDate date, LocalTime from, LocalTime to) {

        OptionalDouble avg =  feed.stops.values().stream()
                .map(s -> this.stop.getAverageHeadwayForStop(s.stop_id, date, from, to))
                .mapToDouble(headway -> headway)
                .average();

        return (int) avg.getAsDouble();
    }
public int getDailyAverageHeadway (LocalDate date, LocalTime from, LocalTime to) {

        OptionalDouble avg =  feed.stops.values().stream()
                .map(s -> this.stop.getAverageHeadwayForStop(s.stop_id, date, from, to))
                .mapToDouble(headway -> headway)
                .average();

        return (int) avg.getAsDouble();
    }
in seconds