spatstat v1.19-1


Monthly downloads



by Adrian Baddeley

Spatial Point Pattern analysis, model-fitting, simulation, tests

A package for analysing spatial data, mainly Spatial Point Patterns, including multitype/marked points and spatial covariates, in any two-dimensional spatial region. Also supports three-dimensional point patterns, and space-time point patterns in any number of dimensions. Contains functions for plotting spatial data, exploratory data analysis, model-fitting, simulation, spatial sampling, model diagnostics, and formal inference. Data types include point patterns, line segment patterns, spatial windows, pixel images and tessellations. Point process models can be fitted to point pattern data. Cluster type models are fitted by the method of minimum contrast. Very general Gibbs point process models can be fitted to point pattern data using a function ppm similar to lm or glm. Models may include dependence on covariates, interpoint interaction and dependence on marks. Fitted models can be simulated automatically. Also provides facilities for formal inference (such as chi-squared tests) and model diagnostics (including simulation envelopes, residuals, residual plots and Q-Q plots).

Functions in spatstat

Name Description
Jcross Multitype J Function (i-to-j) Coerce Line Segment Pattern to a Data Frame
ants Harkness-Isham ants' nests data
cut.ppp Classify Points in a Point Pattern
convexhull.xy Convex Hull of Points
Poisson Poisson Point Process Model
distmap.owin Distance Map of Window
mincontrast Method of Minimum Contrast
markstat Summarise Marks in Every Neighbourhood in a Point Pattern
methods.box3 Methods for Three-Dimensional Box Convert Pixel Image from Numeric to Factor
Hest Spherical Contact Distribution Function
affine.ppp Apply Affine Transformation To Point Pattern
Iest Estimate the I-function
Extract.fv Extract Subset of Function Values
Extract.splitppp Extract or Replace Sub-Patterns
Gcross Multitype Nearest Neighbour Distance Function (i-to-j)
betacells Beta Ganglion Cells in Cat Retina
Lcross Multitype L-function (cross-type)
Lcross.inhom Inhomogeneous Cross Type L Function
Pairwise Generic Pairwise Interaction model
chorley Chorley-Ribble Cancer Data
nbfires Point Patterns of New Brunswick Forest Fires Test Whether Two Pixel Images Are Compatible
MultiStrauss The Multitype Strauss Point Process Model
allstats Calculate four standard summary functions of a point pattern.
Softcore The Soft Core Point Process Model
Kest.fft K-function using FFT
pppmatching.object Class of Point Matchings
StraussHard The Strauss / Hard Core Point Process Model
as.rectangle Window Frame
pairdist Pairwise distances
Jmulti Marked J Function
rThomas Simulate Thomas Process
fitted.ppm Fitted Conditional Intensity for Point Process Model
clickpoly Interactively Define a Polygon
Hardcore The Hard Core Point Process Model
as.mask.psp Convert Line Segment Pattern to Binary Pixel Mask
Kdot Multitype K Function (i-to-any) Convert Pixel Image to Matrix
Extract.listof Extract or Replace Subset of a List of Things
bdist.pixels Distance to Boundary of Window
as.polygonal Convert a Window to a Polygonal Window
centroid.owin Centroid of a window
DiggleGratton Diggle-Gratton model
crossing.psp Crossing Points of Two Line Segment Patterns
default.dummy Generate a Default Pattern of Dummy Points
clarkevans Clark and Evans Aggregation Index Extract Subset of Image
Ord Generic Ord Interaction model
bermantest Berman's Tests for Point Process Model Convert to Pixel Image
Strauss The Strauss Point Process Model
anova.ppm ANOVA for Fitted Point Process Models
expand.owin Expand Window By Factor
Gest Nearest Neighbour Distance Function G
crossdist.psp Pairwise distances between two different line segment patterns
eval.fv Evaluate Expression Involving Functions
owin Create a Window
pcfcross Multitype pair correlation function (cross-type)
gridweights Compute Quadrature Weights Based on Grid Counts
rlabel Random Re-Labelling of Point Pattern
Gdot Multitype Nearest Neighbour Distance Function (i-to-any)
collapse.fv Collapse Several Function Tables into One
delaunay Delaunay Triangulation of Point Pattern Reset Values in Subset of Image
print.ppp Print Brief Details of a Point Pattern Dataset
redwoodfull California Redwoods Point Pattern (Entire Dataset)
G3est Nearest Neighbour Distance Distribution Function of a Three-Dimensional Point Pattern
crossdist.ppp Pairwise distances between two different point patterns
istat Point and Click Interface for Exploratory Analysis of Point Pattern
kstest.ppm Kolmogorov-Smirnov Test for Point Process Model Bounding Box of a Window or Point Pattern
iplot Point and Click Interface for Displaying a Point Pattern
as.tess Convert Data To Tessellation
lut Lookup Tables
cbind.hyperframe Combine Hyperframes by Rows or by Columns
eval.fasp Evaluate Expression Involving Function Arrays Convex Hull of Points
model.images Compute Images of Constructed Covariates
marks Marks of a Point Pattern
cells Biological Cells Point Pattern
lansing Lansing Woods Point Pattern
density.splitppp Kernel Smoothed Intensity of Split Point Pattern
box3 Three-Dimensional Box
demopat Artificial Data Point Pattern Test Whether An Object Is A Pixel Image
Emark Diagnostics for random marking Kaplan-Meier and Reduced Sample Estimator using Histograms
identify.ppp Identify Points in a Point Pattern
areaGain Difference of Disc Areas
affine.psp Apply Affine Transformation To Line Segment Pattern
blur Apply Gaussian Blur to a Pixel Image
Extract.quad Subset of Quadrature Scheme
pixellate Convert Spatial Object to Pixel Image
Linhom L-function
as.hyperframe.ppx Extract coordinates and marks of multidimensional point pattern
Kcross.inhom Inhomogeneous Cross K Function
dilated.areas Areas of Morphological Dilations
nndist.ppx Nearest Neighbour Distances in Any Dimensions
nnclean Nearest Neighbour Clutter Removal
periodify Make Periodic Copies of a Spatial Pattern
simulate.kppm Simulate a Fitted Cluster Point Process Model
distfun Distance Map as a Function
logLik.ppm Log Likelihood for Poisson Point Process Model
shift.psp Apply Vector Translation To Line Segment Pattern Interpolate a Pixel Image
diameter.boxx Geometrical Calculations for Multi-Dimensional Box
im Create a Pixel Image Object
rmhmodel Define Point Process Model for Metropolis-Hastings Simulation.
is.owin Test Whether An Object Is A Window
predict.kppm Prediction from a Fitted Cluster Point Process Model Print Brief Details of an Image
Kinhom Inhomogeneous K-function
nndist.pp3 Nearest neighbour distances in three dimensions
coef.ppm Coefficients of Fitted Point Process Model
ewcdf Weighted Empirical Cumulative Distribution Function
quadrat.test.splitppp Chi-Squared Test of CSR for Split Point Pattern
distmap Distance Map
area.owin Area of a Window
areaLoss Difference of Disc Areas Contour plot of pixel image
summary.ppm Summarizing a Fitted Point Process Model
Gfox Foxall's Distance Functions
markconnect Mark Connection Function
closing Morphological Closing
pairdist.ppx Pairwise Distances in Any Dimensions
Jest Estimate the J-function
is.convex Test Whether a Window is Convex
alltypes Calculate Summary Statistic for All Types in a Multitype Point Pattern Perspective Plot of Pixel Image
is.multitype.ppp Test Whether A Point Pattern is Multitype
discpartarea Area of Part of Disc
midpoints.psp Midpoints of Line Segment Pattern
ripras Estimate window from points alone
levelset Level Set of a Pixel Image
as.mask Pixel Image Approximation of a Window
pp3 Three Dimensional Point Pattern
Kcross Multitype K Function (Cross-type)
envelope.pp3 Simulation Envelopes of Summary Function for 3D Point Pattern
perimeter Perimeter Length of Window
heather Diggle's Heather Data
PairPiece The Piecewise Constant Pairwise Interaction Point Process Model
data.ppm Extract Original Data from a Fitted Point Process Model
distmap.psp Distance Map of Line Segment Pattern
nncorr Nearest-Neighbour Correlation Indices of Marked Point Pattern
Extract.tess Extract or Replace Subset of Tessellation
gpc2owin Convert Polygonal Region into Different Format
BadGey Hybrid Geyer Point Process Model
AreaInter The Area Interaction Point Process Model
dummy.ppm Extract Dummy Points Used to Fit a Point Process Model Sample Quantiles of Pixel Image
plot.splitppp Plot a List of Point Patterns
ppp.object Class of Point Patterns
is.ppp Test Whether An Object Is A Point Pattern
Fest Estimate the empty space function F
Kest K-function Evaluate Expression Involving Pixel Images
pixellate.psp Convert Line Segment Pattern to Pixel Image
spatstat-internal Internal spatstat functions
bramblecanes Hutchings' Bramble Canes data
diagnose.ppm Diagnostic Plots for Fitted Point Process Model
Geyer Geyer's Saturation Point Process Model
bind.fv Combine Function Value Tables
redwood California Redwoods Point Pattern (Ripley's Subset)
smooth.ppp Spatial smoothing of observations at irregular points
diameter Diameter of an Object
markcorrint Mark Correlation Integral
rMaternII Simulate Matern Model II
as.psp Convert Data To Class psp
diameter.box3 Geometrical Calculations for Three-Dimensional Box
print.quad Print a Quadrature Scheme
pixellate.owin Convert Window to Pixel Image
is.marked Test Whether Marks Are Present
convexhull Convex Hull
by.ppp Apply a Function to a Point Pattern Broken Down by Factor
pcfdot.inhom Inhomogeneous Multitype Pair Correlation Function (Type-i-To-Any-Type)
lurking Lurking variable plot Plot a Pixel Image
ppx Multidimensional Space-Time Point Pattern Print News About Latest Version of Package
shift Apply Vector Translation
chop.tess Subdivide a Window or Tessellation using a Set of Lines
humberside Humberside Data on Childhood Leukaemia and Lymphoma
append.psp Combine Two Line Segment Patterns
crossdist.default Pairwise distances between two different sets of points
fv Create a Function Value Table
murchison Murchison gold deposits
clickppp Interactively Add Points
is.marked.ppm Test Whether A Point Process Model is Marked
plot.tess Plot a tessellation
as.owin Convert Data To Class owin
spruces Spruces Point Pattern
MultiStraussHard The Multitype/Hard Core Strauss Point Process Model
hamster Aherne's hamster tumour data
SatPiece Piecewise Constant Saturated Pairwise Interaction Point Process Model
rescale.psp Convert Line Segment Pattern to Another Unit of Length
infline Infinite Straight Lines
nncross Nearest Neighbours Between Two Patterns
summary.ppp Summary of a Point Pattern Dataset
project2segment Move Point To Nearest Line
localK Neighbourhood density function
bei Tropical rain forest trees
methods.boxx Methods for Multi-Dimensional Box
methods.ppx Methods for Multidimensional Space-Time Point Patterns
runifpoint3 Generate N Uniform Random Points in Three Dimensions
bronzefilter Bronze gradient filter data
affine Apply Affine Transformation
pppdist Distance Between Two Point Patterns
plot.colourmap Plot a Colour Map
kaplan.meier Kaplan-Meier Estimator using Histogram Data
rSSI Simulate Simple Sequential Inhibition
runifdisc Generate N Uniform Random Points in a Disc
summary.owin Summary of a Spatial Window
profilepl Profile Maximum Pseudolikelihood
bdist.points Distance to Boundary of Window
matchingdist Distance for a Point Pattern Matching
Extract.psp Extract Subset of Line Segment Pattern
clip.infline Intersect Infinite Straight Lines with a Window
as.box3 Convert Data to Three-Dimensional Box
distmap.ppp Distance Map of Point Pattern
concatxy Concatenate x,y Coordinate Vectors
rMaternI Simulate Matern Model I
Ldot Multitype L-function (i-to-any)
lengths.psp Lengths of Line Segments Apply Function to Image Broken Down by Factor
colourmap Colour Lookup Tables
LennardJones The Lennard-Jones Potential
Saturated Saturated Pairwise Interaction model
finpines Pine saplings in Finland.
F3est Empty Space Function of a Three-Dimensional Point Pattern
thomas.estK Fit the Thomas Point Process by Minimum Contrast
quadrat.test Chi-Squared Dispersion Test for Spatial Point Pattern Based on Quadrat Counts
fitin.ppm Extract the Interaction from a Fitted Point Process Model
anemones Beadlet Anemones Data
adaptive.density Intensity Estimate of Point Pattern Using Tessellation
nnwhich.pp3 Nearest neighbours in three dimensions
applynbd Apply Function to Every Neighbourhood in a Point Pattern
nearest.raster.point Find Pixel Nearest to a Given Point
Gmulti Marked Nearest Neighbour Distance Function
plot.plotppm Plot a plotppm Object Created by plot.ppm
owin.object Class owin Convert Pixel Image to Another Unit of Length Summarizing a Pixel Image
complement.owin Take Complement of a Window
plot.pp3 Plot a three-dimensional point pattern
summary.listof Summary of a List of Things
crossdist.ppx Pairwise Distances Between Two Different Multi-Dimensional Point Patterns
ppm.object Class of Fitted Point Process Models
methods.pp3 Methods for three-dimensional point patterns
volume Volume of an Object
npoints Number of Points in a Point Pattern
fasp.object Function Arrays for Spatial Patterns
Kmeasure Reduced Second Moment Measure
OrdThresh Ord's Interaction model
plot.kstest Plot a Spatial Kolmogorov-Smirnov Test Convert Pixel Image to Data Frame
pcfdot Multitype pair correlation function (i-to-any) Coerce Point Pattern to a Data Frame
nndist.psp Nearest neighbour distances between line segments
rescue.rectangle Convert Window Back To Rectangle
rmpoispp Generate Multitype Poisson Point Pattern
pairdist.ppp Pairwise distances
quad.ppm Extract Quadrature Scheme Used to Fit a Point Process Model
psp.object Class of Line Segment Patterns
marktable Tabulate Marks in Neighbourhood of Every Point in a Point Pattern
pixellate.ppp Convert Point Pattern to Pixel Image
unique.ppp Extract Unique Points from a Spatial Point Pattern
rmh.ppm Simulate from a Fitted Point Process Model
density.psp Kernel Smoothing of Line Segment Pattern
markcorr Mark Correlation Function
nnwhich Nearest neighbour
plot.bermantest Plot Result of Berman Test
rGaussPoisson Simulate Gauss-Poisson Process Saturated Pairwise Interaction Point Process Family
nearestsegment Find Line Segment Nearest to Each Point Coerce Hyperframe to Data Frame Integral of a Pixel Image
quadratresample Resample a Point Pattern by Resampling Quadrats
as.hyperframe Convert Data to Hyperframe
border Border Region of a Window
crossdist.pp3 Pairwise distances between two different three-dimensional point patterns
fryplot Fry Plot of Point Pattern
spatstat-deprecated Deprecated spatstat functions
shift.owin Apply Vector Translation To Window
dilation Morphological Dilation
Fiksel The Fiksel Interaction
rpoint Generate N Random Points
affine.owin Apply Affine Transformation To Window
quadscheme Generate a Quadrature Scheme from a Point Pattern
rotate.ppp Rotate a Point Pattern
setcov Set Covariance of a Window
pairdist.pp3 Pairwise distances in Three Dimensions
rMatClust Simulate Matern Cluster Process
Extract.fasp Extract Subset of Function Array
rStrauss Perfect Simulation of the Strauss Process
union.quad Union of Data and Dummy Points
effectfun Compute Fitted Effect of a Spatial Covariate in a Point Process Model
spatstat.options Internal Options in Spatstat Package
connected Connected components of an image or window
stieltjes Compute Integral of Function Against Cumulative Distribution
japanesepines Japanese Pines Point Pattern
multiplicity.ppp Count Multiplicity of Duplicate Points
rpoislinetess Poisson Line Tessellation
rlinegrid Generate grid of parallel lines with random displacement
is.multitype Test whether Object is Multitype
Lest L-function
angles.psp Orientation Angles of Line Segments
density.ppp Kernel Smoothed Intensity of Point Pattern
rmhstart Determine Initial State for Metropolis-Hastings Simulation.
matclust.estK Fit the Matern Cluster Point Process by Minimum Contrast
Jdot Multitype J Function (i-to-any)
im.object Class of Images
rmhmodel.ppm Interpret Fitted Model for Metropolis-Hastings Simulation.
raster.x Cartesian Coordinates for a Pixel Raster
rshift.psp Randomly Shift a Line Segment Pattern
quadratcount Quadrat counting for a point pattern
plot.kppm Plot a fitted cluster point process
summary.splitppp Summary of a Split Point Pattern
copper Berman-Huntington points and lines data
rmh Simulate point patterns using the Metropolis-Hastings algorithm.
residualspaper Data and Code From JRSS Discussion Paper on Residuals
fv.object Data Frames of Function Values
plot.hyperframe Plot Entries in a Hyperframe
nnwhich.ppx Nearest Neighbours in Any Dimensions
simulate.ppm Simulate a Fitted Gibbs Point Process Model
rshift Random Shift
plot.ppm plot a Fitted Point Process Model
rescale.ppp Convert Point Pattern to Another Unit of Length
ganglia Beta Ganglion Cells in Cat Retina, Old Version
rpoisppx Generate Poisson Point Pattern in Any Dimensions
corners Corners of a rectangle
vertices Vertices of a Window
amacrine Hughes' Amacrine Cell Data
rmhmodel.list Define Point Process Model for Metropolis-Hastings Simulation.
hyperframe Hyper Data Frame
tess Create a Tessellation
endpoints.psp Endpoints of Line Segment Pattern
pcfinhom Inhomogeneous Pair Correlation Function
is.empty Test Whether An Object Is Empty
rknn Theoretical Distribution of Nearest Neighbour Distance
print.psp Print Brief Details of a Line Segment Pattern Dataset
rotate.owin Rotate a Window
summary.psp Summary of a Line Segment Pattern Dataset
runifpointOnLines Generate N Uniform Random Points On Line Segments
rstrat Simulate Stratified Random Point Pattern
longleaf Longleaf Pines Point Pattern
qqplot.ppm Q-Q Plot of Residuals from Fitted Point Process Model
pcfcross.inhom Inhomogeneous Multitype Pair Correlation Function (Cross-Type)
markvario Mark Variogram
boxx Multi-Dimensional Box
duplicated.ppp Determine Duplicated Points in a Spatial Point Pattern
rotate Rotate
eem Exponential Energy Marks
spokes Spokes pattern of dummy points
rsyst Simulate systematic random point pattern
crossdist Pairwise distances
is.ppm Test Whether An Object Is A Fitted Point Process Model
suffstat Sufficient Statistic of Point Process Model
model.matrix.ppm Extract Design Matrix from Point Process Model
rcell Simulate Baddeley-Silverman Cell Process
osteo Osteocyte Lacunae Data: Replicated Three-Dimensional Point Patterns
harmonic Basis for Harmonic Functions
rpoisline Generate Poisson Random Line Process Histogram of Pixel Values in an Image
superimposePSP Superimpose Several Line Segment Patterns
runifpointx Generate N Uniform Random Points in Any Dimensions
incircle Find Largest Circle Inside Window
shapley Galaxies in the Shapley Supercluster
is.marked.ppp Test Whether A Point Pattern is Marked
pcf.fv Pair Correlation Function obtained from K Function
update.kppm Update a Fitted Cluster Point Process Model
kppm Fit cluster point process model
solutionset Evaluate Logical Expression Involving Pixel Images and Return Region Where Expression is True
compatible.fasp Test Whether Two Function Arrays Are Compatible
simplify.owin Approximate a Polygon by a Simpler Polygon
intersect.tess Intersection of Two Tessellations
pcf Pair Correlation Function
as.ppp Convert Data To Class ppp
inside.owin Test Whether Points Are Inside A Window
simdat Simulated Point Pattern
plot.owin Plot a Spatial Window
runifpoint Generate N Uniform Random Points
pointsOnLines Place Points Evenly Along Specified Lines
lgcp.estK Fit a Log-Gaussian Cox Point Process by Minimum Contrast Infinite Order Interaction Family
unmark Remove Marks
nndist Nearest neighbour distances
ponderosa Ponderosa Pine Tree Point Pattern
opening Morphological Opening
pairdist.default Pairwise distances
letterR Window in Shape of Letter R
is.subset.owin Determine Whether One Window is Contained In Another
deltametric Delta Metric
plot.quad plot a Spatial Quadrature Scheme
print.owin Print Brief Details of a Spatial Window
Ldot.inhom Inhomogeneous Multitype L Dot Function
rmhcontrol Set Control Parameters for Metropolis-Hastings Algorithm.
compatible.fv Test Whether Two Function Objects Are Compatible
pairdist.psp Pairwise distances between line segments
rpoisppOnLines Generate Poisson Point Pattern on Line Segments
spatstat-package The Spatstat Package
erosion Morphological Erosion
is.multitype.ppm Test Whether A Point Process Model is Multitype
Extract.ppp Extract or Replace Subset of Point Pattern
rshift.splitppp Randomly Shift a List of Point Patterns
rMosaicField Mosaic Random Field
print.ppm Print a Fitted Point Process Model
predict.ppm Prediction from a Fitted Point Process Model
plot.psp plot a Spatial Line Segment Pattern
Kmulti Marked K-Function
whist Weighted Histogram
quad.object Class of Quadrature Schemes
eroded.areas Areas of Morphological Erosions
trim.rectangle Cut margins from rectangle
discretise Safely Convert Point Pattern Window to Binary Mask Apply Vector Translation To Pixel Image
intersect.owin Intersection, Union or Set Subtraction of Two Windows
plot.fv Plot Function Values
split.ppp Divide Point Pattern into Sub-patterns
rmpoint Generate N Random Multitype Points
envelope Simulation Envelopes of Summary Function
rpoispp3 Generate Poisson Point Pattern in Three Dimensions Pairwise Interaction Process Family
pppmatching Create a Point Matching Divide Image Into Sub-images
rescale.owin Convert Window to Another Unit of Length
scanpp Read Point Pattern From Data File
tiles Extract List of Tiles in a Tessellation
coords Extract Coordinates of a Spatial or Spatiotemporal Point Pattern
rjitter Random Perturbation of a Point Pattern
rshift.ppp Randomly Shift a Point Pattern
dirichlet.weights Compute Quadrature Weights Based on Dirichlet Tessellation
nztrees New Zealand Trees Point Pattern
residuals.ppm Residuals for Fitted Point Process Model Ord Interaction Process Family
plot.ppp plot a Spatial Point Pattern
Kdot.inhom Inhomogeneous Multitype K Dot Function
dirichlet Dirichlet Tessellation of Point Pattern
ppm Fit Point Process Model to Data
superimpose Superimpose Several Point Patterns
reduced.sample Reduced Sample Estimator using Histogram Data
swedishpines Swedish Pines Point Pattern
rotate.psp Rotate a Line Segment Pattern
bdist.tiles Distance to Boundary of Window
reach Interaction Distance of a Point Process
pcf.ppp Pair Correlation Function of Point Pattern
urkiola Urkiola Woods Point Pattern
psp Create a Line Segment Pattern
smooth.fv Apply Smoothing to Function Values
selfcrossing.psp Crossing Points in a Line Segment Pattern
summary.quad Summarizing a Quadrature Scheme
plot.listof Plot a List of Things
gridcentres Rectangular grid of points
with.fv Evaluate an Expression in a Function Table
progressreport Print Progress Reports
miplot Morishita Index Plot
rescale Convert dataset to another unit of length
rpoispp Generate Poisson Point Pattern
square Square Window
plot.fasp Plot a Function Array
unitname Name for Unit of Length
shift.ppp Apply Vector Translation To Point Pattern
pixelquad Quadrature Scheme Based on Pixel Grid
rMosaicSet Mosaic Random Set
update.ppm Update a Fitted Point Process Model
with.hyperframe Evaluate an Expression in Each Row of a Hyperframe
pcf.fasp Pair Correlation Function obtained from array of K functions
rmhmodel.default Build Point Process Model for Metropolis-Hastings Simulation.
vcov.ppm Variance-Covariance Matrix for a Fitted Point Process Model
quadrats Divide Region into Quadrats
rthin Random Thinning
rNeymanScott Simulate Neyman-Scott Process
rmh.default Simulate Point Process Models using the Metropolis-Hastings Algorithm.
disc Circular Window
diameter.owin Diameter of a Window
ppp Create a Point Pattern
K3est K-function of a Three-Dimensional Point Pattern Maximum, Minimum, Mean, Median, Range or Sum of Pixel Values in an Image
No Results!

Last month downloads


Date 2010-05-22
License GPL (>= 2)
Packaged 2010-05-23 02:05:13 UTC; adrian
Repository CRAN
Date/Publication 2010-05-25 17:09:22

Include our badge in your README