RAnEnExtra::generatePersistence generates persistent analog ensemble forecasts. For each test forecast, it simply takes the historical observation values that are associated with the historical forecasts that are directly prior to the current forecasts. The number of values taken would be the number of ensemble members desired.

generatePersistence(
  test.times,
  flts,
  observations,
  obs.id,
  obs.times,
  num.analogs,
  forecast.time.interval = 86400,
  show.progress = F,
  silent = F
)

Arguments

test.times

Forecast times

flts

Forecast lead times

observations

Observation data array

obs.id

Observation vairable index

obs.times

Observation times

num.analogs

The number of analogs

forecast.time.interval

The forecast time interval in seconds. This is also the number of seconds between two forecast cycle time. It is usually 24 * 60 * 60 because the third dimension of forecasts is usually day. If it is half day, change the value accordingly.

show.progress

Whether to show a progress bar.

silent

Whether to be silent.

Value

An 5-dimension array [stations, times, flts, members, index for (values, stations, times)].

Details

For example, to generate a 3-member persistent analog ensemble for a particular forecast at a certain grid point, a certain lead time, and on July 25, 2019, the observations associated with the historical forecasts on July 22, 24, and 24 will be included in the persistent analogs.