is.projector {dae}R Documentation

Tests whether an object is a valid object of class projector

Description

Tests whether an object is a valid object of class "projector".

Usage

is.projector(object)

Arguments

object

The matrix to be made into a projector.

Details

The function is.projector tests whether the object consists of a matrix that is square, symmetric and idempotent. In checking symmetry and idempotency, the equality of the matrix with either its transpose or square is tested. In this, a difference in elements is considered to be zero if it is less than daeTolerance, which is initially set to .Machine$double.eps ^ 0.5 (about 1.5E-08). The function set.daeTolerance can be used to change daeTolerance.

Value

TRUE or FALSE depending on whether the object is a valid object of class "projector".

Warning

The degrees of freedom are not checked. correct.degfree can be used to check them.

Author(s)

Chris Brien

See Also

projector, correct.degfree in package dae.

projector for further information about this class.

Examples

## set up a 2 x 2 mean operator that takes the mean of a vector of 2 values
m <- matrix(rep(0.5,4), nrow=2)

## create an object of class projector
proj.m <- projector(m)

## check that it is a valid projector
is.projector(proj.m)

[Package dae version 3.2.28 Index]