pseudo_obs {rvinecopulib} | R Documentation |
Pseudo-Observations
Description
Compute the pseudo-observations for the given data matrix.
Usage
pseudo_obs(x, ties_method = "average", lower_tail = TRUE)
Arguments
x |
vector or matrix random variates to be converted (column wise) to pseudo-observations. |
ties_method |
similar to |
lower_tail |
|
Details
Given n
realizations ,
of a random vector
X
, the pseudo-observations are defined via
for
and
, where
denotes the rank of
among all
,
.
The pseudo-observations can thus also be computed by component-wise applying
the empirical distribution functions to the data and scaling the result by
. This asymptotically negligible scaling factor is used to force
the variates to fall inside the open unit hypercube, for example, to avoid
problems with density evaluation at the boundaries.
When lower_tail = FALSE
, then pseudo_obs()
simply returns
1 - pseudo_obs()
.
Value
a vector of matrix of the same dimension as the input containing the pseudo-observations.
Examples
# pseudo-observations for a vector
pseudo_obs(rnorm(10))
# pseudo-observations for a matrix
pseudo_obs(cbind(rnorm(10), rnorm(10)))