Learn R Programming

⚠️There's a newer version (3.3-3) of this package.Take me there.

spatstat.geom (version 2.0-1)

Geometrical Functionality of the 'spatstat' Family

Description

Defines types of spatial data such as point patterns, mainly in two dimensions, but also in higher dimensions. Provides class support, and functions for geometrical operations on spatial data, used in the 'spatstat' family of packages. Excludes spatial data on a linear network, which are covered by the separate package 'spatstat.linnet'.

Copy Link

Version

Install

install.packages('spatstat.geom')

Monthly Downloads

66,163

Version

2.0-1

License

GPL (>= 2)

Maintainer

Last Published

March 22nd, 2021

Functions in spatstat.geom (2.0-1)

Extract.anylist

Extract or Replace Subset of a List of Things
as.ppp

Convert Data To Class ppp
as.boxx

Convert Data to Multi-Dimensional Box
as.data.frame.hyperframe

Coerce Hyperframe to Data Frame
as.function.im

Convert Pixel Image to Function of Coordinates
Math.im

S3 Group Generic methods for images
Math.imlist

S3 Group Generic methods for List of Images
as.data.frame.tess

Convert Tessellation to Data Frame
Extract.tess

Extract or Replace Subset of Tessellation
as.psp

Convert Data To Class psp
Window

Extract or Change the Window of a Spatial Object
Extract.ppp

Extract or Replace Subset of Point Pattern
Extract.ppx

Extract Subset of Multidimensional Point Pattern
Frame

Extract or Change the Containing Rectangle of a Spatial Object
by.ppp

Apply a Function to a Point Pattern Broken Down by Factor
as.polygonal

Convert a Window to a Polygonal Window
angles.psp

Orientation Angles of Line Segments
affine.tess

Apply Geometrical Transformation To Tessellation
as.owin

Convert Data To Class owin
convexhull

Convex Hull
cbind.hyperframe

Combine Hyperframes by Rows or by Columns
clickbox

Interactively Define a Rectangle
as.tess

Convert Data To Tessellation
corners

Corners of a rectangle
bdist.pixels

Distance to Boundary of Window
compatible.im

Test Whether Pixel Images Are Compatible
WindowOnly

Extract Window of Spatial Object
complement.owin

Take Complement of a Window
anylist

List of Objects
area.owin

Area of a Window
anyNA.im

Check Whether Image Contains NA Values
as.function.owin

Convert Window to Indicator Function
areaGain

Difference of Disc Areas
as.function.tess

Convert a Tessellation to a Function
clickdist

Interactively Measure Distance
convexhull.xy

Convex Hull of Points
diameter.boxx

Geometrical Calculations for Multi-Dimensional Box
diameter.owin

Diameter of a Window
as.rectangle

Window Frame
closepairs.pp3

Close Pairs of Points in 3 Dimensions
boundingcircle

Smallest Enclosing Circle
as.solist

Convert List of Two-Dimensional Spatial Objects
Extract.listof

Extract or Replace Subset of a List of Things
boxx

Multi-Dimensional Box
Extract.owin

Extract Subset of Window
box3

Three-Dimensional Box
by.im

Apply Function to Image Broken Down by Factor
duplicated.ppp

Determine Duplicated Points in a Spatial Point Pattern
edit.ppp

Invoke Text Editor on Spatial Data
closetriples

Close Triples of Points
compatible

Test Whether Objects Are Compatible
commonGrid

Determine A Common Spatial Domain And Pixel Resolution
affine.im

Apply Affine Transformation To Pixel Image
affine.owin

Apply Affine Transformation To Window
edges

Extract Boundary Edges of a Window.
edges2triangles

List Triangles in a Graph
ewcdf

Weighted Empirical Cumulative Distribution Function
edges2vees

List Dihedral Triples in a Graph
contour.im

Contour plot of pixel image
hotrod

Heat Kernel for a One-Dimensional Rod
extrapolate.psp

Extrapolate Line Segments to Obtain Infinite Lines
as.data.frame.im

