# NOT RUN {
## The following example takes some time and will therefore not
## be run unless you type: example(isofind, run.dontrun=TRUE)
data(calibdata)
data(assigndata)
data(elevraster)
data(countries)
data(oceanmask)
data(Europefit)
## prepare the elevation raster
elevationraster <- relevate(
elevation.raster=elevraster,
isofit=Europefit)
## build the isoscape
isoscape <- isoscape(
elevation.raster=elevationraster,
isofit=Europefit)
## fit the calibration model
calib <- calibfit(
calib.data=calibdata,
isofit=Europefit)
## perform the assignment on land and water
assignment <- isofind(
assign.data=subset(assigndata,
species=="Myotis_bechsteinii"),
isoscape=isoscape,
calibfit=calib)
assignment
## perform the assignment on land only
assignment.dry <- isofind(
assign.data=subset(assigndata,
species=="Myotis_bechsteinii"),
isoscape=isoscape,
calibfit=calib,
mask=oceanmask)
## plot the group assignment
plot(assignment, who="group") ## without decoration
plot(assignment.dry, who="group") ## without decoration
plot(assignment.dry, who="group",
borders=list(borders=countries),
mask=list(mask=oceanmask))
## plot the assignment for the 4 first individuals
plot(assignment.dry, who=1:4,
borders=list(borders=countries),
mask=list(mask=oceanmask),
sources=list(draw=FALSE),
calib= list(draw=FALSE))
## plot the assignment for the individual "Mbe_8"
plot(assignment.dry, who="Mbe_8",
borders=list(borders=countries),
mask=list(mask=oceanmask))
# }
Run the code above in your browser using DataLab