anaForward: Forward gaussian anamorphosis forward transformation to...

View source: R/Anamorphosis.R

anaForwardR Documentation

Forward gaussian anamorphosis forward transformation to multivariate gaussian scores

Description

Forward gaussian anamorphosis forward transformation to multivariate gaussian scores

Usage

anaForward(
  x,
  Y,
  sigma0,
  sigma1 = 1 + sigma0,
  steps = 30,
  plt = FALSE,
  sphere = TRUE,
  weights = NULL
)

Arguments

x

points to be transformed (a matrix)

Y

node points defining the transformation (another matrix, same nr. of columns as x)

sigma0

starting spread of the kernels

sigma1

final spread of the kernels

steps

number of steps to linearize the transform (default 30 is good)

plt

boolean, do you want to get a plot of the transformation?

sphere

boolean, should the data be pre-Y-spherified first? defaults to true

weights

vector of weights for all computations, length must be equal to number of rows of x

Value

a matrix with the gaussian scores; same dimensions of x

Author(s)

K. Gerald van den Boogaart, Raimon Tolosana-Delgado

See Also

ana() for defining a function that carries over the transformation (by means of a closure), anaBackward() for the explicit back-transformation, sphTrans() for defining a function that carries over the spherification of the data

Examples

data("jura", package="gstat")
Y = jura.pred[,c(10,12,13)]
plot(compositions::acomp(Y))
Ylr = compositions::alr(Y)
plot(Ylr)
z = anaForward(x=Ylr, Y=Ylr, sigma0=0.1)
plot(z, asp=1)
shapiro.test(z[,1])
shapiro.test(z[,2])

gmGeostats documentation built on April 18, 2023, 5:08 p.m.