def points_for_interval(interval):
 range = time_range_by_interval[interval]
 interval = timedelta_by_name(interval)
 return (range.total_seconds() / interval.total_seconds())

def points_for_interval ( interval ) : range = time_range_by_interval [ interval ] interval = timedelta_by_name ( interval ) return ( range . total_seconds ( ) / interval . total_seconds ( ) )
calculate the number of data points to render for a given interval .