special.matrix: Generating Special Matrices

Description Usage Arguments See Also Examples

Description

Creates an Identity Matrix I and a Matrix of Ones J.

Usage

1
2
3
I(n)

J(n, m = n)

Arguments

n

Number of rows in I or J.

m

Number of columns in J. Default: Same as number of rows.

See Also

Other matrix: tr(), vec()

Examples

1
2
3
4
5
6
# To create an identity matrix of order 12
I(2)
# To make a matrix of 6 rows and 10 columns of all ones
J(6, 10)
# To make a matrix of unity, dimensions 6 x 6.
J(6)

phargarten2/matrixNormal documentation built on Dec. 31, 2021, 12:06 a.m.