Learn R Programming

edina (version 0.1.1)

as_q_matrix: Coerce data.frame and matrix classes to Q Matrix.

Description

as.q_matrix acts as an aliases.

Usage

as_q_matrix(x, ...)

# S3 method for data.frame as_q_matrix(x, ...)

# S3 method for matrix as_q_matrix(x, ...)

# S3 method for default as_q_matrix(x, ...)

Value

A q_matrix object.`

Arguments

x

Either a data.frame or matrix.

...

Not used

See Also

q_matrix()

Examples

Run this code
# Q matrix values
x = matrix(c(1, 0, 0, 1), nrow = 2)

# Construct class
q_mat = as_q_matrix(x)

Run the code above in your browser using DataLab