Learn R Programming

infoDecompuTE (version 0.6.2)

identityMat: Identity Matrix

Description

Construct an identity matrix.

Usage

identityMat(n)

Arguments

n

a numeric describes the dimension of the identity matrix.

Value

This function returns a matrix with the diagonal elements equal to one and the off-diagonal elements equal to zero.

References

John J, Williams E (1987). Cyclic and computer generated Designs. Second edition. Chapman & Hall.

See Also

diag

Examples

Run this code
# NOT RUN {

identityMat(10)


# }

Run the code above in your browser using DataLab