SpatialBoundaries.jl
Core functions
SpatialBoundaries.wombling — Functionwombling(x::Vector{T}, y::Vector{T}, z::Vector{T}) where {T<:Number}Wrapper function that implements the triangulation wombling algorithm for points that are irregularly arranged in space.
wombling(x::Vector{T}, y::Vector{T}, z::Matrix{T}) where {T<:Number}Wrapper function that implements the lattice wombling algorithm for points that are regularly arranged in space. Note that the matrix is presented in a way that is flipped, i.e. the x coordinates corresponds to the rows, and the y coordinates correspond to the columns. If you want to think of x and y as geographic coordinates, y are the longitudes, and x are the latitudes. Using the bindings for SimpleSDMLayers, this conversion will be performed automatically.
wombling(m::Matrix{T}) where {T<:Number}Shortcut to womble a matrix (using lattice wombling) when no x and y positions are given - the cell size in each dimension is expected to be 1.
SpatialBoundaries.boundaries — Functionboundaries(W::Womble, t=0.1; ignorezero=false)Extracts candidate boundaries using calculated wombling object W on specified threshold t. Default threshold is 0.1, meaning that the top 10% of pixels are selected as part of the boundaries. This function returns a list of indices identifying which simplices are part of the boundaries. The NaN values in the rates of change are not going to be a part of the boundaries. The keyword ignorezero, which defaults to false, can be used to remove the points with a rate of change of 0.
Types
SpatialBoundaries.LatticeWomble — TypeLatticeWomble{T <: Number} <: WombleA set of data (and co-ordinates) that are regularly arranged in space are of type LatticeWomble after having been passed through wombling - the fields in this type are
m, a matrix of rate of change at each (x,y) co-ordinateθ, a matrix of direction of change at each (x,y) co-ordinatexandy, the coordinates of the center of each cell
Note that the type of x and y should be the same as the element type of m and θ, because these values are all used when calculating the rate of change and that x and y correspond to latitude and longitude respectively.
SpatialBoundaries.TriangulationWomble — TypeTriangulationWomble{T <: Number} <: WombleA set of data (and co-ordinates) that are irregularly arranged in space are of type TriangulationWomble after having been passed through wombling - the fields in this type are
m, a vector of rate of change at each (x,y) co-ordinateθ, a vector of direction of change at each (x,y) co-ordinatexandy, the coordinates of the barycenter of each triangle in the plan
Note that the type of x and y should be the same as the element type of m and θ, because these values are all used when calculating the rate of change and that x and y correspond to latitude and longitude respectively.
SpatialBoundaries.Womble — TypeWombleThe Womble abstract type is a catch-all for specific wombling outputs.