Convert Pixel Image to Data Frame
hyperframe

Hyper Data Frame
as.data.frame.owin

Convert Window to Data Frame
contour.imlist

Array of Contour Plots
coords

Extract or Change Coordinates of a Spatial or Spatiotemporal Point Pattern
imcov

Spatial Covariance of a Pixel Image
im.object

Class of Images
is.connected

Determine Whether an Object is Connected
intensity.psp

Empirical Intensity of Line Segment Pattern
is.multitype.ppp

Test Whether A Point Pattern is Multitype
intensity.quadratcount

Intensity Estimates Using Quadrat Counts
as.hyperframe.ppx

Extract coordinates and marks of multidimensional point pattern
as.hyperframe

Convert Data to Hyperframe
is.connected.ppp

Determine Whether a Point Pattern is Connected
markstat

Summarise Marks in Every Neighbourhood in a Point Pattern
is.owin

Test Whether An Object Is A Window
matchingdist

Distance for a Point Pattern Matching
methods.box3

Methods for Three-Dimensional Box
nnwhich.pp3

Nearest neighbours in three dimensions
mergeLevels

Merge Levels of a Factor
as.matrix.owin

Convert Pixel Image to Matrix
as.matrix.im

Convert Pixel Image to Matrix or Array
crossdist.ppx

Pairwise Distances Between Two Different Multi-Dimensional Point Patterns
crossdist.ppp

Pairwise distances between two different point patterns
nnwhich.ppx

Nearest Neighbours in Any Dimensions
owin

Create a Window
boundingbox

Bounding Box of a Window, Image, or Point Pattern
Extract.quad

Subset of Quadrature Scheme
owin.object

Class owin
Extract.psp

Extract Subset of Line Segment Pattern
bounding.box.xy

Convex Hull of Points
Replace.im

Reset Values in Subset of Image
MinkowskiSum

Minkowski Sum of Windows
centroid.owin

Centroid of a window
pixellate

Convert Spatial Object to Pixel Image
chop.tess

Subdivide a Window or Tessellation using a Set of Lines
closepairs

Close Pairs of Points
clip.infline

Intersect Infinite Straight Lines with a Window
covering

Cover Region with Discs
crossdist

Pairwise distances
pixellate.owin

Convert Window to Pixel Image
pixellate.ppp

Convert Point Pattern to Pixel Image
pixellate.psp

Convert Line Segment Pattern to Pixel Image
levelset

Level Set of a Pixel Image
default.dummy

Generate a Default Pattern of Dummy Points
distmap.owin

Distance Map of Window
discpartarea

Area of Part of Disc
delaunay

Delaunay Triangulation of Point Pattern
disc

Circular Window
distmap.ppp

Distance Map of Point Pattern
fardist

Farthest Distance to Boundary of Window
as.box3

Convert Data to Three-Dimensional Box
affine

Apply Affine Transformation
add.texture

Fill Plot With Texture
areaLoss

Difference of Disc Areas
as.layered

Convert Data To Layered Object
as.im

Convert to Pixel Image
connected.ppp

Connected Components of a Point Pattern
colouroutputs

Extract or Assign Colour Values in a Colour Map
colourtools

Convert and Compare Colours in Different Formats
bdist.tiles

Distance to Boundary of Window
plot.solist

Plot a List of Spatial Objects
integral.im

Integral of a Pixel Image
cut.im

Convert Pixel Image from Numeric to Factor
bdist.points

Distance to Boundary of Window
distmap.psp

Distance Map of Line Segment Pattern
quadscheme.logi

Generate a Logistic Regression Quadrature Scheme from a Point Pattern
plot.splitppp

Plot a List of Point Patterns
quantile.ewcdf

Quantiles of Weighted Empirical Cumulative Distribution Function
quantess

Quantile Tessellation
identify.ppp

Identify Points in a Point Pattern
flipxy

Exchange X and Y Coordinates
interp.im

Interpolate a Pixel Image
cut.ppp

