1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89
|
\name{compclassf.train}
\alias{compclassf.train}
\title{
Functional Componentwise Classifier
}
\description{
Trains the functional componentwise classifier
}
\usage{
compclassf.train (dataf, labels, subset,
to.equalize = TRUE,
to.reduce = TRUE,
classifier.type = c("ddalpha", "maxdepth", "knnaff", "lda", "qda"),
...)
}
\arguments{
\item{dataf}{
list containing lists (functions) of two vectors of equal length, named "args" and "vals": arguments sorted in ascending order and corresponding them values respectively
}
\item{labels}{
list of output labels of the functional observations
}
\item{subset}{
an optional vector specifying a subset of observations to be used in training the classifier.
}
\item{to.equalize}{
Adjust the data to have equal (the largest) argument interval.
}
\item{to.reduce}{
If the data spans a subspace only, project on it (by PCA).
}
\item{classifier.type}{
the classifier which is used on the transformed space. The default value is 'ddalpha'.
}
\item{\dots}{
additional parameters, passed to the classifier, selected with parameter \code{classifier.type}.
}
}
\details{
The finite-dimensional space is directly constructed from the observed values.
Delaigle, Hall and Bathia (2012) consider (almost) all sets of discretization points
that have a given cardinality.
The usual classifiers are then trained on the constructed finite-dimensional space.
}
\value{
Trained functional componentwise classifier
%% If it is a LIST, use
%% \item{comp1 }{Description of 'comp1'}
%% \item{comp2 }{Description of 'comp2'}
%% ...
}
\references{
Delaigle, A., Hall, P., and Bathia, N. (2012). Componentwise classification and clustering of functional data. \emph{Biometrika} \bold{99} 299--313.
}
\seealso{
\code{\link{compclassf.classify}} for classification using functional componentwise classifier,
\code{\link{ddalphaf.train}} to train the functional DD-classifier,
\code{\link{dataf.*}} for functional data sets included in the package.
}
\examples{
\dontrun{
## load the Growth dataset
dataf = dataf.growth()
learn = c(head(dataf$dataf, 49), tail(dataf$dataf, 34))
labels =c(head(dataf$labels, 49), tail(dataf$labels, 34))
test = tail(head(dataf$dataf, 59), 10) # elements 50:59. 5 girls, 5 boys
c = compclassf.train (learn, labels, classifier.type = "ddalpha")
classified = compclassf.classify(c, test)
print(unlist(classified))
}
}
\keyword{ functional }
\keyword{ robust }
\keyword{ multivariate }
\keyword{ nonparametric }
\keyword{ classif }
|