Description Usage Arguments Value Examples
Plot maze solution (path)
1 | plotMazeSolution(gD = NA, nrows = 0, ncols = 0, inShiny = FALSE)
|
gD |
an existing maze graph object. |
nrows |
maze hight (number of rows); default value set to 0. |
ncols |
maze width (number of columns); default value set to 0. |
inShiny |
a flag that marks whether the function is called from a shiny app or console. |
The maze solution is found as the shortest path between the start and end maze cells (currently, start and end points of the maze are fixed). The function uses ggplot to plot a maze.
1 2 3 4 | maze1 <- makeGraph(10, 10)
maze1 <- makeMaze_dfs(maze1)
plotMaze(maze1, 10, 10)
plotMazeSolution(maze1, 10, 10)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.