circle.only: Define a circular habitat with constant value

Description Usage Arguments Value Examples

View source: R/habitat.R

Description

Create a circular habitat with a value of inside within a defined distance from the origin(0,0), and outside elsewhere.

Usage

1
circle.only(x, y, dist.inside = 50, inside = 1, outside = 0)

Arguments

x

x coordinate

y

y coordinate

dist.inside

Distance from the origin (0,0) with habitat value inside

inside

Value of habitat within dist.inside from the origin

outside

Value of habitat further than dist.inside from the origin

Value

Habitat value for each location. This function is used in conjunction with as.im to produce an image that defines the habitat.

Examples

1
2
3
hab.win <- owin(c(-50,50),c(-50,50),unitname="metres")
Z <- as.im(circle.only,hab.win,dist.inside=10,inside=0.8,outside=0.2)
plot(Z)

pwhigham/spatibm documentation built on Aug. 30, 2019, 1:16 p.m.