getTopFeatures {alcyon} | R Documentation |
Extract top x percent of features
Description
Sorts features by a specific column and extracts the top x percent
Usage
getTopFeatures(lineStringMap, column, percent)
Arguments
lineStringMap |
An sf lineString map |
column |
The column to use to extract the features from |
percent |
Percentage of features (to total) to extract |
Value
The lineString map filtered and sorted
Examples
mifFile <- system.file(
"extdata", "testdata", "barnsbury",
"barnsbury_small_axial_original.mif",
package = "alcyon"
)
sfMap <- st_read(mifFile,
geometry_column = 1L, quiet = TRUE
)
shapeGraph <- as(sfMap, "AxialShapeGraph")
shapeGraph <- allToAllTraverse(
shapeGraph,
traversalType = TraversalType$Topological,
radii = c("n", "3"),
includeBetweenness = TRUE
)
getTopFeatures(shapeGraph, "Connectivity", 0.1)
[Package alcyon version 0.4.0 Index]