pinskylab / OceanAdapt

Scripts and data for OceanAdapt website to visualize shifts in marine animal distributions
http://oceanadapt.rutgers.edu
MIT License
13 stars 6 forks source link

NEUS AREA column misinterpreted as numerical value #151

Open zoekitchel opened 2 years ago

zoekitchel commented 2 years ago

I believe that the AREA column from the neus_season_svstra.csv files is being interpretted incorrectly. It refers to "Standard area code used for commercial data (New England Statistical Area Code) for the position of the beginning of the tow." as described in the metadata. However, in line 1532 of compile.R, this value is divided by 1000000, implying that it is being interpretted as m^2.

neus_fall <- neus_fall %>% mutate(stratum = as.double(stratum), latitude = as.double(lat), longitude = as.double(lon), depth = as.double(depth), wgt = as.double(wgt), year = as.double(year), haul_dur = as.numeric(TOWDUR), quarter = case_when(month %in% c(1,2,3) ~ 1, month %in% c(4,5,6) ~ 2, month %in% c(7,8,9) ~ 3, month %in% c(10,11,12) ~ 4), season = "Fall", SVSPP = as.double(SVSPP), area = AREA/1000000)