Classify Points in a Point Pattern
distmap

Distance Map
distfun

Distance Map as a Function
diameter

Diameter of an Object
diameter.box3

Geometrical Calculations for Three-Dimensional Box
project2segment

Move Point To Nearest Line
gridcentres

Rectangular grid of points
connected.tess

Connected Components of Tiles of a Tessellation
convolve.im

Convolution of Pixel Images
convexify

Weil's Convexifying Operation
delaunayDistance

Distance on Delaunay Triangulation
dirichletVertices

Vertices and Edges of Dirichlet Tessellation
edit.hyperframe

Invoke Text Editor on Hyperframe
identify.psp

Identify Segments in a Line Segment Pattern
invoke.symbolmap

Plot Data Using Graphics Symbol Map
plot.owin

Plot a Spatial Window
dirichletWeights

Compute Quadrature Weights Based on Dirichlet Tessellation
domain

Extract the Domain of any Spatial Object
lengths_psp

Lengths of Line Segments
erosionAny

Morphological Erosion of Windows
hist.im

Histogram of Pixel Values in an Image
eval.im

Evaluate Expression Involving Pixel Images
fourierbasis

Fourier Basis Functions
quantile.im

Sample Quantiles of Pixel Image
funxy

Spatial Function Class
Extract.im

Extract Subset of Image
deltametric

Delta Metric
rjitter

Random Perturbation of a Point Pattern
Extract.layered

Extract or Replace Subset of a Layered Object
dirichlet

Dirichlet Tessellation of Point Pattern
gridweights

Compute Quadrature Weights Based on Grid Counts
rlinegrid

Generate grid of parallel lines with random displacement
harmonise

Make Objects Compatible
hist.funxy

Histogram of Values of a Spatial Function
discretise

Safely Convert Point Pattern Window to Binary Mask
dirichletAreas

Compute Areas of Tiles in Dirichlet Tessellation
discs

Union of Discs
eroded.areas

Areas of Morphological Erosions
erosion

Morphological Erosion by a Disc
intensity.ppx

Intensity of a Multidimensional Space-Time Point Pattern
im

Create a Pixel Image Object
intensity.ppp

Empirical Intensity of Point Pattern
intersect.tess

Intersection of Two Tessellations
im.apply

Apply Function Pixelwise to List of Images
intensity

Intensity of a Dataset or a Model
harmonise.im

Make Pixel Images Compatible
plot.listof

Plot a List of Things
nsegments

Number of Line Segments in a Line Segment Pattern
interp.colourmap

Interpolate smoothly between specified colours
inside.boxx

Test Whether Points Are Inside A Multidimensional Box
inside.owin

Test Whether Points Are Inside A Window
headtail

First or Last Part of a Spatial Pattern
intersect.boxx

Intersection Of Boxes Of Arbitrary Dimension
hextess

Hexagonal Grid or Tessellation
is.lpp

Test Whether An Object Is A Point Pattern on a Linear Network
Extract.solist

Extract or Replace Subset of a List of Spatial Objects
volume

Volume of an Object
intersect.owin

Intersection, Union or Set Subtraction of Windows
run.simplepanel

Run Point-and-Click Interface
rsyst

Simulate systematic random point pattern
is.im

Test Whether An Object Is A Pixel Image
is.marked.ppp

Test Whether A Point Pattern is Marked
nndist.pp3

Nearest neighbour distances in three dimensions
is.multitype

Test whether Object is Multitype
nndist

Nearest neighbour distances
rotate

Rotate
is.marked

Test Whether Marks Are Present
affine.ppp

Apply Affine Transformation To Point Pattern
Extract.splitppp

Extract or Replace Sub-Patterns
nnmap

K-th Nearest Point Map
maxnndist

Compute Minimum or Maximum Nearest-Neighbour Distance
plot.layered

Layered Plot
methods.unitname

Methods for Units
simplify.owin

Approximate a Polygon by a Simpler Polygon
is.ppp

Test Whether An Object Is A Point Pattern
plot.yardstick

