R/as.matrix.permutationMatrix.R

Defines functions `as.matrix.permutationMatrix`

## as.matrix.permutationMatrix - an S3 method to convert to the S3
## matrix class. Essentially this just strips attributes and updates
## the class to only "matrix"

`as.matrix.permutationMatrix` <- function(x, ...) {
    attr(x, "seed") <- NULL
    attr(x, "control") <- NULL
    class(x) <- "matrix"
    x
}

Try the permute package in your browser

Any scripts or data that you put into this service are public.

permute documentation built on March 18, 2022, 7:36 p.m.