Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

rplusarithm

vectorial arithmetic for data sets with rplus class


Description

The positive quadrant forms a manifold of the real vector space. The induced operations +,-,*,/ give results valued in this real vector space (not necessarily inside the manifold).

Usage

mul.rplus(x,r)
## Methods for class rplus
##   x+y
##  x-y
##   -x
##   x*r
##   r*x
##   x/r

Arguments

x

an rplus composition or dataset of compositions

y

an rplus composition or dataset of compositions

r

a numeric vector of size 1 or nrow(x)

Details

The functions behave quite like +.rmult.

Value

rmult-objects containing the given operations on the rcomp manifold as subset of the R^D. Only the addition and multiplication with positive numbers are internal operation and results in an rplus-object again.

Note

For * the arguments x and y can be exchanged.

Author(s)

K.Gerald v.d. Boogaart http://www.stat.boogaart.de

See Also

Examples

rplus(1:5)* -1 + rplus(1:5)
data(SimulatedAmounts)
cdata <- rplus(sa.lognormals)
plot( tmp <- (cdata-mean(cdata))/msd(cdata) )
class(tmp)
mean(tmp)
msd(tmp)
var(tmp)

compositions

Compositional Data Analysis

v2.0-1
GPL (>= 2)
Authors
K. Gerald van den Boogaart <boogaart@hzdr.de>, Raimon Tolosana-Delgado, Matevz Bren
Initial release
2021-01-08

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.