fitzLab-AL / gdm

R package for Generalized Dissimilarity Modeling
GNU General Public License v3.0
33 stars 12 forks source link

formatsiterepair undefined columns #20

Closed njm-data closed 2 years ago

njm-data commented 2 years ago

Hi! I'm trying to produce a gdm with presence/absence data that I have and this is the issue that I am having.

This is the command that I am running, and the error that I get: gdmtab <- formatsitepair(bioData = spp, bioFormat = 2, XColumn="Longitude", YColumn="Latitude", sppColumn = "Trait", site= "zone", predData = env) No abundance column was specified, so the species data are assumed to be presences.Aggregation function missing: defaulting to length cannot xtfrm data framesError in[.data.frame(envInfo, , "siteUltimateCoolness") : undefined columns selected Here is the head of my biodata: head(spp) Longitude Latitude Trait zone 1 -110.3976 31.46074 n A 2 -104.0201 30.65312 n W 3 -109.2110 31.89133 y B 4 -109.2393 31.87379 y B 5 -107.4298 28.77738 y BB 6 -105.7348 28.92134 n CC

Trait is the y/n of having the trait, and the zone is the locality found. My environment data is worldclim, elevation, Latitude, Longitude. Do you have any suggestions for how to address this issue? Thanks!

fitzLab-AL commented 2 years ago

The formatsitepair function is not designed to handle data in the format you are using. Please see the help documents.