Description Usage Arguments Value Examples
Create a maze uzing a randomized version of depth-first search algorithm (recursive backtracker).
| 1 2 | makeMaze_dfs(gD = NA, stepBystep = FALSE, nrows = 0, ncols = 0,
  inShiny = FALSE)
 | 
| gD | an existing maze graph object. | 
| stepBystep | a flag that will allow a step by step plot of maze creation | 
| nrows | maze hight (number of rows); required only for the step by step plot; default value set to 0. | 
| ncols | maze width (number of columns); required only for the step by step plot; default value set to 0. | 
| inShiny | a flag that marks whether the function is called from a shiny app or console | 
Given a connected maze graph (with all walls on), this function creates a maze (removes some walls) using depth-first search algorithm (recursive backtracker), and returns the resulting maze graph.
| 1 2 3 | maze1 <- makeGraph(10, 10)
maze1 <- makeMaze_dfs(maze1)
plotMaze(maze1, 10, 10)
 | 
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.