gs_quant.timeseries.datetime.quarter — gs_quant 0.1 documentation

# gs_quant.timeseries.datetime.quarter

`quarter`(x)

  Quarter of each value in series

  Parameters

    x (`Series`) – time series

  Return type

    `Series`

  Returns

    quarter of observations

  Usage

  Returns the quarter as a numeric value for each observation in the series:

  \(Y_t = quarter(t)\)

  Quarter of the time or date is the integer quarter number, e.g. 1, 2, 3, 4

  Examples

  Quarter for observations in series:

      >>> series = generate_series(100)
      >>> days = quarter(series)

  See also

  `day()` `month()`