Plot a Yardstick or Scale Bar
is.rectangle

Determine Type of Window
plot.quad

Plot a Spatial Quadrature Scheme
affine.psp

Apply Affine Transformation To Line Segment Pattern
mean.im

Mean and Median of Pixel Values in an Image
nobjects

Count Number of Geometrical Objects in a Spatial Dataset
pppdist

Distance Between Two Point Patterns
padimage

Pad the Border of a Pixel Image
applynbd

Apply Function to Every Neighbourhood in a Point Pattern
as.data.frame.ppp

Coerce Point Pattern to a Data Frame
append.psp

Combine Two Line Segment Patterns
nearest.raster.point

Find Pixel Nearest to a Given Point
methods.funxy

Methods for Spatial Functions
methods.layered

Methods for Layered Objects
psp.object

Class of Line Segment Patterns
multiplicity.ppp

Count Multiplicity of Duplicate Points
solapply

Apply a Function Over a List and Obtain a List of Objects
as.data.frame.psp

Coerce Line Segment Pattern to a Data Frame
as.mask

Pixel Image Approximation of a Window
spatdim

Spatial Dimension of a Dataset
spatstat.geom-deprecated

Deprecated spatstat.geom functions
is.linim

Test Whether an Object is a Pixel Image on a Linear Network
summary.distfun

Summarizing a Function of Spatial Location
texturemap

Texture Map
textureplot

Plot Image or Tessellation Using Texture Fill
summary.im

Summarizing a Pixel Image
plot.onearrow

Plot an Arrow
npoints

Number of Points in a Point Pattern
spokes

Spokes pattern of dummy points
border

Border Region of a Window
lut

Lookup Tables
layered

Create List of Plotting Layers
beachcolours

Create Colour Scheme for a Range of Numbers
as.mask.psp

Convert Line Segment Pattern to Binary Pixel Mask
is.subset.owin

Determine Whether One Window is Contained In Another
marks

Marks of a Point Pattern
reflect

Reflect In Origin
methods.pp3

Methods for three-dimensional point patterns
methods.ppx

Methods for Multidimensional Space-Time Point Patterns
clickpoly

Interactively Define a Polygon
nvertices

Count Number of Vertices
clickppp

Interactively Add Points
closing

Morphological Closing
midpoints.psp

Midpoints of Line Segment Pattern
pairdist.pp3

Pairwise distances in Three Dimensions
pairdist.default

Pairwise distances
rotate.im

Rotate a Pixel Image
pixelcentres

Extract Pixel Centres as Point Pattern
pointsOnLines

Place Points Evenly Along Specified Lines
vertices

Vertices of a Window
colourmap

Colour Lookup Tables
perspPoints

Draw Points or Lines on a Surface Viewed in Perspective
transmat

Convert Pixel Array Between Different Conventions
plot.imlist

Plot a List of Images
triangulate.owin

Decompose Window into Triangles
concatxy

Concatenate x,y Coordinate Vectors
crossdist.psp

Pairwise distances between two different line segment patterns
connected

Connected components
crossdist.default

Pairwise distances between two different sets of points
nearestValue

Image of Nearest Defined Pixel Value
crossdist.pp3

Pairwise distances between two different three-dimensional point patterns
trim.rectangle

Cut margins from rectangle
nncross.pp3

Nearest Neighbours Between Two Patterns in 3D
pairdist

Pairwise distances
weighted.median

Weighted Median, Quantiles or Variance
where.max

Find Location of Maximum in a Pixel Image
nnfun

Nearest Neighbour Index Map as a Function
rescale.im

Convert Pixel Image to Another Unit of Length
crossing.psp

Crossing Points of Two Line Segment Patterns
nncross.ppx

Nearest Neighbours Between Two Patterns in Any Dimensions
pairdist.psp

Pairwise distances between line segments
plot.im

Plot a Pixel Image
plot.textstring

Plot a Text String
nearestsegment

Find Line Segment Nearest to Each Point
unstack.solist

