Helper function: add horizontal distances from left boundary coordinates

addHorizontalDistances(gisData, leftBoundaryRow = 1)

Arguments

gisData

data.frame as retrieved by importShapefiles()

leftBoundaryRow

row number index of "gisData" which contains the left model boundary (Default: 1)

Value

Model coordinates instead of "real" world coordinates

Examples

shp.dir <- system.file("extdata", "qgis", package="kwb.demeau") shp.files <- dir(path = shp.dir, pattern = ".shp", full.names = TRUE) ### Store GIS data in R data.frame "gisData" gisData <- importShapefiles(shp.files) ### Add horizontal distances from left boundary and ignore all features that ### have larger distances than "right" boundary gisData <- addHorizontalDistances(gisData)
#> Feature: Settling basin of Ponds.shp (Left boundary lies inside. Minimum distance set to 0) #> Feature: Settling basin of Ponds.shp (Left boundary lies inside. Maximum distance set to 91.6)
### Plot horizontal model coordinates maxVertical <- -abs(max(gisData$fcBottom, na.rm=TRUE))