# NOT RUN {
data(PAM) # Phyllomedusa presence-absence matrix
require(maptools)
data(wrld_simpl) # World map
Brazil <- wrld_simpl[wrld_simpl$NAME == "Brazil", ] # Brazil (polygon)
# Check where is the variable name
# (in this case it is in "NAME" which will be my z value)
names(Brazil)
PAM_pol <- lets.addpoly(PAM, Brazil, "NAME")
# }
# NOT RUN {
# }
Run the code above in your browser using DataLab