trader/core/utils/date_utils.py
def date_range_length(datetime_index, periods=None):
    """Get length of date_range list

    pd.date_range result of date_range is inclusive. Therefore last
    timeframe does not fit in the time interval calculated in date_range
    function.

    Args:
        t (DatetimeIndex): list of datetime objects

    Returns:
        Int: date_range count
    """
    length = len(datetime_index)
    return length if periods else length - 1
Get length of date_range list

    pd.date_range result of date_range is inclusive. Therefore last
    timeframe does not fit in the time interval calculated in date_range
    function.

    Args:
        t (DatetimeIndex): list of datetime objects

    Returns:
        Int: date_range count
    
Get length of date_range list
pd.date_range result of date_range is inclusive. Therefore last
timeframe does not fit in the time interval calculated in date_range
function.
Get length of date_range list pd . date_range result of date_range is inclusive . Therefore last timeframe does not fit in the time interval calculated in date_range function .
def date_range_length(datetime_index, periods=None):
    length = len(datetime_index)
    return length if periods else length - 1
def date_range_length ( datetime_index , periods = None ) : length = len ( datetime_index ) return length if periods else length - 1
Get length of date_range list
pd.date_range result of date_range is inclusive.
Get length of date_range list pd . date_range result of date_range is inclusive .
"""Get length of date_range list

    pd.date_range result of date_range is inclusive. Therefore last
    timeframe does not fit in the time interval calculated in date_range
    function.

    Args:
        t (DatetimeIndex): list of datetime objects

    Returns:
        Int: date_range count
    """
None
Int
datetime_index
periods
t
list of datetime objects
list of datetime objects