## Loads the data
data(puechabon)
sahr <- puechabon$sahr
## prepares the data for the kselect analysis: only two variables are kept
x <- sahrlocs2kselect(sahr)
tab <- x$tab
dud <- dudi.mix(tab, scannf = FALSE, nf = 2)
## the randomisation tests
## be patient, this can be very long on some machines
(te <- rand.kselect(dud, x$factor, x$weight, nrep = 50))
Run the code above in your browser using DataLab