board: Board Class Constructor

Description Usage Arguments Value Examples

View source: R/board.R

Description

Class constructor function for the class "board".

Usage

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

Arguments

mat

If not NULL, contains a board matrix.

n

Dimension of the square board matrix. Used only when mat == NULL.

p

A float between 0 to 1 that denotes the fraction of the n^2 squares are blocked. Used only when mat == NULL.

Value

The generated board object per inputted instructions.

Examples

1

lilinhonglexie/percolate documentation built on Nov. 4, 2019, 4:32 p.m.