2
0
Fork 0
CVE/CVE_C/man/cve.Rd

101 lines
2.9 KiB
R

% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/CVE.R
\name{cve}
\alias{cve}
\alias{cve.call}
\title{Conditional Variance Estimator (CVE).}
\usage{
cve(formula, data, method = "simple", max.dim = 10L, ...)
cve.call(X, Y, method = "simple", nObs = sqrt(nrow(X)), h = NULL,
min.dim = 1L, max.dim = 10L, k = NULL, momentum = 0, tau = 1,
tol = 0.001, slack = 0, gamma = 0.5, V.init = NULL,
epochs = 50L, attempts = 10L, logger = NULL)
}
\arguments{
\item{formula}{an object of class \code{"formula"} which is a symbolic
description of the model to be fitted.}
\item{data}{an optional data frame, containing the data for the formula if
supplied.}
\item{method}{specifies the CVE method variation as one of
\itemize{
\item "simple" exact implementation as described in the paper listed
below.
\item "weighted" variation with addaptive weighting of slices.
}}
\item{max.dim}{upper bounds for \code{k}, (ignored if \code{k} is supplied).}
\item{...}{Parameters passed on to \code{cve.call}.}
\item{X}{data matrix with samples in its rows.}
\item{Y}{Responses (1 dimensional).}
\item{nObs}{parameter for choosing bandwidth \code{h} using
\code{\link{estimate.bandwidth}} (ignored if \code{h} is supplied).}
\item{min.dim}{lower bounds for \code{k}, (ignored if \code{k} is supplied).}
\item{k}{Dimension of lower dimensional projection, if \code{k} is given
only the specified dimension \code{B} matrix is estimated.}
\item{tau}{Initial step-size.}
\item{tol}{Tolerance for break condition.}
\item{epochs}{maximum number of optimization steps.}
\item{attempts}{number of arbitrary different starting points.}
\item{logger}{a logger function (only for advanced user, significantly slows
down the computation).}
}
\value{
dr is a S3 object of class \code{cve} with named properties:
\itemize{
\item X: Original training data,
\item Y: Responce of original training data,
\item method: Name of used method,
\item call: The method call
}
as well as indexed entries \code{dr[[k]]} storing the k-dimensional SDR
projection matrices.
dr is a list which contains:
\itemize{
\item dir: dir[[d]] is the central space with d-dimension
d = 1, 2, ..., p reduced direction of different dimensions
\item y: the value of response
\item idx: the index of variables which survives after screening
\item max.dim: the largest dimensions of CS or CMS which have been calculated in mave function
\item ky: parameter used for DIM for selection
\item x: the original training data
}
}
\description{
TODO: reuse of package description and details!!!!
}
\examples{
library(CVE)
# create dataset
n <- 200
p <- 12
X <- matrix(rnorm(n * p), n, p)
B <- cbind(c(1, rep(0, p - 1)), c(0, 1, rep(0, p - 2)))
Y <- X \%*\% B
Y <- Y[, 1L]^2 + Y[, 2L]^2 + rnorm(n, 0, 0.3)
# Call the CVE method.
dr <- cve(Y ~ X)
(B <- basis(dr, 2))
}
\seealso{
For a detailed description of \code{formula} see
[\code{\link{formula}}].
}