normalize: Center and rescale irregular time series (NA values are...

View source: R/Proxytools_helpers.R

normalizeR Documentation

Center and rescale irregular time series (NA values are removed from computing means / standard deviations)

Description

Center and rescale irregular time series (NA values are removed from computing means / standard deviations)

Usage

normalize(xin, center = TRUE, scale = TRUE)

Arguments

xin

Proxytibble with proxy data in 'zoo::zoo' format, or irregular time series object ('zoo::zoo'), xin can be multivariate

center

logical center to zero mean?

scale

logical normalize to unit standard deviation?

Value

Proxytibble with proxy data in 'zoo::zoo' format, or irregular time series object ('zoo::zoo'), xin can be multivariate

Examples

# Load Monticchio example data from PTBoxProxydata
library(PTBoxProxydata)
mng <- PTBoxProxydata::ProxyDataManager()
monticchiodata <- PTBoxProxydata::load_set(mng,'monticchio_testset',zoo_format = 'zoo', force_file=TRUE)
# Normalize proxy data in proxytibble
monticchiodata_normalized <- normalize(monticchiodata)

# Normalize single zoo
monticchiozoo_normalized <- normalize(monticchiodata$proxy_data[[1]])
# Plot zoo data
plot(monticchiozoo_normalized)
plot(monticchiodata_normalized$proxy_data[[1]])


paleovar/ptboxproxytools documentation built on June 9, 2025, 1:40 a.m.