Generate a square maze of the specified dimentions using a specified weight function.
make_maze(nrow = 1, ncol = 1, weight.fun = "rnorm")
nrow | number of rows. |
---|---|
ncol | number of columns. |
weight.fun | weight function. |
An object of class igraph. A minimum spaning tree.
make_maze(2, 2)#> IGRAPH 9ba4435 U--- 4 3 -- Lattice graph #> + attr: name (g/c), dimvector (g/n), nei (g/n), mutual (g/l), circular #> | (g/l), ncol (g/n), nrow (g/n), layout (g/n), labels (v/n) #> + edges from 9ba4435: #> [1] 1--2 2--4 3--4