log_transform: Computes log transformed streamflow vector.

Description Usage Arguments Value

View source: R/performance_metrics.R

Description

compute the log transformed value of streamflow using either the approach proposed by Pushpalatha et al. (2012) (i.e. a 100th of the mean value is added to each streamflow value), or by adding any given value to all streamflow values or simply by setting to NA any non finite value resulting from the application of the log() function.

Usage

1
log_transform(x, method = "Pushpalatha2012")

Arguments

x

numeric vector. Streamflow vector to log transform.

method

Method used to deal with missing values: 'Pushpalatha2012' a numeric value (to be added to 'x') or 'inf.na'. If a charcter string equal to "Pushpalatha2012", the method of Pushpalatha et al. (2012) is used. If a character string equal to "inf.na", any non-finite value are set to NA. If a flow value, it is added to each streamflow value before transofmation.

Value

Returns a numeric vector of the same length than x containing the log transformed streamflow values.


IvanHeriver/hsa-R-package documentation built on Dec. 17, 2021, 11:32 p.m.