aspace (version 0.1)

calc.sdd: Calculate and plot the Standard Distance Deviation (Standard Distance), and a Standard Deviation Box

Description

The dispersion of a set of points on a Cartesian plane can be described using the Standard Distance Deviation (SDD) or Standard Distance. For the purpose of geographic visualization, the SDD is typically portrayed as a circle with radius SDD centered on the mean center of a set of point observations. The orthogonal dispersion of a set of points can also be described using the standard deviation of the x- and y-coordinates of a set of point observations. The standard deviation of x- and y-coordinates can be geographically visualized using a box, with the edges set, respectively, to the standard deviation of the x- and y-coordinates.

Usage

calc.sdd(id = 1, filename = "SDD_Output.txt", centre.xy = centre, calccentre = TRUE, useWMC = FALSE, weightpoints = FALSE, weights = wts, destmat = activities, verbose = FALSE, plot = TRUE, plothv = TRUE, plotdest = TRUE, plotcenter = TRUE, box = TRUE)

Arguments

id
A unique integer to identify the shape
filename
A string indicating the ASCII textfile where shape coordinates will be written
centre.xy
A vector of length 2, containing the x- and y-coordinates of the SDD centroid
calccentre
Boolean: Set to TRUE if the mean center is to be calculated
useWMC
Boolean: Set to TRUE if the mean center is to be computed with weighted coordinates
weightpoints
Boolean: Set to TRUE if the point observations are to be weighted
weights
Weights applied to point observations
destmat
A 2-column matrix or data frame containing point coordinates
verbose
Boolean: Set to TRUE if extensive feedback is desired on the standard output
plot
Boolean: Set to TRUE if the SDD is to be plotted
plothv
Boolean: Set to TRUE if the orthogonal N-S, E-W axes are to be plotted through the center
plotdest
Boolean: Set to TRUE if the point observations are to be plotted
plotcenter
Boolean: Set to TRUE if the mean center is to be plotted
box
Boolean: Set to TRUE if the standard deviation of the x- and y-coordinates are to be plotted as a box

Value

  • The result is a list of terms:
  • idIdentifier for the SDD shape - it should be unique
  • calccentreTrue if mean centre is computed
  • Orig.xOriginal x-coordinate of center before mean center calculation
  • Orig.yOriginal y-coordinate of center before mean center calculation
  • CENTRE.xActual, used x-coordinate of centre
  • CENTRE.yActual, used y-coordinate of centre
  • SD.xStandard deviation of the x-coordinates
  • SD.yStandard deviation of the y-coordinates
  • SDD.radiusSDD value, radius of the SDD
  • Box.areaArea of the box formed by the standard deviation of the x- and y-coordinates
  • SDD.areaArea of the SDD circle
  • useWMCBoolean: TRUE if the weighted mean center is used
  • WeightPointsBoolean: TRUE if point observations are weighted

Details

This function is most powerful when used repetitively within a loop to compute the SDD for subsets of points stored in a large table.

See Also

ellipse3, calc.mcp, calc.sde, makeshapes

Examples

Run this code
calc.sdd(id = 1, filename = "SDD_Output.txt", centre.xy = centre, calccentre = TRUE, useWMC = FALSE, weightpoints = FALSE, destmat = activities, verbose = FALSE, plot = TRUE, plothv = TRUE, plotdest = TRUE, plotcenter = TRUE, box = TRUE)

Run the code above in your browser using DataLab