Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

hist.funxy

Histogram of Values of a Spatial Function


Description

Computes and displays a histogram of the values of a spatial function of class "funxy".

Usage

## S3 method for class 'funxy'
hist(x, ..., xname)

Arguments

x

A pixel image (object of class "funxy").

...

Arguments passed to as.im or hist.im.

xname

Optional. Character string to be used as the name of the dataset x.

Details

This function computes and (by default) displays a histogram of the values of the function x.

An object of class "funxy" describes a function of spatial location. It is a function(x,y,..) in the R language, with additional attributes.

The function hist.funxy is a method for the generic function hist for the class "funxy".

The function is first converted to a pixel image using as.im, then hist.im is called to produce the histogram.

Any arguments in ... are passed to as.im to determine the pixel resolution, or to hist.im to determine the histogram breaks and to control or suppress plotting. Useful arguments include W for the spatial domain, eps,dimyx for pixel resolution, main for the main title.

Value

An object of class "histogram" as returned by hist.default. This object can be plotted.

Author(s)

Adrian Baddeley Adrian.Baddeley@curtin.edu.au, Rolf Turner r.turner@auckland.ac.nz and Ege Rubak rubak@math.aau.dk.

See Also

spatialcdf for the cumulative distribution function of an image or function.

For other statistical graphics such as Q-Q plots, use as.im(X)[] to extract the pixel values of image X, and apply the usual statistical graphics commands.

Examples

f <- funxy(function(x,y) {x^2}, unit.square())
  hist(f)

spatstat.geom

Geometrical Functionality of the 'spatstat' Family

v2.1-0
GPL (>= 2)
Authors
Adrian Baddeley [aut, cre], Rolf Turner [aut], Ege Rubak [aut], Tilman Davies [ctb], Ute Hahn [ctb], Abdollah Jalilian [ctb], Sebastian Meyer [ctb], Suman Rakshit [ctb], Dominic Schuhmacher [ctb], Rasmus Waagepetersen [ctb]
Initial release
2021-04-15

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.