Description Usage Arguments Examples

Subset the nodes in a matrix of cost values based on user defined point-of-interest coordinates, a user-defined importance cutoff, and a randomly selected proportion of non-null cells. Generate a graph object from this subset using delaunay triangulation.

1 2 |

`dm` |
matrix of 2d cost values |

`poicoords` |
matrix 2 column point-of-interest coordinates |

`grainprop` |
numeric proportion of cells selected as grain cells |

`cutoff` |
numeric user-defined importance cutoff |

`irregular` |
logical skip irregular node subsetting routine? |

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 | ```
## Not run:
dm <- matrix(
c(1, 1, 1, 1, 1,
NA, NA, NA, NA, 1,
1, 1, 1, 1, 1,
1, 1, 1, 1, 1,
1, 1, 1, 1, 1
), ncol = 5, byrow = TRUE)
sp::plot(raster::raster(dm))
raster::text(raster::raster(dm), which(raster::raster(dm)[] == 1))
graph <- irl_graph(dm)
plot(graph$graph)
geometry::trimesh(graph$tri$tri, graph$allcoords)
## End(Not run)
``` |

jsta/irlgraph documentation built on May 18, 2017, 10:45 a.m.

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.