gs_quant.timeseries.datetime.weekday¶
- weekday(x)[source]¶
Weekday of each value in series
- Parameters:
x (
Series
) – time series- Return type:
Series
- Returns:
weekday of observations
Usage
Returns the weekday as a numeric value for each observation in the series:
\(Y_t = weekday(t)\)
Weekday of the time or date is the integer day of the week, e.g. 0-6, where 0 represents Monday
Examples
Weekday for observations in series:
>>> series = generate_series(100) >>> days = weekday(series)
See also