ascgen: Creation of Raster Maps

Description Usage Arguments Value Author(s) See Also Examples

Description

ascgen creates an object of class asc using a set of points.

Usage

1
ascgen(xy = NULL, cellsize = NULL, nrcol = 10, count = TRUE)

Arguments

xy

a data frame with two columns containing the x and y coordinates of the points

cellsize

the cellsize attribute of the object of class asc to be created

nrcol

the size of the square raster map to be created (number of rows and columns)

count

logical. If TRUE, the object of class asc contains the number of points in each cell. If FALSE, all the cells are set to zero

Value

Returns an object of class asc.

Author(s)

Clement Calenge clement.calenge@oncfs.gouv.fr

See Also

asc for additional information on objects of class asc.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
data(puechabon)
lo <- puechabon$locs[,c("X","Y")]
plot(lo, asp = 1, pch = 16)

## lo contains the relocations of wild boars
rast <- ascgen(lo, cellsize = 100)
image(rast)

## Alternatively, one can specify the size of the square raster map
rast <- ascgen(lo, nrcol = 10)
rast
image(rast)

## can be used for further analyses
## (e.g. correspondence analyses)
locs <- puechabon$locs[, c("Name", "X", "Y")]
o <- count.points.id(locs[,2:3], locs[,1], rast)
image(o)

adehabitat documentation built on Jan. 28, 2018, 5:02 p.m.