Title: | Spatial Network Analysis |
---|---|
Description: | Interface package for 'sala', the spatial network analysis library from the 'depthmapX' software application. The R parts of the code are based on the 'rdepthmap' package. Allows for the analysis of urban and building-scale networks and provides metrics and methods usually found within the Space Syntax domain. Methods in this package are described by K. Al-Sayed, A. Turner, B. Hillier, S. Iida and A. Penn (2014) "Space Syntax methodology", and also by A. Turner (2004) <https://discovery.ucl.ac.uk/id/eprint/2651> "Depthmap 4: a researcher's handbook". |
Authors: | Petros Koutsolampros [cre, aut]
(<https://orcid.org/0000-0003-2842-9899>, 'sala' library
contributor through 'depthmapX'),
Fani Kostourou [ctb] |
Maintainer: | Petros Koutsolampros <[email protected]> |
License: | GPL-3 |
Version: | 0.7.0 |
Built: | 2025-02-21 02:54:26 UTC |
Source: | https://github.com/spatialnous/alcyon |
Runs Agent Analysis on the given PointMap
agentAnalysis( pointMap, timesteps, releaseRate, agentLifeTimesteps, agentFov, agentStepsToDecision, agentLookMode, originX = vector(), originY = vector(), locationSeed = 0L, numberOfTrails = 0L, getGateCounts = FALSE, copyMap = TRUE, verbose = FALSE, progress = FALSE )
agentAnalysis( pointMap, timesteps, releaseRate, agentLifeTimesteps, agentFov, agentStepsToDecision, agentLookMode, originX = vector(), originY = vector(), locationSeed = 0L, numberOfTrails = 0L, getGateCounts = FALSE, copyMap = TRUE, verbose = FALSE, progress = FALSE )
pointMap |
A PointMap, used as an exosomatic visual map for agents to take exploratory information |
timesteps |
Number of total system timesteps. |
releaseRate |
Agent release rate (likelihood of release per timestep). |
agentLifeTimesteps |
Agent total lifetime (in timesteps) |
agentFov |
Agent field-of-view (out of 32 bins = 360). |
agentStepsToDecision |
Agent steps before turn decision. |
agentLookMode |
The agent look mode. See AgentLookMode |
originX |
Agent starting points (x coordinates). |
originY |
Agent starting point (y coordinates). |
locationSeed |
Agents to start at random locations with specific seed (0 to 10). Default is 0. |
numberOfTrails |
Record trails for this amount of agents (set to 0 to record all, with max possible currently = 50). |
getGateCounts |
Get values at gates |
copyMap |
Optional. Copy the internal sala map |
verbose |
Optional. Show more information of the process. |
progress |
Optional. Show process progress. |
Returns a list with:
newAttributes: The new attributes that were created during the process
trailMap: A ShapeMap with trails if numberOfTrails was set over 0
mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) pointMap <- makeVGAPointMap( sfMap, gridSize = 0.5, fillX = 3.0, fillY = 6.0, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE ) agentAnalysis( pointMap, timesteps = 3000L, releaseRate = 0.1, agentStepsToDecision = 3L, agentFov = 11L, agentLife = 1000L, agentLookMode = AgentLookMode$Standard, originX = NA, originY = NA, locationSeed = 1L, numberOfTrails = 50L, getGateCounts = FALSE, verbose = FALSE )
mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) pointMap <- makeVGAPointMap( sfMap, gridSize = 0.5, fillX = 3.0, fillY = 6.0, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE ) agentAnalysis( pointMap, timesteps = 3000L, releaseRate = 0.1, agentStepsToDecision = 3L, agentFov = 11L, agentLife = 1000L, agentLookMode = AgentLookMode$Standard, originX = NA, originY = NA, locationSeed = 1L, numberOfTrails = 50L, getGateCounts = FALSE, verbose = FALSE )
These are meant to be used to indicate what kind of look function the agents use to look around and decide where to go next. Possible values:
AgentLookMode$None
AgentLookMode$Standard
AgentLookMode$LineOfSightLength
AgentLookMode$OcclusionLength
AgentLookMode$OcclusionAny
AgentLookMode$OcclusionGroup45 (Occlusion group bins - 45 degrees)
AgentLookMode$OcclusionGroup60 (Occlusion group bins - 60 degrees)
AgentLookMode$OcclusionFurthest (Furthest occlusion per bin)
AgentLookMode$BinFarDistance (Per bin far distance weighted)
AgentLookMode$BinAngle (Per bin angle weighted)
AgentLookMode$BinFarDistanceAngle (Per bin far-distance and angle weighted)
AgentLookMode$BinMemory (Per bin memory)
AgentLookMode
AgentLookMode
An object of class list
of length 12.
A list of numbers representing each agent look mode
AgentLookMode$Standard AgentLookMode$LineOfSightLength AgentLookMode$OcclusionAny
AgentLookMode$Standard AgentLookMode$LineOfSightLength AgentLookMode$OcclusionAny
A representation of sala's All-line ShapeGraph in R. Holds onto a sala All-line ShapeGraph pointer and operates on that
Runs all-to-all traversal on a map with a graph. This is applicable to:
PointMaps (Visibility Graph Analysis)
Axial ShapeGraphs (Axial analysis)
Segment ShapeGraphs (Segment analysis)
allToAllTraverse( map, traversalType, radii, radiusTraversalType, weightByAttribute = NULL, includeBetweenness = FALSE, quantizationWidth = NA, gatesOnly = FALSE, nthreads = 1L, copyMap = TRUE, verbose = FALSE, progress = FALSE )
allToAllTraverse( map, traversalType, radii, radiusTraversalType, weightByAttribute = NULL, includeBetweenness = FALSE, quantizationWidth = NA, gatesOnly = FALSE, nthreads = 1L, copyMap = TRUE, verbose = FALSE, progress = FALSE )
map |
A PointMap, Axial ShapeGraph or Segment ShapeGraph |
traversalType |
The traversal type. See TraversalType |
radii |
A list of radii |
radiusTraversalType |
The traversal type to keep track of whether the analysis is within the each radius limit. See TraversalType |
weightByAttribute |
The attribute to weigh the analysis with |
includeBetweenness |
Set to TRUE to also calculate betweenness (known as Choice in the Space Syntax domain) |
quantizationWidth |
Set this to use chunks of this width instead of continuous values for the cost of traversal. This is equivalent to the "tulip bins" for depthmapX's tulip analysis (1024 tulip bins = pi/1024 quantizationWidth). Only works for Segment ShapeGraphs |
gatesOnly |
Optional. Only calculate results at particular gate pixels. Only works for PointMaps |
nthreads |
Optional. Use more than one threads. 1 by default, set to 0 to use all available. Only available for PointMaps. |
copyMap |
Optional. Copy the internal sala map |
verbose |
Optional. Show more information of the process. |
progress |
Optional. Enable progress display |
A new map with the results included
# Pointmap analysis (VGA) mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) pointMap <- makeVGAPointMap( sfMap, gridSize = 0.5, fillX = 3.0, fillY = 6.0, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE ) allToAllTraverse(pointMap, traversalType = TraversalType$Angular, radii = -1L, radiusTraversalType = TraversalType$None ) # Axial analysis 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") allToAllTraverse( shapeGraph, traversalType = TraversalType$Topological, radii = c("n", "3"), includeBetweenness = TRUE ) # Segment analysis mifFile <- system.file( "extdata", "testdata", "barnsbury", "barnsbury_small_segment_original.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) shapeGraph <- as(sfMap, "SegmentShapeGraph") allToAllTraverse( shapeGraph, radii = c("n", "100"), radiusTraversalType = TraversalType$Metric, traversalType = TraversalType$Angular, weightByAttribute = "Segment Length", includeBetweenness = TRUE, quantizationWidth = pi / 1024L, verbose = FALSE, progress = FALSE )
# Pointmap analysis (VGA) mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) pointMap <- makeVGAPointMap( sfMap, gridSize = 0.5, fillX = 3.0, fillY = 6.0, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE ) allToAllTraverse(pointMap, traversalType = TraversalType$Angular, radii = -1L, radiusTraversalType = TraversalType$None ) # Axial analysis 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") allToAllTraverse( shapeGraph, traversalType = TraversalType$Topological, radii = c("n", "3"), includeBetweenness = TRUE ) # Segment analysis mifFile <- system.file( "extdata", "testdata", "barnsbury", "barnsbury_small_segment_original.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) shapeGraph <- as(sfMap, "SegmentShapeGraph") allToAllTraverse( shapeGraph, radii = c("n", "100"), radiusTraversalType = TraversalType$Metric, traversalType = TraversalType$Angular, weightByAttribute = "Segment Length", includeBetweenness = TRUE, quantizationWidth = pi / 1024L, verbose = FALSE, progress = FALSE )
This is a direct conversion, for ShapeMap -> Axial -> Segment see axialToSegmentShapeGraph
This is a direct conversion, for ShapeMap -> Axial -> Segment see axialToSegmentShapeGraph
Other ShapeMap:
ShapeMap-class
Other ShapeMap:
ShapeMap-class
Other AxialShapeGraph:
AxialShapeGraph-class
Other AxialShapeGraph:
AxialShapeGraph-class
Other SegmentShapeGraph:
SegmentShapeGraph-class
Other SegmentShapeGraph:
SegmentShapeGraph-class
Runs axial analysis to get the local metrics Control and Controllability
axialAnalysisLocal(shapeGraph, copyMap = TRUE, verbose = FALSE)
axialAnalysisLocal(shapeGraph, copyMap = TRUE, verbose = FALSE)
shapeGraph |
An Axial ShapeGraph |
copyMap |
Optional. Copy the internal sala map |
verbose |
Optional. Show more information of the process. |
Returns a list with:
completed: Whether the analysis completed
newAttributes: The new attributes that were created during the process
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") axialAnalysisLocal(shapeGraph)
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") axialAnalysisLocal(shapeGraph)
Subsetting AxialShapeGraph objects essentially passes the data to sf. See sf
## S3 method for class 'AxialShapeGraph' x[...] ## S3 replacement method for class 'AxialShapeGraph' x[...] <- value
## S3 method for class 'AxialShapeGraph' x[...] ## S3 replacement method for class 'AxialShapeGraph' x[...] <- value
x |
object of class |
... |
other parameters passed to |
value |
value to be passed to |
A representation of sala's Axial ShapeGraph in R. Holds onto a sala Axial ShapeGraph pointer and operates on that
Other AxialShapeGraph:
as()
Convert an Axial ShapeGraph to a Segment ShapeGraph
axialToSegmentShapeGraph(axialShapeGraph, stubRemoval = NULL)
axialToSegmentShapeGraph(axialShapeGraph, stubRemoval = NULL)
axialShapeGraph |
An Axial ShapeGraph |
stubRemoval |
Remove stubs of axial lines shorter than this percentage (for example provide 0.4 for 40%) |
A new Segment ShapeGraph
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") axialToSegmentShapeGraph(shapeGraph, stubRemoval = 0.4)
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") axialToSegmentShapeGraph(shapeGraph, stubRemoval = 0.4)
Takes a PointMap and a ShapeMap with lines and blocks the cells on the PointMap where the lines pass.
blockLines(pointMap, lineStringMap, copyMap = TRUE, verbose = FALSE)
blockLines(pointMap, lineStringMap, copyMap = TRUE, verbose = FALSE)
pointMap |
The input PointMap |
lineStringMap |
Map of lines, either a ShapeMap, or an sf lineString map |
copyMap |
Optional. Copy the internal sala map |
verbose |
Optional. Show more information of the process. |
A new PointMap with points as they have been blocked by the lines
mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) shapeMap <- as(sfMap[, vector()], "ShapeMap") lineStringMap <- as(sfMap, "sf") mapRegion <- sf::st_bbox(lineStringMap) pointMap <- createGrid( minX = mapRegion[["xmin"]], minY = mapRegion[["ymin"]], maxX = mapRegion[["xmax"]], maxY = mapRegion[["ymax"]], gridSize = 0.04 ) blockLines( pointMap = pointMap, lineStringMap = lineStringMap[vector()] )
mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) shapeMap <- as(sfMap[, vector()], "ShapeMap") lineStringMap <- as(sfMap, "sf") mapRegion <- sf::st_bbox(lineStringMap) pointMap <- createGrid( minX = mapRegion[["xmin"]], minY = mapRegion[["ymin"]], maxX = mapRegion[["xmax"]], maxY = mapRegion[["ymax"]], gridSize = 0.04 ) blockLines( pointMap = pointMap, lineStringMap = lineStringMap[vector()] )
Get map connections
connections(map)
connections(map)
map |
A sala map |
A matrix with the connected refs
Get the Axial ShapeGraph connections
## S4 method for signature 'AxialShapeGraph' connections(map)
## S4 method for signature 'AxialShapeGraph' connections(map)
map |
An Axial ShapeGraph |
A matrix with the connected refs
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") connections(shapeGraph)
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") connections(shapeGraph)
Get the PointMap connections
## S4 method for signature 'PointMap' connections(map)
## S4 method for signature 'PointMap' connections(map)
map |
A PointMap |
A matrix with the connected refs
mifFile <- system.file( "extdata", "testdata", "gallery", "gallery_lines.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) pointMap <- makeVGAPointMap( sfMap, gridSize = 0.04, fillX = 3.01, fillY = 6.7, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE ) # plot the first 100 connections only head(connections(pointMap), 100)
mifFile <- system.file( "extdata", "testdata", "gallery", "gallery_lines.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) pointMap <- makeVGAPointMap( sfMap, gridSize = 0.04, fillX = 3.01, fillY = 6.7, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE ) # plot the first 100 connections only head(connections(pointMap), 100)
Get the Segment ShapeGraph connections
## S4 method for signature 'SegmentShapeGraph' connections(map)
## S4 method for signature 'SegmentShapeGraph' connections(map)
map |
An Segment ShapeGraph |
A matrix with the connected refs
mifFile <- system.file( "extdata", "testdata", "barnsbury", "barnsbury_small_segment_original.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) shapeGraph <- as(sfMap, "SegmentShapeGraph") connections(shapeGraph)
mifFile <- system.file( "extdata", "testdata", "barnsbury", "barnsbury_small_segment_original.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) shapeGraph <- as(sfMap, "SegmentShapeGraph") connections(shapeGraph)
Create a PointMap through a grid
createGrid(minX, minY, maxX, maxY, gridSize, verbose = FALSE)
createGrid(minX, minY, maxX, maxY, gridSize, verbose = FALSE)
minX |
Minimum X of the bounding region |
minY |
Minimum Y of the bounding region |
maxX |
Maximum X of the bounding region |
maxY |
Maximum Y of the bounding region |
gridSize |
Size of the cells |
verbose |
Optional. Show more information of the process. |
A new PointMap
mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) shapeMap <- as(sfMap[, vector()], "ShapeMap") lineStringMap <- as(sfMap, "sf") mapRegion <- sf::st_bbox(lineStringMap) createGrid( minX = mapRegion[["xmin"]], minY = mapRegion[["ymin"]], maxX = mapRegion[["xmax"]], maxY = mapRegion[["ymax"]], gridSize = 0.04 )
mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) shapeMap <- as(sfMap[, vector()], "ShapeMap") lineStringMap <- as(sfMap, "sf") mapRegion <- sf::st_bbox(lineStringMap) createGrid( minX = mapRegion[["xmin"]], minY = mapRegion[["ymin"]], maxX = mapRegion[["xmax"]], maxY = mapRegion[["ymax"]], gridSize = 0.04 )
Fill a PointMap's grid starting from one or more points
fillGrid(pointMap, fillX, fillY, copyMap = TRUE, verbose = FALSE)
fillGrid(pointMap, fillX, fillY, copyMap = TRUE, verbose = FALSE)
pointMap |
The input PointMap |
fillX |
X coordinate of the fill points |
fillY |
Y coordinate of the fill points |
copyMap |
Optional. Copy the internal sala map |
verbose |
Optional. Show more information of the process. |
A new PointMap with filled points
mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) shapeMap <- as(sfMap[, vector()], "ShapeMap") lineStringMap <- as(sfMap, "sf") mapRegion <- sf::st_bbox(lineStringMap) pointMap <- createGrid( minX = mapRegion[["xmin"]], minY = mapRegion[["ymin"]], maxX = mapRegion[["xmax"]], maxY = mapRegion[["ymax"]], gridSize = 0.04 ) pointMap <- blockLines( pointMap = pointMap, lineStringMap = lineStringMap[vector()] ) fillGrid( pointMap = pointMap, fillX = 3.01, fillY = 6.7 )
mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) shapeMap <- as(sfMap[, vector()], "ShapeMap") lineStringMap <- as(sfMap, "sf") mapRegion <- sf::st_bbox(lineStringMap) pointMap <- createGrid( minX = mapRegion[["xmin"]], minY = mapRegion[["ymin"]], maxX = mapRegion[["xmax"]], maxY = mapRegion[["ymax"]], gridSize = 0.04 ) pointMap <- blockLines( pointMap = pointMap, lineStringMap = lineStringMap[vector()] ) fillGrid( pointMap = pointMap, fillX = 3.01, fillY = 6.7 )
Sorts features by a specific column and extracts the top x percent
getTopFeatures(lineStringMap, column, percent)
getTopFeatures(lineStringMap, column, percent)
lineStringMap |
An sf lineString map |
column |
The column to use to extract the features from |
percent |
Percentage of features (to total) to extract |
The lineString map filtered and sorted
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)
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)
Create one or more isovists at particular points, given angle and field of view
isovist(boundaryMap, x, y, angle = NA, viewAngle = NA, verbose = FALSE)
isovist(boundaryMap, x, y, angle = NA, viewAngle = NA, verbose = FALSE)
boundaryMap |
A ShapeMap with lines designating the isovist boundaries |
x |
X coordinate of the origin points |
y |
Y coordinate of the origin points |
angle |
The angle (from the X axis) of the isovist look direction |
viewAngle |
The angle signifying the isovist's field of view |
verbose |
Optional. Show more information of the process. |
A ShapeMap with the isovist polygons
mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) shapeMap <- as(sfMap[, vector()], "ShapeMap") isovist( shapeMap, x = c(3.01, 1.3), y = c(6.70, 5.2), angle = 0.01, viewAngle = 3.14, FALSE )
mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) shapeMap <- as(sfMap[, vector()], "ShapeMap") isovist( shapeMap, x = c(3.01, 1.3), y = c(6.70, 5.2), angle = 0.01, viewAngle = 3.14, FALSE )
Create one or more isovists at particular points, given another point for direction and an angle for field of view
isovist2pts(boundaryMap, x, y, toX, toY, viewAngle, verbose = FALSE)
isovist2pts(boundaryMap, x, y, toX, toY, viewAngle, verbose = FALSE)
boundaryMap |
A ShapeMap with lines designating the isovist boundaries |
x |
X coordinate of the origin points |
y |
Y coordinate of the origin points |
toX |
X coordinate of the target points |
toY |
Y coordinate of the target points |
viewAngle |
The angle signifying the isovist's field of view |
verbose |
Optional. Show more information of the process. |
A ShapeMap with the isovist polygons
mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) shapeMap <- as(sfMap[, vector()], "ShapeMap") isovist2pts( shapeMap, x = c(3.01, 1.3), y = c(6.70, 5.2), toX = c(3.40, 1.1), toY = c(6.50, 5.6), viewAngle = 3.14, FALSE )
mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) shapeMap <- as(sfMap[, vector()], "ShapeMap") isovist2pts( shapeMap, x = c(3.01, 1.3), y = c(6.70, 5.2), toX = c(3.40, 1.1), toY = c(6.50, 5.6), viewAngle = 3.14, FALSE )
Link map points/lines as if selecting them using points
linkCoords(map, fromX, fromY, toX, toY, copyMap = TRUE)
linkCoords(map, fromX, fromY, toX, toY, copyMap = TRUE)
map |
A sala map |
fromX |
X coordinate of the origin point |
fromY |
Y coordinate of the origin point |
toX |
X coordinate of the target point |
toY |
Y coordinate of the target point |
copyMap |
Optional. Copy the internal sala map |
A new map with linked points/lines
Link two locations on an Axial ShapeGraph using the point coordinates
## S4 method for signature 'AxialShapeGraph' linkCoords(map, fromX, fromY, toX, toY, copyMap = TRUE)
## S4 method for signature 'AxialShapeGraph' linkCoords(map, fromX, fromY, toX, toY, copyMap = TRUE)
map |
An Axial ShapeGraph |
fromX |
X coordinate of the first link point |
fromY |
Y coordinate of the first link point |
toX |
X coordinate of the second link point |
toY |
Y coordinate of the second link point |
copyMap |
Optional. Copy the internal sala map |
A new Axial ShapeGraph with linked lines
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") linkCoords(shapeGraph, 982.8, -1620.3, 1217.1, -1977.3)
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") linkCoords(shapeGraph, 982.8, -1620.3, 1217.1, -1977.3)
Link two cells on a PointMap using the point coordinates
## S4 method for signature 'PointMap' linkCoords(map, fromX, fromY, toX, toY, copyMap = TRUE)
## S4 method for signature 'PointMap' linkCoords(map, fromX, fromY, toX, toY, copyMap = TRUE)
map |
A PointMap |
fromX |
X coordinate of the first link point |
fromY |
Y coordinate of the first link point |
toX |
X coordinate of the second link point |
toY |
Y coordinate of the second link point |
copyMap |
Optional. Copy the internal sala map |
A new PointMap with linked points
mifFile <- system.file( "extdata", "testdata", "gallery", "gallery_lines.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) pointMap <- makeVGAPointMap( sfMap, gridSize = 0.04, fillX = 3.01, fillY = 6.7, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE ) linkCoords(pointMap, 1.74, 6.7, 5.05, 5.24)
mifFile <- system.file( "extdata", "testdata", "gallery", "gallery_lines.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) pointMap <- makeVGAPointMap( sfMap, gridSize = 0.04, fillX = 3.01, fillY = 6.7, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE ) linkCoords(pointMap, 1.74, 6.7, 5.05, 5.24)
Link map points/lines using their refs
linkRefs(map, fromRef, toRef, copyMap = TRUE)
linkRefs(map, fromRef, toRef, copyMap = TRUE)
map |
A sala map |
fromRef |
The ref of the origin element |
toRef |
The ref of the target element |
copyMap |
Optional. Copy the internal sala map |
A new map with linked points/lines
Link two lines on an Axial ShapeGraph using their refs
## S4 method for signature 'AxialShapeGraph' linkRefs(map, fromRef, toRef, copyMap = TRUE)
## S4 method for signature 'AxialShapeGraph' linkRefs(map, fromRef, toRef, copyMap = TRUE)
map |
An Axial ShapeGraph |
fromRef |
Ref of the first link line |
toRef |
Ref of the second link line |
copyMap |
Optional. Copy the internal sala map |
A new Axial ShapeGraph with linked lines
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") linkRefs(shapeGraph, 0L, 9L)
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") linkRefs(shapeGraph, 0L, 9L)
Link two cells on an PointMap using their refs
## S4 method for signature 'PointMap' linkRefs(map, fromRef, toRef, copyMap = TRUE)
## S4 method for signature 'PointMap' linkRefs(map, fromRef, toRef, copyMap = TRUE)
map |
A PointMap |
fromRef |
Ref of the first link line |
toRef |
Ref of the second link line |
copyMap |
Optional. Copy the internal sala map |
A new PointMap with linked points
mifFile <- system.file( "extdata", "testdata", "gallery", "gallery_lines.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) pointMap <- makeVGAPointMap( sfMap, gridSize = 0.04, fillX = 3.01, fillY = 6.7, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE ) pointMap <- linkRefs(pointMap, 1835056L, 7208971L)
mifFile <- system.file( "extdata", "testdata", "gallery", "gallery_lines.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) pointMap <- makeVGAPointMap( sfMap, gridSize = 0.04, fillX = 3.01, fillY = 6.7, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE ) pointMap <- linkRefs(pointMap, 1835056L, 7208971L)
Get map links
links(map)
links(map)
map |
A sala map |
A matrix with the linked refs
Get the Axial ShapeGraph links
## S4 method for signature 'AxialShapeGraph' links(map)
## S4 method for signature 'AxialShapeGraph' links(map)
map |
An Axial ShapeGraph |
A matrix with the linked refs
# links of an axial map 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") linkRefs(shapeGraph, 0L, 9L) unlinkCoords(shapeGraph, 530923.0, 184041.0, 530956.0, 183887.0) links(shapeGraph)
# links of an axial map 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") linkRefs(shapeGraph, 0L, 9L) unlinkCoords(shapeGraph, 530923.0, 184041.0, 530956.0, 183887.0) links(shapeGraph)
Get the PointMap links
## S4 method for signature 'PointMap' links(map)
## S4 method for signature 'PointMap' links(map)
map |
A PointMap |
A matrix with the linked refs
mifFile <- system.file( "extdata", "testdata", "gallery", "gallery_lines.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) pointMap <- makeVGAPointMap( sfMap, gridSize = 0.04, fillX = 3.01, fillY = 6.7, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE ) linkRefs(pointMap, 1835056L, 7208971L) links(pointMap)
mifFile <- system.file( "extdata", "testdata", "gallery", "gallery_lines.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) pointMap <- makeVGAPointMap( sfMap, gridSize = 0.04, fillX = 3.01, fillY = 6.7, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE ) linkRefs(pointMap, 1835056L, 7208971L) links(pointMap)
Create an All-line Map
makeAllLineMap(boundsMap, seedX, seedY, verbose = FALSE)
makeAllLineMap(boundsMap, seedX, seedY, verbose = FALSE)
boundsMap |
The boundary ShapeMap to create the all-line map in |
seedX |
X coordinate of the seed (the point that initiates the process) |
seedY |
Y coordinate of the seed (the point that initiates the process) |
verbose |
Optional. Show more information of the process. |
An All-line Axial ShapeGraph
mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) shapeMap <- as(sfMap[, vector()], "ShapeMap") makeAllLineMap( shapeMap, seedX = 3.01, seedY = 6.7 )
mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) shapeMap <- as(sfMap[, vector()], "ShapeMap") makeAllLineMap( shapeMap, seedX = 3.01, seedY = 6.7 )
Create a single colour from depthmapX's palettes.
makeDepthmapClassicColour(value, rangeMin = 0, rangeMax = 1) makeAxmanesqueColour(value, rangeMin = 0, rangeMax = 1) makePurpleOrangeColour(value, rangeMin = 0, rangeMax = 1) makeBlueRedColour(value, rangeMin = 0, rangeMax = 1) makeGreyScaleColour(value, rangeMin = 0, rangeMax = 1) makeNiceHSBColour(value, rangeMin = 0, rangeMax = 1)
makeDepthmapClassicColour(value, rangeMin = 0, rangeMax = 1) makeAxmanesqueColour(value, rangeMin = 0, rangeMax = 1) makePurpleOrangeColour(value, rangeMin = 0, rangeMax = 1) makeBlueRedColour(value, rangeMin = 0, rangeMax = 1) makeGreyScaleColour(value, rangeMin = 0, rangeMax = 1) makeNiceHSBColour(value, rangeMin = 0, rangeMax = 1)
value |
Value within the min/max range to take |
rangeMin |
The min value of the range |
rangeMax |
The max value of the range |
Returns a single colour.
makeDepthmapClassicColour(0.2, 0, 1) makeAxmanesqueColour(0.2, 0, 1) makePurpleOrangeColour(0.2, 0, 1) makeBlueRedColour(0.2, 0, 1) makeGreyScaleColour(0.2, 0, 1) makeNiceHSBColour(0.2, 0, 1)
makeDepthmapClassicColour(0.2, 0, 1) makeAxmanesqueColour(0.2, 0, 1) makePurpleOrangeColour(0.2, 0, 1) makeBlueRedColour(0.2, 0, 1) makeGreyScaleColour(0.2, 0, 1) makeNiceHSBColour(0.2, 0, 1)
Create a graph between visible cells in the PointMap
makeVGAGraph( pointMap, boundaryGraph = FALSE, maxVisibility = NA, copyMap = TRUE, verbose = FALSE )
makeVGAGraph( pointMap, boundaryGraph = FALSE, maxVisibility = NA, copyMap = TRUE, verbose = FALSE )
pointMap |
The input PointMap |
boundaryGraph |
Only create a graph on the boundary cells |
maxVisibility |
Limit how far two cells can be to be connected |
copyMap |
Optional. Copy the internal sala map |
verbose |
Optional. Show more information of the process. |
A new PointMap with a graph between points
mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) shapeMap <- as(sfMap[, vector()], "ShapeMap") lineStringMap <- as(sfMap, "sf") mapRegion <- sf::st_bbox(lineStringMap) pointMap <- createGrid( minX = mapRegion[["xmin"]], minY = mapRegion[["ymin"]], maxX = mapRegion[["xmax"]], maxY = mapRegion[["ymax"]], gridSize = 0.5 ) pointMap <- blockLines( pointMap = pointMap, lineStringMap = lineStringMap[vector()] ) pointMap <- fillGrid( pointMap = pointMap, fillX = 3.01, fillY = 6.7 ) makeVGAGraph( pointMap = pointMap, boundaryGraph = FALSE, maxVisibility = NA )
mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) shapeMap <- as(sfMap[, vector()], "ShapeMap") lineStringMap <- as(sfMap, "sf") mapRegion <- sf::st_bbox(lineStringMap) pointMap <- createGrid( minX = mapRegion[["xmin"]], minY = mapRegion[["ymin"]], maxX = mapRegion[["xmax"]], maxY = mapRegion[["ymax"]], gridSize = 0.5 ) pointMap <- blockLines( pointMap = pointMap, lineStringMap = lineStringMap[vector()] ) pointMap <- fillGrid( pointMap = pointMap, fillX = 3.01, fillY = 6.7 ) makeVGAGraph( pointMap = pointMap, boundaryGraph = FALSE, maxVisibility = NA )
This is intended to be a single command to get from the lines to a PointMap ready for analysis
makeVGAPointMap( lineStringMap, gridSize, fillX, fillY, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE )
makeVGAPointMap( lineStringMap, gridSize, fillX, fillY, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE )
lineStringMap |
Map of lines, either a ShapeMap, or an sf lineString map |
gridSize |
Size of the cells |
fillX |
X coordinate of the fill points |
fillY |
Y coordinate of the fill points |
maxVisibility |
Limit how far two cells can be to be connected |
boundaryGraph |
Only create a graph on the boundary cells |
verbose |
Optional. Show more information of the process. |
A new PointMap
mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) shapeMap <- as(sfMap[, vector()], "ShapeMap") makeVGAPointMap( sfMap, gridSize = 0.5, fillX = 3.01, fillY = 6.7, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE )
mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) shapeMap <- as(sfMap[, vector()], "ShapeMap") makeVGAPointMap( sfMap, gridSize = 0.5, fillX = 3.01, fillY = 6.7, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE )
Match points to their closest line. Matches (spatial-join) points to lines. Finds the point closest to a line. One point is attached to one line, thus if fewer points than lines are given then some lines will have no point attached.
matchPointsToLines(points, lines, getIndex = FALSE)
matchPointsToLines(points, lines, getIndex = FALSE)
points |
Points to attach. |
lines |
Lines to attach to. |
getIndex |
Get the index returned and not the data. |
If getIndex is TRUE then the index of the points as they relate to the matching lines are given. If not, then the data from the points dataframe is returned.
segmentsMif <- system.file( "extdata", "testdata", "barnsbury", "barnsbury_small_segment_original.mif", package = "alcyon" ) segmentsSf <- st_read( segmentsMif, geometry_column = 1L, quiet = TRUE ) gateCountsMif <- system.file( "extdata", "testdata", "barnsbury", "barnsbury_ped_gatecounts.mif", package = "alcyon" ) gateCountsSf <- st_read( gateCountsMif, geometry_column = 1L, quiet = TRUE ) matchPointsToLines(gateCountsSf, segmentsSf)
segmentsMif <- system.file( "extdata", "testdata", "barnsbury", "barnsbury_small_segment_original.mif", package = "alcyon" ) segmentsSf <- st_read( segmentsMif, geometry_column = 1L, quiet = TRUE ) gateCountsMif <- system.file( "extdata", "testdata", "barnsbury", "barnsbury_ped_gatecounts.mif", package = "alcyon" ) gateCountsSf <- st_read( gateCountsMif, geometry_column = 1L, quiet = TRUE ) matchPointsToLines(gateCountsSf, segmentsSf)
Get map name
name(map)
name(map)
map |
A sala map |
The name of the object as a string
Get the PointMap name
## S4 method for signature 'PointMap' name(map)
## S4 method for signature 'PointMap' name(map)
map |
A PointMap |
The name of the PointMap as a string
mifFile <- system.file( "extdata", "testdata", "gallery", "gallery_lines.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) pointMap <- makeVGAPointMap( sfMap, gridSize = 0.04, fillX = 3.01, fillY = 6.7, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE ) name(pointMap)
mifFile <- system.file( "extdata", "testdata", "gallery", "gallery_lines.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) pointMap <- makeVGAPointMap( sfMap, gridSize = 0.04, fillX = 3.01, fillY = 6.7, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE ) name(pointMap)
Get the ShapeMap name
## S4 method for signature 'ShapeMap' name(map)
## S4 method for signature 'ShapeMap' name(map)
map |
A ShapeMap |
The name of the ShapeMap as a string
mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) shapeMap <- as(sfMap[, vector()], "ShapeMap") name(shapeMap)
mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) shapeMap <- as(sfMap[, vector()], "ShapeMap") name(shapeMap)
Runs one-to-all traversal on a map with a graph. This is applicable to:
PointMaps (Visibility Graph Analysis)
Axial ShapeGraphs (Axial analysis)
Segment ShapeGraphs (Segment analysis)
oneToAllTraverse( map, traversalType, fromX, fromY, quantizationWidth = NA, copyMap = TRUE, verbose = FALSE )
oneToAllTraverse( map, traversalType, fromX, fromY, quantizationWidth = NA, copyMap = TRUE, verbose = FALSE )
map |
A PointMap, Axial ShapeGraph or Segment ShapeGraph |
traversalType |
The traversal type. See TraversalType |
fromX |
X coordinate of the point to start the traversal from |
fromY |
X coordinate of the point to start the traversal from |
quantizationWidth |
Set this to use chunks of this width instead of continuous values for the cost of traversal. This is equivalent to the "tulip bins" for depthmapX's tulip analysis (1024 tulip bins = pi/1024 quantizationWidth). Only works for Segment ShapeGraphs |
copyMap |
Optional. Copy the internal sala map |
verbose |
Optional. Show more information of the process. |
Returns a list with:
completed: Whether the analysis completed
newAttributes: The new attributes that were created during the process
# Pointmap analysis (VGA) mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) pointMap <- makeVGAPointMap( sfMap, gridSize = 0.5, fillX = 3.0, fillY = 6.0, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE ) oneToAllTraverse( pointMap, traversalType = TraversalType$Metric, fromX = 3.01, fromY = 6.7 ) # Axial analysis 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") oneToAllTraverse( shapeGraph, traversalType = TraversalType$Topological, fromX = 1217.1, fromY = -1977.3 ) # Segment analysis mifFile <- system.file( "extdata", "testdata", "barnsbury", "barnsbury_small_segment_original.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) shapeGraph <- as(sfMap, "SegmentShapeGraph") oneToAllTraverse( shapeGraph, traversalType = TraversalType$Topological, fromX = 1217.1, fromY = -1977.3 )
# Pointmap analysis (VGA) mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) pointMap <- makeVGAPointMap( sfMap, gridSize = 0.5, fillX = 3.0, fillY = 6.0, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE ) oneToAllTraverse( pointMap, traversalType = TraversalType$Metric, fromX = 3.01, fromY = 6.7 ) # Axial analysis 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") oneToAllTraverse( shapeGraph, traversalType = TraversalType$Topological, fromX = 1217.1, fromY = -1977.3 ) # Segment analysis mifFile <- system.file( "extdata", "testdata", "barnsbury", "barnsbury_small_segment_original.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) shapeGraph <- as(sfMap, "SegmentShapeGraph") oneToAllTraverse( shapeGraph, traversalType = TraversalType$Topological, fromX = 1217.1, fromY = -1977.3 )
Runs one-to-one traversal on a map with a graph. This is applicable to:
PointMaps (Visibility Graph Analysis)
Segment ShapeGraphs (Segment analysis)
oneToOneTraverse( map, traversalType, fromX, fromY, toX, toY, quantizationWidth = NA, copyMap = TRUE, verbose = FALSE )
oneToOneTraverse( map, traversalType, fromX, fromY, toX, toY, quantizationWidth = NA, copyMap = TRUE, verbose = FALSE )
map |
A PointMap or Segment ShapeGraph |
traversalType |
The traversal type. See TraversalType |
fromX |
X coordinate of the point(s) to start the traversal from |
fromY |
X coordinate of the point(s) to start the traversal from |
toX |
X coordinate of the point(s) to start the traversal from |
toY |
X coordinate of the point(s) to start the traversal from |
quantizationWidth |
Set this to use chunks of this width instead of continuous values for the cost of traversal. This is equivalent to the "tulip bins" for depthmapX's tulip analysis (1024 tulip bins = pi/1024 quantizationWidth). Only works for Segment ShapeGraphs |
copyMap |
Optional. Copy the internal sala map |
verbose |
Optional. Show more information of the process. |
Returns a list with:
completed: Whether the analysis completed
newAttributes: The new attributes that were created during the process
# Pointmap analysis (VGA) mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) pointMap <- makeVGAPointMap( sfMap, gridSize = 0.5, fillX = 3.0, fillY = 6.0, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE ) oneToOneTraverse( pointMap, traversalType = TraversalType$Metric, fromX = 7.52, fromY = 6.02, toX = 5.78, toY = 2.96 ) # Segment analysis mifFile <- system.file( "extdata", "testdata", "barnsbury", "barnsbury_small_segment_original.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) shapeGraph <- as(sfMap, "SegmentShapeGraph") oneToOneTraverse( shapeGraph, traversalType = TraversalType$Topological, fromX = 1217.1, fromY = -1977.3, toX = 1017.8, toY = -1699.3 )
# Pointmap analysis (VGA) mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) pointMap <- makeVGAPointMap( sfMap, gridSize = 0.5, fillX = 3.0, fillY = 6.0, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE ) oneToOneTraverse( pointMap, traversalType = TraversalType$Metric, fromX = 7.52, fromY = 6.02, toX = 5.78, toY = 2.96 ) # Segment analysis mifFile <- system.file( "extdata", "testdata", "barnsbury", "barnsbury_small_segment_original.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) shapeGraph <- as(sfMap, "SegmentShapeGraph") oneToOneTraverse( shapeGraph, traversalType = TraversalType$Topological, fromX = 1217.1, fromY = -1977.3, toX = 1017.8, toY = -1699.3 )
Create n contiguous colours taken from depthmapX.
depthmap.classic.colour(n, rangeMin = 0, rangeMax = 1) depthmap.axmanesque.colour(n, rangeMin = 0, rangeMax = 1) depthmap.purpleorange.colour(n, rangeMin = 0, rangeMax = 1) depthmap.bluered.colour(n, rangeMin = 0, rangeMax = 1) depthmap.grayscale.colour(n, rangeMin = 0, rangeMax = 1) depthmap.nicehsb.colour(n, rangeMin = 0, rangeMax = 1)
depthmap.classic.colour(n, rangeMin = 0, rangeMax = 1) depthmap.axmanesque.colour(n, rangeMin = 0, rangeMax = 1) depthmap.purpleorange.colour(n, rangeMin = 0, rangeMax = 1) depthmap.bluered.colour(n, rangeMin = 0, rangeMax = 1) depthmap.grayscale.colour(n, rangeMin = 0, rangeMax = 1) depthmap.nicehsb.colour(n, rangeMin = 0, rangeMax = 1)
n |
Number of colours to generate |
rangeMin |
The min value of the range |
rangeMax |
The max value of the range |
Returns a vector of colours.
depthmap.classic.colour(100, 0, 1) depthmap.axmanesque.colour(100, 0, 1) depthmap.purpleorange.colour(100, 0, 1) depthmap.bluered.colour(100, 0, 1) depthmap.grayscale.colour(100, 0, 1) depthmap.nicehsb.colour(100, 0, 1)
depthmap.classic.colour(100, 0, 1) depthmap.axmanesque.colour(100, 0, 1) depthmap.purpleorange.colour(100, 0, 1) depthmap.bluered.colour(100, 0, 1) depthmap.grayscale.colour(100, 0, 1) depthmap.nicehsb.colour(100, 0, 1)
Calls a standard plot.stars, but flips the first argument around the x axis
## S3 method for class 'PointMap' plot(x, ...)
## S3 method for class 'PointMap' plot(x, ...)
x |
object of class |
... |
other parameters passed to |
Subsetting PointMap objects essentially passes the data to stars See stars_subset
## S3 method for class 'PointMap' x[...] ## S3 replacement method for class 'PointMap' x[...] <- value
## S3 method for class 'PointMap' x[...] ## S3 replacement method for class 'PointMap' x[...] <- value
x |
object of class |
... |
other parameters passed to |
value |
value to be passed to |
A representation of sala's PointMap in R. Holds onto a sala PointMap pointer and operates on that
Reads a metagraph into a bunch of ShapeMaps/ShapeGraphs/PointMaps
readMetaGraph(fileName)
readMetaGraph(fileName)
fileName |
The metagraph file |
A list of ShapeMaps, ShapeGraphs and PointMaps
fileName <- system.file( "extdata", "testdata", "barnsbury", "barnsburySmall.graph", package = "alcyon" ) readMetaGraph(fileName)
fileName <- system.file( "extdata", "testdata", "barnsbury", "barnsburySmall.graph", package = "alcyon" ) readMetaGraph(fileName)
Reduce an All-line Map to two types of fewest-line maps
reduceToFewest(allLineMap)
reduceToFewest(allLineMap)
allLineMap |
An AllLineShapeGraph |
A list with two fewest-line axial ShapeGraphs
mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) shapeMap <- as(sfMap[, vector()], "ShapeMap") allLineMap <- makeAllLineMap( shapeMap, seedX = 3.01, seedY = 6.7 ) reduceToFewest(allLineMap)
mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) shapeMap <- as(sfMap[, vector()], "ShapeMap") allLineMap <- makeAllLineMap( shapeMap, seedX = 3.01, seedY = 6.7 ) reduceToFewest(allLineMap)
Converts a depthmapX "Ref" ID to the indices (x, y) of a cell, or the reverse
refIDtoIndex(refID) indexToRefID(i, j)
refIDtoIndex(refID) indexToRefID(i, j)
refID |
The Ref ID |
i |
The x-axis index of the cell |
j |
The y-axis index of the cell |
A pair of indices (x, y) or a Ref ID
idx <- refIDtoIndex(852645) # outputs: # i j # 1 13 677 idx <- indexToRefID(13, 667) # outputs: # 852645
idx <- refIDtoIndex(852645) # outputs: # i j # 1 13 677 idx <- indexToRefID(13, 667) # outputs: # 852645
Subsetting SegmentShapeGraph objects essentially passes the data to sf. See sf
## S3 method for class 'SegmentShapeGraph' x[...] ## S3 replacement method for class 'SegmentShapeGraph' x[...] <- value
## S3 method for class 'SegmentShapeGraph' x[...] ## S3 replacement method for class 'SegmentShapeGraph' x[...] <- value
x |
object of class |
... |
other parameters passed to |
value |
value to be passed to |
A representation of sala's Segment ShapeGraph in R. Holds onto a sala Segment ShapeGraph pointer and operates on that
Other SegmentShapeGraph:
as()
Creates data to be construct a graph, based on the connections and the x,y coordinates of the centroids of shapes in a shapegraph (axial, segment, convex). Specify weightColumn to assign weight to graph edges.
shapegraphToGraphData(shapeGraph, weightColumn = NA)
shapegraphToGraphData(shapeGraph, weightColumn = NA)
shapeGraph |
A ShapeGraph |
weightColumn |
Optional. The variable used to assign weight to graph edges |
If weightColumn is provided, edge connections weight is calculated by taking the average of the variable of the connected nodes.
Returns a list with edges and vertices for constructing a graph.
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") shapegraphToGraphData(shapeGraph)
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") shapegraphToGraphData(shapeGraph)
Subsetting ShapeMap objects essentially passes the data to sf. See sf
## S3 method for class 'ShapeMap' x[...] ## S3 replacement method for class 'ShapeMap' x[...] <- value
## S3 method for class 'ShapeMap' x[...] ## S3 replacement method for class 'ShapeMap' x[...] <- value
x |
object of class |
... |
other parameters passed to |
value |
value to be passed to |
A representation of sala's ShapeMap in R. Holds onto a sala ShapeMap pointer and operates on that
Other ShapeMap:
as()
Convert a ShapeMap to an sf Polygon map
shapeMapToPolygonSf(shapeMap)
shapeMapToPolygonSf(shapeMap)
shapeMap |
A ShapeMap |
A new sf Polygon map
mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) shapeMap <- as(sfMap[, vector()], "ShapeMap") isovistMap <- isovist( shapeMap, x = c(3.01, 1.3), y = c(6.70, 5.2), angle = 0.01, viewAngle = 3.14, FALSE ) shapeMapToPolygonSf(isovistMap)
mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) shapeMap <- as(sfMap[, vector()], "ShapeMap") isovistMap <- isovist( shapeMap, x = c(3.01, 1.3), y = c(6.70, 5.2), angle = 0.01, viewAngle = 3.14, FALSE ) shapeMapToPolygonSf(isovistMap)
These are meant to be used to indicate what kind of analysis is meant to be carried out.
TraversalType
TraversalType
An object of class list
of length 4.
A list of numbers representing each particular analysis type
TraversalType$Angular TraversalType$Topological TraversalType$Metric
TraversalType$Angular TraversalType$Topological TraversalType$Metric
Unlink map lines at their crossing point
unlinkAtCrossPoint(map, x, y, copyMap = TRUE)
unlinkAtCrossPoint(map, x, y, copyMap = TRUE)
map |
A sala map |
x |
X coordinate of the crossing point |
y |
Y coordinate of the crossing point |
copyMap |
Optional. Copy the internal sala map |
A new map with linked lines
Unlink two crossing lines on an Axial ShapeGraph at the crossing point
## S4 method for signature 'AxialShapeGraph' unlinkAtCrossPoint(map, x, y, copyMap = TRUE)
## S4 method for signature 'AxialShapeGraph' unlinkAtCrossPoint(map, x, y, copyMap = TRUE)
map |
An Axial ShapeGraph |
x |
X coordinate of the unlink crossing point |
y |
Y coordinate of the unlink crossing point |
copyMap |
Optional. Copy the internal sala map |
A new Axial ShapeGraph with unlinked lines
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") unlinkAtCrossPoint(shapeGraph, 530925.0, 184119.0)
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") unlinkAtCrossPoint(shapeGraph, 530925.0, 184119.0)
Unlink map points/lines as if selecting them using points
unlinkCoords(map, fromX, fromY, toX, toY, copyMap = TRUE)
unlinkCoords(map, fromX, fromY, toX, toY, copyMap = TRUE)
map |
A sala map |
fromX |
X coordinate of the origin point |
fromY |
Y coordinate of the origin point |
toX |
X coordinate of the target point |
toY |
Y coordinate of the target point |
copyMap |
Optional. Copy the internal sala map |
A new map with unlinked points/lines
Unlink two locations on an Axial ShapeGraph using the point coordinates
## S4 method for signature 'AxialShapeGraph' unlinkCoords(map, fromX, fromY, toX, toY, copyMap = TRUE)
## S4 method for signature 'AxialShapeGraph' unlinkCoords(map, fromX, fromY, toX, toY, copyMap = TRUE)
map |
An Axial ShapeGraph |
fromX |
X coordinate of the first unlink point |
fromY |
Y coordinate of the first unlink point |
toX |
X coordinate of the second unlink point |
toY |
Y coordinate of the second unlink point |
copyMap |
Optional. Copy the internal sala map |
A new Axial ShapeGraph with unlinked lines
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") unlinkCoords(shapeGraph, 982.8, -1620.3, 1080.4, -1873.5)
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") unlinkCoords(shapeGraph, 982.8, -1620.3, 1080.4, -1873.5)
Unlink two cells on a PointMap using the point coordinates
## S4 method for signature 'PointMap' unlinkCoords(map, fromX, fromY, toX, toY, copyMap = TRUE)
## S4 method for signature 'PointMap' unlinkCoords(map, fromX, fromY, toX, toY, copyMap = TRUE)
map |
A PointMap |
fromX |
X coordinate of the first unlink point |
fromY |
Y coordinate of the first unlink point |
toX |
X coordinate of the second unlink point |
toY |
Y coordinate of the second unlink point |
copyMap |
Optional. Copy the internal sala map |
A new PointMap with unlinked points
mifFile <- system.file( "extdata", "testdata", "gallery", "gallery_lines.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) pointMap <- makeVGAPointMap( sfMap, gridSize = 0.04, fillX = 3.01, fillY = 6.7, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE ) pointMap <- linkCoords(pointMap, 1.74, 6.7, 5.05, 5.24) pointMap <- unlinkCoords(pointMap, 1.74, 6.7, 5.05, 5.24)
mifFile <- system.file( "extdata", "testdata", "gallery", "gallery_lines.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) pointMap <- makeVGAPointMap( sfMap, gridSize = 0.04, fillX = 3.01, fillY = 6.7, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE ) pointMap <- linkCoords(pointMap, 1.74, 6.7, 5.05, 5.24) pointMap <- unlinkCoords(pointMap, 1.74, 6.7, 5.05, 5.24)
Unlink map points/lines using their refs
unlinkRefs(map, fromRef, toRef, copyMap = TRUE)
unlinkRefs(map, fromRef, toRef, copyMap = TRUE)
map |
A sala map |
fromRef |
The ref of the origin element |
toRef |
The ref of the target element |
copyMap |
Optional. Copy the internal sala map |
A new map with unlinked points/lines
Unlink two lines on an Axial ShapeGraph using their refs
## S4 method for signature 'AxialShapeGraph' unlinkRefs(map, fromRef, toRef, copyMap = TRUE)
## S4 method for signature 'AxialShapeGraph' unlinkRefs(map, fromRef, toRef, copyMap = TRUE)
map |
An Axial ShapeGraph |
fromRef |
Ref of the first unlink line |
toRef |
Ref of the second unlink line |
copyMap |
Optional. Copy the internal sala map |
A new Axial ShapeGraph with unlinked lines
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") unlinkRefs(shapeGraph, 12L, 34L)
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") unlinkRefs(shapeGraph, 12L, 34L)
Unlink two cells on an PointMap using their refs
## S4 method for signature 'PointMap' unlinkRefs(map, fromRef, toRef, copyMap = TRUE)
## S4 method for signature 'PointMap' unlinkRefs(map, fromRef, toRef, copyMap = TRUE)
map |
A PointMap |
fromRef |
Ref of the first unlink line |
toRef |
Ref of the second unlink line |
copyMap |
Optional. Copy the internal sala map |
A new PointMap with unlinked points
mifFile <- system.file( "extdata", "testdata", "gallery", "gallery_lines.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) pointMap <- makeVGAPointMap( sfMap, gridSize = 0.04, fillX = 3.01, fillY = 6.7, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE ) pointMap <- linkRefs(pointMap, 1835056L, 7208971L) pointMap <- unlinkRefs(pointMap, 1835056L, 7208971L)
mifFile <- system.file( "extdata", "testdata", "gallery", "gallery_lines.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) pointMap <- makeVGAPointMap( sfMap, gridSize = 0.04, fillX = 3.01, fillY = 6.7, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE ) pointMap <- linkRefs(pointMap, 1835056L, 7208971L) pointMap <- unlinkRefs(pointMap, 1835056L, 7208971L)
Unmake the graph in a PointMap
unmakeVGAGraph(pointMap, removeLinks = FALSE, copyMap = TRUE, verbose = FALSE)
unmakeVGAGraph(pointMap, removeLinks = FALSE, copyMap = TRUE, verbose = FALSE)
pointMap |
The input PointMap |
removeLinks |
Also remove the links |
copyMap |
Optional. Copy the internal sala map |
verbose |
Optional. Show more information of the process. |
A new PointMap without the points graph
mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) shapeMap <- as(sfMap[, vector()], "ShapeMap") pointMap <- makeVGAPointMap( sfMap, gridSize = 0.5, fillX = 3.01, fillY = 6.7, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE ) unmakeVGAGraph( pointMap = pointMap, removeLinks = FALSE )
mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) shapeMap <- as(sfMap[, vector()], "ShapeMap") pointMap <- makeVGAPointMap( sfMap, gridSize = 0.5, fillX = 3.01, fillY = 6.7, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE ) unmakeVGAGraph( pointMap = pointMap, removeLinks = FALSE )
Runs axial analysis to get the local metrics Control and Controllability
vgaIsovist(pointMap, boundaryMap, copyMap = TRUE)
vgaIsovist(pointMap, boundaryMap, copyMap = TRUE)
pointMap |
A PointMap |
boundaryMap |
A ShapeMap of lines |
copyMap |
Optional. Copy the internal sala map |
A new PointMap with the results included
mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) pointMap <- makeVGAPointMap( sfMap, gridSize = 0.5, fillX = 3.0, fillY = 6.0, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE ) boundaryMap <- as(sfMap[, c()], "ShapeMap") vgaIsovist(pointMap, boundaryMap)
mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) pointMap <- makeVGAPointMap( sfMap, gridSize = 0.5, fillX = 3.0, fillY = 6.0, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE ) boundaryMap <- as(sfMap[, c()], "ShapeMap") vgaIsovist(pointMap, boundaryMap)
Different algorithms for calculating the VGA Local metrics (Control, Controllability, Clustering Coefficient).
VGALocalAlgorithm$None
VGALocalAlgorithm$Standard
VGALocalAlgorithm$AdjacencyMatrix
VGALocalAlgorithm
VGALocalAlgorithm
An object of class list
of length 3.
A list of numbers representing each algorithm
VGALocalAlgorithm$Angular VGALocalAlgorithm$Topological VGALocalAlgorithm$Metric
VGALocalAlgorithm$Angular VGALocalAlgorithm$Topological VGALocalAlgorithm$Metric
Runs Visibility Graph Analysis to get the Through Vision metric
vgaThroughVision(pointMap, copyMap = TRUE)
vgaThroughVision(pointMap, copyMap = TRUE)
pointMap |
A PointMap |
copyMap |
Optional. Copy the internal sala map |
A new PointMap with the results included
mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) pointMap <- makeVGAPointMap( sfMap, gridSize = 0.5, fillX = 3.0, fillY = 6.0, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE ) vgaThroughVision(pointMap)
mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) pointMap <- makeVGAPointMap( sfMap, gridSize = 0.5, fillX = 3.0, fillY = 6.0, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE ) vgaThroughVision(pointMap)
Runs Visibility Graph Analysis to get visual local metrics
vgaVisualLocal( pointMap, nthreads = 1L, algorithm = VGALocalAlgorithm$Standard, copyMap = TRUE, gatesOnly = FALSE, progress = FALSE )
vgaVisualLocal( pointMap, nthreads = 1L, algorithm = VGALocalAlgorithm$Standard, copyMap = TRUE, gatesOnly = FALSE, progress = FALSE )
pointMap |
A PointMap |
nthreads |
Optional. Number of threads to use (defaults to 1) |
algorithm |
Optional. The algorithm to use. See ?VGALocalAlgorithm |
copyMap |
Optional. Copy the internal sala map |
gatesOnly |
Optional. Only keep the values at specific gates |
progress |
Optional. Enable progress display |
A new PointMap with the results included
mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) pointMap <- makeVGAPointMap( sfMap, gridSize = 0.5, fillX = 3.0, fillY = 6.0, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE ) vgaVisualLocal(pointMap, FALSE)
mifFile <- system.file( "extdata", "testdata", "simple", "simple_interior.mif", package = "alcyon" ) sfMap <- st_read(mifFile, geometry_column = 1L, quiet = TRUE ) pointMap <- makeVGAPointMap( sfMap, gridSize = 0.5, fillX = 3.0, fillY = 6.0, maxVisibility = NA, boundaryGraph = FALSE, verbose = FALSE ) vgaVisualLocal(pointMap, FALSE)