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

flipxy

Exchange X and Y Coordinates


Description

Exchanges the x and y coordinates in a spatial dataset.

Usage

flipxy(X)
 ## S3 method for class 'owin'
flipxy(X)
 ## S3 method for class 'ppp'
flipxy(X)
 ## S3 method for class 'psp'
flipxy(X)
 ## S3 method for class 'im'
flipxy(X)

Arguments

X

Spatial dataset. An object of class "owin", "ppp", "psp" or "im".

Details

This function swaps the x and y coordinates of a spatial dataset. This could also be performed using the command affine, but flipxy is faster.

The function flipxy is generic, with methods for the classes of objects listed above.

Value

Another object of the same type, representing the result of swapping the x and y coordinates.

Author(s)

and Rolf Turner r.turner@auckland.ac.nz

See Also

Examples

data(cells)
  X <- flipxy(cells)

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.