Description Usage Arguments Details Value Author(s) References See Also Examples
Performs a multivariate analysis of ecological data (Kselect analysis).
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15  kselect(dudi, factor, weight, scannf = TRUE, nf = 2, ewa = FALSE)
## S3 method for class 'kselect'
print(x, ...)
## S3 method for class 'kselect'
kplot(object, xax = 1, yax = 2, csub = 2, possub = c("topleft",
"bottomleft", "bottomright", "topright"),
addval = TRUE, cpoint = 1, csize = 1, clegend = 2, ...)
## S3 method for class 'kselect'
hist(x, xax = 1, mar=c(0.1,0.1,0.1,0.1),
ncell=TRUE, csub=2,
possub=c("bottomleft", "topleft",
"bottomright", "topright"),
ncla=15, ...)
## S3 method for class 'kselect'
plot(x, xax = 1, yax = 2, ...)

dudi 
an object of class 
factor 
a factor with the same length as 
weight 
a numeric vector of integer values giving the weight
associated to the rows of 
scannf 
logical. Whether the eigenvalues bar plot should be displayed 
nf 
if 
ewa 
logical. If 
x, object 
an object of class 
xax 
the column number for the xaxis 
yax 
the column number for the yaxis 
addval 
logical. If 
cpoint 
the size of the points (if 0, the points where no relocations are found are not displayed) 
mar 
the margin parameter (see 
ncell 
logical. If 
csub 
the character size for the legend, used with

csize 
the size coefficient for the points 
clegend 
the character size for the legend used by

possub 
a character string indicating the subtitle position

ncla 
the number of classes of the histograms 
... 
additional arguments to be passed to the generic function

The Kselect analysis is intended for hindcasting studies of habitat
selection by animals using radiotracking data. Each habitat variable
defines one dimension in the ecological space. For each animal, the
difference between the vector of average available habitat conditions
and the vector of average used conditions defines the marginality
vector. Its size is proportional to the importance of habitat
selection, and its direction indicates which variables are
selected. By performing a noncentered principal component analysis of
the table containing the coordinates of the marginality vectors of
each animal (row) on the habitat variables (column), the Kselect
analysis returns a linear combination of habitat variables for which
the average marginality is greatest. It is a synthesis of variables
which contributes the most to the habitat selection. As with principal
component analysis, the biological significance of the factorial axes is
deduced from the loading of variables.
plot.kselect
returns a summary of the analysis: it displays (i)
a graph of the correlations between the principal axes of the PCA of
the objects of class dudi
passed as argument and the factorial
axes of the Kselect analysis; (ii) a graph giving the scores of the
habitat variables on the factorial axes of the Kselect analysis;
(iii) the barplot of the eigenvalues of the analysis (each eigenvalue
measure the mean marginality explained by the axis; (iv) the
projection of the nonrecentred marginality vectors on the factorial
plane (the origin of the arrow indicates the average available habitat
conditions, and the end of the arrow indicates the average used
conditions); (v) the projection of the resource units available to
each animal on the first factorial plane and (vi) the coordinates of
the recentred marginality vectors (i.e. recentred so that they have a
common origin) on the first factorial plane.
kplot.kselect
returns one graph per animal showing the
projections of the available resource units on the factorial plane, as
well as their use by the animal. hist.kselect
does the same
thing, but on one dimension instead of two.
kselect
returns a list of the class kselect
and
dudi
(see dudi
).
Clement Calenge [email protected]
Calenge, C., Dufour, A.B. and Maillard, D. (2005) Kselect analysis: a new method to analyse habitat selection in radiotracking studies. Ecological modelling, 186, 143–153.
sahrlocs2kselect
for
conversion of objects class sahrlocs
to objects suitable for a
Kselect analysis, s.distri
, and
dudi
for class dudi
.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51  ## Not run:
## Loads the data
data(puechabon)
sahr < puechabon$sahr
## prepares the data for the kselect analysis
x < sahrlocs2kselect(sahr)
tab < x$tab
## Example of analysis with two variables: the slope and the elevation.
## Have a look at the use and availability of the two variables
## for the 4 animals
tab < tab[,((names(tab) == "Slope")(names(tab) == "Elevation"))]
tab < scale(tab)
tmp < split.data.frame(tab, x$factor)
wg < split(x$weight, x$factor)
opar < par(mfrow = n2mfrow(nlevels(x$factor)))
for (i in names(tmp))
s.distri(scale(tmp[[i]]), wg[[i]])
par(opar)
## We call a new graphic window
x11()
## A Kselect analysis
acp < dudi.pca(tab, scannf = FALSE, nf = 2)
kn < kselect(acp, x$factor, x$weight,
scannf = FALSE, nf = 2)
# use of the generic function scatter
scatter(kn)
# Displays the first factorial plane
kplot(kn)
kplot(kn, cellipse = 0, cpoint = 0)
kplot(kn, addval = FALSE, cstar = 0)
# this factorial plane can be compared with
# the other graph to see the rotation proposed by
# the analysis
graphics.off()
# Displays the first factorial axis
hist(kn)
# Displays the second factorial axis
hist(kn, xax = 2)
# Summary of the analysis
plot(kn)
## End(Not run)

Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.