| 1782 |
maechler |
1 |
\name{triangularMatrix-class}
|
|
|
2 |
\docType{class}
|
|
|
3 |
\alias{triangularMatrix-class}
|
|
|
4 |
\title{Virtual Class of Triangular Matrices in package:Matrix}
|
|
|
5 |
\description{
|
|
|
6 |
The virtual class of triangular matrices,\code{"triangularMatrix"},
|
|
|
7 |
from the package \pkg{Matrix} contains numeric and logical, dense and
|
|
|
8 |
sparse matrices, e.g., see the examples.
|
|
|
9 |
|
|
|
10 |
The main use will be in methods (and C functions) that can deal with
|
|
|
11 |
all triangular matrices.
|
|
|
12 |
}
|
|
|
13 |
% \section{Objects from the Class}{A virtual Class: No objects may be created from it.}
|
|
|
14 |
\section{Slots}{
|
|
|
15 |
\describe{
|
|
|
16 |
\item{\code{uplo}:}{Object of class \code{"character"}. Must be
|
|
|
17 |
either "U", for upper triangular, and "L", for lower triangular.}
|
|
|
18 |
\item{\code{diag}:}{Object of class \code{"character"}. Must be
|
|
|
19 |
either \code{"U"}, for unit triangular (diagonal is all ones), or
|
|
|
20 |
\code{"N"} for non-unit. The diagonal elements are not
|
|
|
21 |
accessed internally when \code{diag} is \code{"U"} (but need to be
|
|
|
22 |
allocated, i.e., \code{length(x)} does not depend on \code{diag}).}
|
| 1784 |
maechler |
23 |
%% below {Dim, Dimnames} work around Slot parsing buglet (< 2.2.0)
|
|
|
24 |
\item{\code{Dim, Dimnames}:}{The dimension (a length-2
|
| 1782 |
maechler |
25 |
\code{"integer"}) and corresponding names (or \code{NULL}),
|
| 3175 |
maechler |
26 |
inherited from the \code{\linkS4class{Matrix}}, see there.}
|
| 1782 |
maechler |
27 |
}
|
|
|
28 |
}
|
|
|
29 |
\section{Extends}{
|
|
|
30 |
Class \code{"Matrix"}, directly.
|
|
|
31 |
}
|
|
|
32 |
\section{Methods}{
|
|
|
33 |
There's a C function \code{triangularMatrix_validity()}
|
|
|
34 |
called by the internal validity checking functions.
|
|
|
35 |
%% Currently:
|
|
|
36 |
%% No methods defined with class "triangularMatrix" in the signature.
|
|
|
37 |
}
|
|
|
38 |
\seealso{
|
| 3175 |
maechler |
39 |
Classes \code{\linkS4class{symmetricMatrix}}, and, e.g.,
|
|
|
40 |
\code{\linkS4class{dtrMatrix}} for numeric \emph{dense} matrices, or
|
|
|
41 |
\code{\linkS4class{ltCMatrix}} for a logical \emph{sparse} matrix
|
| 1782 |
maechler |
42 |
subclass of \code{"triangularMatrix"}.
|
|
|
43 |
}
|
|
|
44 |
\examples{
|
|
|
45 |
showClass("triangularMatrix")
|
|
|
46 |
|
|
|
47 |
## The names of direct subclasses:
|
|
|
48 |
scl <- getClass("triangularMatrix")@subclasses
|
|
|
49 |
directly <- sapply(lapply(scl, slot, "by"), length) == 0
|
|
|
50 |
names(scl)[directly]
|
|
|
51 |
}
|
|
|
52 |
\keyword{classes}
|