Unstack Each Spatial Object in a List of Objects
plot.pppmatching

Plot a Point Matching
grow.boxx

Add margins to box in any dimension
dilation

Morphological Dilation
ellipse

Elliptical Window.
shift.psp

Apply Vector Translation To Line Segment Pattern
endpoints.psp

Endpoints of Line Segment Pattern
dilated.areas

Areas of Morphological Dilations
selfcrossing.psp

Crossing Points in a Line Segment Pattern
polartess

Tessellation Using Polar Coordinates
nnmark

Mark of Nearest Neighbour
spatstat.geom-internal

Internal spatstat.geom functions
grow.rectangle

Add margins to rectangle
perimeter

Perimeter Length of Window
solist

List of Two-Dimensional Spatial Objects
print.im

Print Brief Details of an Image
periodify

Make Periodic Copies of a Spatial Pattern
nnwhich

Nearest neighbour
plot.quadratcount

Plot Quadrat Counts
ppp

Create a Point Pattern
ppp.object

Class of Point Patterns
rescale

Convert dataset to another unit of length
print.owin

Print Brief Details of a Spatial Window
rQuasi

Generate Quasirandom Point Pattern in Given Window
quad.object

Class of Quadrature Schemes
yardstick

Text, Arrow or Scale Bar in a Diagram
print.ppp

Print Brief Details of a Point Pattern Dataset
requireversion

Require a Specific Version of a Package
project2set

Find Nearest Point in a Region
scaletointerval

Rescale Data to Lie Between Specified Limits
quasirandom

Quasirandom Patterns
ppx

Multidimensional Space-Time Point Pattern
relevel.im

Reorder Levels of a Factor-Valued Image or Pattern
pppmatching.object

Class of Point Matchings
psp

Create a Line Segment Pattern
nestsplit

Nested Split
has.close

Check Whether Points Have Close Neighbours
rgbim

Create Colour-Valued Pixel Image
is.convex

Test Whether a Window is Convex
harmonise.owin

Make Windows Compatible
methods.boxx

Methods for Multi-Dimensional Box
unmark

Remove Marks
incircle

Find Largest Circle Inside Window
infline

Infinite Straight Lines
plot.psp

plot a Spatial Line Segment Pattern
square

Square Window
rescale.ppp

Convert Point Pattern to Another Unit of Length
persp.im

Perspective Plot of Pixel Image
plot.colourmap

Plot a Colour Map
plot.ppp

plot a Spatial Point Pattern
plot.hyperframe

Plot Entries in a Hyperframe
is.empty

Test Whether An Object Is Empty
plot.pp3

Plot a Three-Dimensional Point Pattern
simplepanel

Simple Point-and-Click Interface Panels
rectdistmap

Distance Map Using Rectangular Distance Metric
summary.ppp

Summary of a Point Pattern Dataset
rotate.ppp

Rotate a Point Pattern
selfcut.psp

Cut Line Segments Where They Intersect
solutionset

Evaluate Logical Expression Involving Pixel Images and Return Region Where Expression is True
print.psp

Print Brief Details of a Line Segment Pattern Dataset
round.ppp

Apply Numerical Rounding to Spatial Coordinates
ripras

Estimate window from points alone
subset.ppp

Subset of Point Pattern Satisfying A Condition
pp3

Three Dimensional Point Pattern
rotate.psp

Rotate a Line Segment Pattern
with.hyperframe

Evaluate an Expression in Each Row of a Hyperframe
layout.boxes

Generate a Row or Column Arrangement of Rectangles.
scanpp

Read Point Pattern From Data File
subset.hyperframe

Subset of Hyperframe Satisfying A Condition
progressreport

Print Progress Reports
layerplotargs

Extract or Replace the Plot Arguments of a Layered Object
pppmatching

Create a Point Matching
plot.texturemap

Plot a Texture Map
rescale.owin

Convert Window to Another Unit of Length
summary.owin

Summary of a Spatial Window
regularpolygon

Create A Regular Polygon
quadratcount

