Learn R Programming

transport (version 0.15-4)

pgrid-object: Class of Pixel Grids

Description

The class "pgrid" (for pixel grid) represents regular quantizations of measures on (bounded subsets of) \(R^d\). Currently only square quantizations of measures on a rectangles are supported, which in 2-d can be thought of as grey scale images.

Arguments

Author

Dominic Schuhmacher dschuhm1@uni-goettingen.de

Details

Objects of class "pgrid" can be created by the function pgrid, and are most commonly used as input to the function transport. There are methods plot, print and summary for this class.

An object of class "pgrid" contains the following elements:

structurethe structure of the grid. Currently only "square" and "rectangular" are supported.
dimensionthe dimension \(d\) of the space in which the grid is embedded. Must be \(\geq 2\).
nthe number of pixels along the various coordinates, a vector of length dimension.
Nthe total number of pixels.
boundarythe outer boundary of the "picture" (i.e. of the support of the measure). A vector of
length 2*dimension, where the odd entries contain the left and the even entries
contain the right endpoints of the various coordinates.
gridtriplethe rule for generating the pixel centres along the various coordinates.
A dim by 3 matrix where each row is of the form c(start, end, step).
generatorsthe pixel centres along the various coordinates. A list of length dim where the
i-th element is a vector of length n[i].
massthe array of masses in each pixel / at each pixel centre. In 2-d orientation corresponds
to the standard orientation of images, see e.g. image. This means that
pixels are arranged on coordinate axes in the order of their indices.

See Also

Constructor function pgrid.