RandomPointConfiguration[pproc,reg]
generates a pseudorandom spatial point configuration from the spatial point process pproc in the observation region reg.
RandomPointConfiguration[pproc,reg, n]
generates an ensemble of n spatial point configurations.
RandomPointConfiguration
RandomPointConfiguration[pproc,reg]
generates a pseudorandom spatial point configuration from the spatial point process pproc in the observation region reg.
RandomPointConfiguration[pproc,reg, n]
generates an ensemble of n spatial point configurations.
Details and Options
- RandomPointConfiguration takes a point process pproc and generates a point configuration as a SpatialPointData object.
- RandomPointConfiguration gives a different realization of pseudorandom point configurations whenever you run the Wolfram Language. You can start with a particular seed using SeedRandom.
- The same process can generate an ensemble consisting of different realizations.
- The observation region reg needs to be a parameter-free region, as well as SpatialObservationRegionQ.
- The following options can be given:
-
Method Automatic what method to use WorkingPrecision MachinePrecision precision used in internal computations - With the setting WorkingPrecisionp, random numbers of precision p will be generated.
- Special settings for Method are documented under the individual point process reference pages.
- Typical Method settings include:
-
"MCMC" Markov chain Monte Carlo birth and death "Thinning" random thinning "Exact" coupling from the past
Examples
open all close allBasic Examples (3)
Sample from a Poisson point process:
pts = RandomPointConfiguration[PoissonPointProcess[10, 2], Disk[]]Show[RegionPlot[pts["ObservationRegion"]], ListPlot[pts]]Sample 5 realizations from a binomial point process:
reg = Ellipsoid[{1, 0, 0}, {1, 2, 3}];
pts = RandomPointConfiguration[BinomialPointProcess[10, reg], reg, 5]pts["ConfigurationCount"]pts["PointCountList"]Sample from a cluster point process defined on the surface of the Earth:
reg = Entity["Country", "Switzerland"]["Polygon"]proc = MaternPointProcess[Quantity[.005, "Kilometers" ^ -2], 30, Quantity[30, "Kilometers"], 2];pts = RandomPointConfiguration[proc, reg]PointValuePlot[pts]Scope (5)
RandomPointConfiguration returns a SpatialPointData object:
sample = RandomPointConfiguration[PoissonPointProcess[3, 3], Ball[]]Obtain a list of locations of the points:
sample["Points"]Simulate a Strauss point process in a rectangle:
proc = StraussPointProcess[20, 0.2, 0.2, 2];
data = RandomPointConfiguration[proc, Rectangle[{0, 0}, {4, 6}]]Retrieve points that lie within a unit disk centered at {2,3}:
data1 = SpatialPointData[data, Disk[{2, 3}]]Visualize points on the plane:
ListPlot[data]Estimate the parameters for a point process using a simulated point configuration:
data = RandomPointConfiguration[HardcorePointProcess[10, 0.1, 2], Disk[]];EstimatedPointProcess[data, HardcorePointProcess[mu, r, 2]]Simulate from a Cauchy point process:
proc = CauchyPointProcess[100, 50, 0.005, 2];
data = RandomPointConfiguration[proc, Triangle[]];ListPlot[data]Estimate Ripley's
function from the sampled point configuration and compare it with the theoretical
function:
kfun = RipleyK[data];Plot[{kfun[r], RipleyK[proc, r]}, {r, 0, 0.25}, PlotLegends -> {"Estimated", "Theoretical"}]Simulate an ensemble of 5 realizations over the same region:
data = RandomPointConfiguration[InhomogeneousPoissonPointProcess[Function[{x, y}, 2Exp[Sin[x - y]]], 2], Rectangle[{0, 0}, {10, 10}], 4];Number of points in each realization:
data["PointCountList"]Visualize the distribution of points in different realizations:
ListPlot[data]Options (3)
Method (2)
Sample from an InhomogeneousPoissonPointProcess using the different methods:
reg = Ellipsoid[{1, 0}, {2, 1.5}];proc = InhomogeneousPoissonPointProcess[Function[{x, y}, 2 * Exp[x + y]], 2];pts1 = RandomPointConfiguration[proc, reg, Method -> "Thinning"]Use the Markov chain Monte Carlo method "MCMC":
pts2 = RandomPointConfiguration[proc, reg, Method -> "MCMC"]Visualize samples over the region:
{Show[RegionPlot[reg], ListPlot[pts1]], Show[RegionPlot[reg], ListPlot[pts2]]}Sample from a Gibbs point process using the Markov chain Monte Carlo method "MCMC" with the number of iterations equal to 30000:
β = 10;h = Function[pts, β ^ Length[pts]];
region = Disk[];n = 20;sample = RandomPointConfiguration[GibbsPointProcess[h, 2], region, n, Method -> {"MCMC", "LengthOfRun" -> 30000}]Show[RegionPlot[sample["ObservationRegion"]], ListPlot[sample]]WorkingPrecision (1)
Generate a sample point configuration with default machine precision:
RandomPointConfiguration[PoissonPointProcess[3, 2], Disk[]]["Points"]Use WorkingPrecision to generate a sample point configuration with higher precision:
RandomPointConfiguration[PoissonPointProcess[3, 2], Disk[], WorkingPrecision -> 20]["Points"]Applications (2)
Estimate the density of a PoissonPointProcess from a sample:
β = 10;region = Disk[];
samples = RandomPointConfiguration[PoissonPointProcess[β, 2], region]N[μ /. FindPointProcessParameters[samples, PoissonPointProcess[μ, 2]]]Compare the expected point counts and the average of number of points for an inhomogeneous Poisson point process:
reg = Ellipsoid[{1, 0}, {1, 3}];
pts = RandomPointConfiguration[InhomogeneousPoissonPointProcess[Function[{x, y}, Exp[x + y]], 2], reg, 500, Method -> "Thinning"]{Integrate[Exp[x + y], {x, y}∈reg], Mean[pts["PointCountList"]]}//NRelated Guides
History
Text
Wolfram Research (2020), RandomPointConfiguration, Wolfram Language function, https://reference.wolfram.com/language/ref/RandomPointConfiguration.html.
CMS
Wolfram Language. 2020. "RandomPointConfiguration." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/RandomPointConfiguration.html.
APA
Wolfram Language. (2020). RandomPointConfiguration. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/RandomPointConfiguration.html
BibTeX
@misc{reference.wolfram_2026_randompointconfiguration, author="Wolfram Research", title="{RandomPointConfiguration}", year="2020", howpublished="\url{https://reference.wolfram.com/language/ref/RandomPointConfiguration.html}", note=[Accessed: 13-June-2026]}
BibLaTeX
@online{reference.wolfram_2026_randompointconfiguration, organization={Wolfram Research}, title={RandomPointConfiguration}, year={2020}, url={https://reference.wolfram.com/language/ref/RandomPointConfiguration.html}, note=[Accessed: 13-June-2026]}