Skip to content

Commit

Permalink
version 1.8.5
Browse files Browse the repository at this point in the history
  • Loading branch information
Clement Calenge authored and gaborcsardi committed May 4, 2009
1 parent 96040fe commit 16812e5
Show file tree
Hide file tree
Showing 10 changed files with 58 additions and 58 deletions.
Empty file removed .Rbuildindex.8939
Empty file.
6 changes: 3 additions & 3 deletions DESCRIPTION
@@ -1,5 +1,5 @@
Package: adehabitat
Version: 1.8.4
Version: 1.8.5
Date: 2009/05/04
Title: Analysis of habitat selection by animals
Author: Clement Calenge, contributions from Mathieu Basille, Stephane
Expand All @@ -11,6 +11,6 @@ Description: A collection of tools for the analysis of habitat
selection by animals
License: GPL (>= 2)
URL: https://www.faunalia.it/animove/trac/
Packaged: 2011-03-18 13:46:16 UTC; calenge
Packaged: 2011-04-17 10:56:14 UTC; calenge
Repository: CRAN
Date/Publication: 2011-03-19 06:18:30
Date/Publication: 2011-04-24 06:05:37
2 changes: 1 addition & 1 deletion R/explore.kasc.r
Expand Up @@ -169,7 +169,7 @@ explore.kasc <- function (ka, coltxt="blue",
return("OK - Finished")
}
if (key == "z") {
tmppx <- (get("cusr", envi=e1)[1:2] - get("cusr", envir=e1)[1])
tmppx <- (get("cusr", envir=e1)[1:2] - get("cusr", envir=e1)[1])
assign("xlim", c(get("a8", envir=e1)[1] - tmppx[2]/4, (get("a8", envir=e1)[1] + tmppx[2]/4)), envir=e1)
assign("tmppy", (get("cusr", envir=e1)[3:4] - get("cusr", envir=e1)[3]), envir=e1)
assign("ylim", c(get("a8", envir=e1)[2] - get("tmppy", envir=e1)[2]/4, (get("a8", envir=e1)[2] + get("tmppy", envir=e1)[2]/4)), envir=e1)
Expand Down
2 changes: 1 addition & 1 deletion R/gnesfa.r
Expand Up @@ -36,7 +36,7 @@ gnesfa <- function(dudi, Focus, Reference, centering = c("single", "twice"),
## First PCA
rank <- dudi$rank
pc1 <- dudi.pca(Z, center=FALSE, scale=FALSE,
row.w=Reference, nf=rank, scann=FALSE)
row.w=Reference, nf=rank, scannf=FALSE)
c1 <- as.matrix(pc1$c1)
L <- sweep(Z%*%c1,2,sqrt(pc1$eig),"/")

Expand Down
2 changes: 1 addition & 1 deletion R/kplot.kselect.r
Expand Up @@ -51,7 +51,7 @@
csub=1.5, cgrid=1.5, csize=csi[i])
}
s.distri(Xtmp, wgtmp, xax, yax,
sub=names(li.Xi)[i], add.p=addval,
sub=names(li.Xi)[i], add.plot=addval,
cpoint=cpoint, xlim=rx, ylim=ry,
...)
}
Expand Down
10 changes: 5 additions & 5 deletions R/madifa.r
Expand Up @@ -457,11 +457,11 @@ s.madifa <- function(x, xax=1, yax=2, cgrid = 1, clab=1, ...)
po <- rbind(as.matrix(pol),yy)

## Draws the plot
s.arrow(co, xax=xax, yax=yax, xlim=c(-1,1), ylim=c(-1,1), clab=clab)
s.arrow(co, xax=xax, yax=yax, xlim=c(-1,1), ylim=c(-1,1), clabel=clab)
polygon(yy)
polygon(po, col="white")
s.arrow(co, xax=xax, yax=yax, xlim=c(-1,1), ylim=c(-1,1), add.p=TRUE,
clab=clab, ...)
s.arrow(co, xax=xax, yax=yax, xlim=c(-1,1), ylim=c(-1,1), add.plot=TRUE,
clabel=clab, ...)

