SubsampleTimeseriesBlock: Subsample (downsample) timeseries using block averaging#'

View source: R/SubsampleTimeseriesBlock.R

SubsampleTimeseriesBlockR Documentation

Subsample (downsample) timeseries using block averaging#'

Description

Resample a equidistant timeseries (e.g. model result) at the 'timepoints' using block averaging. The blocks are divided at 1/2 time between the requested output points. For the first (and last) timepoint, the interval starting mean(diff(timepoints)) before (ending after) are used. Example usage is to downsample a model timeseries to mimick an integrating proxy (e.g. water isotopes that are measured by melting pieces of ice).

Usage

SubsampleTimeseriesBlock(ts, timepoints)

Arguments

ts

ts object or vector containing the equidistant timeseries

timepoints

vector with the points in time

Value

values at timepoints

Author(s)

Thomas Laepple


EarthSystemDiagnostics/orbitalforcing documentation built on March 24, 2022, 11:25 a.m.