Learn R Programming

Matrix (version 1.2-8)

nMatrix-class: Class "nMatrix" of Non-zero Pattern Matrices

Description

The nMatrix class is the virtual “mother” class of all non-zero pattern (or simply pattern) matrices in the Matrix package.

Arguments

Slots

Common to all matrix object in the package:

Methods

There is a bunch of coercion methods (for as(..)), e.g.,
--- --- --- Additional methods contain group methods, such as

See Also

The classes lMatrix, nsparseMatrix, and the mother class, Matrix.

Examples

Run this code
getClass("nMatrix")

L3 <- Matrix(upper.tri(diag(3)))
L3 # an "ltCMatrix"
as(L3, "nMatrix") # -> ntC*

## similar, not using Matrix()
as(upper.tri(diag(3)), "nMatrix")# currently "ngTMatrix"

Run the code above in your browser using DataLab