board: An object with superclass "matrix" and subclass "board"

Description Usage Arguments Value Examples

View source: R/board.R

Description

An object with superclass "matrix" and subclass "board"

Usage

1
board(mat = NULL, n = 5, p = 0.25)

Arguments

mat

a matrix (if valid, a square matrix that contains only 0s, 1s, and 2s)

n

a positive integer denote the size of the board

p

a number between 0 and 1 that denotes the fraction of the n^2 squares are blocked

Value

'board' sub - class (matrix primary class) object; if matrix input paramter is incorrect, return an error

Examples

1
board(mat = NULL, n = 5, p = 0.25), board(generate_board_mat())

adityagandhi81298/percolate documentation built on Nov. 1, 2019, 8:54 p.m.