Learn R Programming

secr (version 1.3.0)

rotate.traps: Rotate Detectors

Description

Rotate detectors while retaining other attributes.

Usage

## S3 method for class 'traps':
rotate(object, degrees, centrexy = NULL, \dots)

Arguments

object
object of class traps
degrees
clockwise angle of rotation in degrees
centrexy
vector with x,y coordinates of point about which to rotate
...
other arguments (not used).

Value

  • An object of class traps with the location of each detector rotated about the centre.

Details

May be used with rbind.traps and shift.traps to create complex geometries.

See Also

traps, shift.traps

Examples

Run this code
hollow1 <- make.grid(nx = 8, ny = 8, hollow = TRUE)
hollow2 <- make.grid(nx = 8, ny = 8, hollow = TRUE)
nested <- rbind (hollow1, rotate(hollow2, 45, c(70, 70)))
plot(nested, gridlines = FALSE)

Run the code above in your browser using DataLab