Quadrat counting for a point pattern
scalardilate

Apply Scalar Dilation
raster.x

Cartesian Coordinates for a Pixel Raster
runifrect

Generate N Uniform Random Points in a Rectangle
unnormdensity

Weighted kernel smoother
marks.psp

Marks of a Line Segment Pattern
text.ppp

Add Text Labels to Spatial Pattern
test.crossing.psp

Check Whether Segments Cross
tiles

Extract List of Tiles in a Tessellation
methods.distfun

Geometrical Operations for Distance Functions
summary.solist

Summary of a List of Spatial Objects
shift

Apply Vector Translation
pairdist.ppx

Pairwise Distances in Any Dimensions
marks.tess

Marks of a Tessellation
nncross

Nearest Neighbours Between Two Patterns
stratrand

Stratified random point pattern
spatstat.geom-package

The spatstat.geom Package
tilenames

Names of Tiles in a Tessellation
zapsmall.im

Rounding of Pixel Values
timeTaken

Extract the Total Computation Time
print.quad

Print a Quadrature Scheme
rescale.psp

Convert Line Segment Pattern to Another Unit of Length
summary.quad

Summarizing a Quadrature Scheme
sidelengths.owin

Side Lengths of Enclosing Rectangle of a Window
shift.ppx

Apply Vector Translation To Box Or Point Pattern In Arbitrary Dimension
summary.anylist

Summary of a List of Things
shift.im

Apply Vector Translation To Pixel Image
tiles.empty

Check For Empty Tiles in a Tessellation
nndist.psp

Nearest neighbour distances between line segments
rounding

Detect Numerical Rounding
nndist.ppx

Nearest Neighbour Distances in Any Dimensions
split.im

Divide Image Into Sub-images
split.ppp

Divide Point Pattern into Sub-patterns
summary.psp

Summary of a Line Segment Pattern Dataset
summary.listof

Summary of a List of Things
opening

Morphological Opening
pairdist.ppp

Pairwise distances
plot.anylist

Plot a List of Things
overlap.owin

Compute Area of Overlap
tile.areas

Compute Areas of Tiles in a Tessellation
tileindex

Determine Which Tile Contains Each Given Point
split.ppx

Divide Multidimensional Point Pattern into Sub-patterns
tweak.colourmap

Change Colour Values in a Colour Map
subset.psp

Subset of Line Segment Satisfying A Condition
tess

Create a Tessellation
symbolmap

Graphics Symbol Map
unstack.ppp

Separate Multiple Columns of Marks
union.quad

Union of Data and Dummy Points
uniquemap.ppp

Map Duplicate Entries to Unique Entries
timed

Record the Computation Time
update.symbolmap

Update a Graphics Symbol Map.
unitname

Name for Unit of Length
venn.tess

Tessellation Delimited by Several Sets
pixelquad

Quadrature Scheme Based on Pixel Grid
spatstat.options

Internal Options in Spatstat Package
rescue.rectangle

Convert Window Back To Rectangle
plot.symbolmap

Plot a Graphics Symbol Map
plot.tess

Plot a Tessellation
setcov

Set Covariance of a Window
shift.ppp

Apply Vector Translation To Point Pattern
quadrats

Divide Region into Quadrats
rotate.infline

Rotate or Shift Infinite Lines
whichhalfplane

Test Which Side of Infinite Line a Point Falls On
quadscheme

Generate a Quadrature Scheme from a Point Pattern
rotate.owin

Rotate a Window
summary.splitppp

Summary of a Split Point Pattern
sessionLibs

Print Names and Version Numbers of Libraries Loaded
unique.ppp

Extract Unique Points from a Spatial Point Pattern
split.hyperframe

Divide Hyperframe Into Subsets and Reassemble
shift.owin

Apply Vector Translation To Window
whist

Weighted Histogram
superimpose

Superimpose Several Geometric Patterns
uniquemap.default

Map Duplicate Entries to Unique Entries
Extract.hyperframe

Extract or Replace Subset of Hyperframe