continuousOps: Simple continuous index merge and Ops

Description Usage Arguments Details Value Author(s)

View source: R/OVariable.r

Description

continuousOps merges two ovariables by continuous indices and performs an operation.

Usage

1
continuousOps(O1, O2, fun, cols = NULL)

Arguments

O1

ovariable

O2

ovariable

fun

function or function name (character) that is to be performed. Typically '*', '+' or some other Ops.

cols

character vector of column names that contain continuous indices. Only needed if there are > 1 indices and the order is critical. Otherwise, shared continuous indices are identified automatically.

Details

O1 is of main interest, while O2 has information that links to O2 via continuous index or indices. All locations in these continuous indices of O1 are created for O2 assuming that the value in the previous location of cols applies. Note that this is asymmetric. Locations in O2 that are missing from O1 are omitted. continuousOps assumes that all continuous indices are in the same dimension, the first one being the main index. Additional indices affect the outcome only if there are (approximate) ties. Therefore, avoid using this with several continuous indices. However, if continuous indices are NOT shared by both O1 and O2, they cause no trouble.

See also: http://en.opasnet.org/

Value

Returns an Ovariable

Author(s)

J. Tuomisto jouni.tuomisto@thl.fi


OpasnetUtils documentation built on May 2, 2019, 12:39 p.m.