TimeSeriesPartialPeriodsMethod {MacrobondAPI}R Documentation

Partial periods to lower frequency methods

Description

A list of named values that determines the method for converting partial periods of a series to a lower frequency.

Format

The list contains named objects of type TimeSeriesPartialPeriodsMethodClass.

Details

The conversion method is used when making a unified series request and is a property of SeriesExpression.

None

Only include full periods of the lower frequency

Auto

Automatically select method based on series properties

RepeatLastValue

Use the last (or first) value to extend incomplete periods

FlowCurrentSum

Use the last (or first) partial average to extend incomplete periods

PastRateOfChange

Use the previous (or next) year's rate of change to extend incomplete periods

Zero

Extend incomplete periods with zeroes

See Also

SeriesExpression, setPartialPeriodsMethod, getPartialPeriodsMethod

Examples

# Convert the monthly series "uscpi" to quarterly frequency and fill in partial quarters at the start and end by repeating the closest value
seriesRequest <- CreateUnifiedTimeSeriesRequest()
setFrequency(seriesRequest, "Quarterly")
reqExp <- addSeries(seriesRequest, "uscpi")
setPartialPeriodsMethod(reqExp, "RepeatLastValue")
seriesCpi <- FetchTimeSeries(seriesRequest)[[1]]

[Package MacrobondAPI version 1.1-5 Index]