## scale box
xaxp <- par("xaxp")
Expand Down Expand Up @@ -498,7 +498,7 @@ plot.madifa <- function(x, index, attr, xax=1, yax=2, cont=FALSE,...)
scatterutil.eigen(x$eig, wsel = c(xax, yax))

## Column scores
s.madifa(x, xax, yax, cgrid=2, clab=1.25)
s.madifa(x, xax, yax, cgrid=2, clabel=1.25)


## function to draw the niche
Expand Down Expand Up @@ -565,7 +565,7 @@ plot.madifa <- function(x, index, attr, xax=1, yax=2, cont=FALSE,...)
## Correlation with the environmental variables
s.arrow(x$cor, xax=xax,yax=yax,
sub="Cor(habitat var., scores) available",
clab=1.25, csub=2, cgrid=2, xlim=c(-1,1), ylim=c(-1,1))
clabel=1.25, csub=2, cgrid=2, xlim=c(-1,1), ylim=c(-1,1))
u <- par(mar=c(0.1,0.1,2,0.1))

## Again the maps
Expand Down
12 changes: 6 additions & 6 deletions R/plot.kselect.r
Expand Up @@ -20,11 +20,11 @@
par(mar = c(0.1, 0.1, 0.1, 0.1))

## 1. correlations between the PCA axes and the K-select axes
s.corcircle(x$as, xax, yax, sub = "Axis", csub = 2, clab = 1.25)
s.corcircle(x$as, xax, yax, sub = "Axis", csub = 2, clabel = 1.25)

## 2. scores of the environmental variables on the
## K-select axes (eigenvectors)
s.arrow(x$l1, xax, yax, sub = "Variables", csub = 2, clab = 1.25)
s.arrow(x$l1, xax, yax, sub = "Variables", csub = 2, clabel = 1.25)

## 3. the eigenvalues of the analysis
scatterutil.eigen(x$eig, wsel = c(xax, yax))
Expand All @@ -46,23 +46,23 @@
## 4.4. The Marginality vectors are displayed as arrows connecting the
## "available" centroids to the "used" centroids

s.label(rbind(mav, mut), xax, yax, clab = 0, cpo = 0,
s.label(rbind(mav, mut), xax, yax, clabel = 0, cpoint = 0,
sub = "Marginality vectors", csub = 2) ## background
for (i in 1:nrow(mav))
arrows(mav[i,xax], mav[i,yax], mut[i,xax], mut[i,yax],
lwd=2, angle=20) ## arrows
s.label(mav, xax, yax, add.plot=TRUE, clab=1.5) ## labels
s.label(mav, xax, yax, add.plot=TRUE, clabel=1.5) ## labels


## 5. coordinates of the uncentered available points on the
## axes of the K-select
s.chull(as.data.frame(ls), x$initfac,
clab=1.5, sub="Available Resource units", csub=2,
clabel=1.5, sub="Available Resource units", csub=2,
optchull=1, cpoint=1)

## 6. coordinates of the recentred marginality vectors on the axes
## on the K-select
s.arrow(x$co, xax, yax, clab = 1.25, cpo = 0.5, sub = "Animals",
s.arrow(x$co, xax, yax, clabel = 1.25, cpoint = 0.5, sub = "Animals",
csub = 2)

}
Expand Down
2 changes: 1 addition & 1 deletion R/simm.mba.r
Expand Up @@ -8,7 +8,7 @@
stop("matrix 2*2 expected")
if (sum((t(sigma)-sigma)^2)> 1e-7)
stop("symetric matrix expected")
if (any(eigen(sigma, sym=TRUE)$value< -1e-7))
if (any(eigen(sigma, symmetric=TRUE)$value< -1e-7))
stop("positive matrix expected")

n <- length(date)
Expand Down
2 changes: 1 addition & 1 deletion R/simm.mou.r
Expand Up @@ -10,7 +10,7 @@ function(date=1:100, b = c(0,0), a = diag(0.5,2),
stop("matrix 2*2 expected")
if (sum((t(sigma)-sigma)^2)> 1e-7)
stop("symetric matrix expected")
if (any(eigen(sigma, sym=TRUE)$value< -1e-7))
if (any(eigen(sigma, symmetric=TRUE)$value< -1e-7))
stop("positive matrix expected")

n <- length(date)
Expand Down

0 comments on commit 16812e5

Please sign in to comment.