R/matlab_package_functions.R

Defines functions ones zeros

Documented in ones zeros

#' Matrix to create zeros
#'
#' @param n size of the matrix
#'
#' @return a square matrix of zeros
zeros <- function(n) {
  return(matrix(0,n,n))

}

#' Returns an Identity matrix
#'
#' @param n size of the matrix
#'
#' @return a identity matrix 
ones <- function(n) {
  return(matrix(1,n,n))
}
spedygiorgio/markovchain documentation built on Feb. 29, 2024, 3:01 p.m.