Closed pwinner1 closed 6 years ago
This was occurring because there was a reference to "Prey_Name_Status" field which no longer exists. All code now references the "Prey_Name_ITIS_ID" field instead.
I also made sure the problematic names were propagating properly (say that 3 times fast).
The clean_all_names function should work now on the Cooper_1993 datafile.
When I use clean_all_names, this error appears
[1] "1 out of 1"
Retrieving data for taxon 'Heteroptera'
Error in
$<-.data.frame
(*tmp*
, "Prey_Name_Status", value = c(NA, NA, : replacement has 178 rows, data has 180stop(sprintf(ngettext(N, "replacement has %d row, data has %d", "replacement has %d rows, data has %d"), N, nrows), domain = NA)
$<-.data.frame
(*tmp*
, "Prey_Name_Status", value = c(NA, NA, NA, NA, NA, NA, NA, "103358", NA, NA, NA, NA, NA, NA, NA, NA, NA, "103358", NA, NA, NA, NA, NA, NA, NA, NA, NA, "103358", NA, NA, NA, NA, NA, NA, NA, NA, NA, "103358", NA, NA, NA, NA, NA, ... at prey_name_cleaning.R#168$<-
(*tmp*
, "Prey_Name_Status", value = c(NA, NA, NA, NA, NA, NA, NA, "103358", NA, NA, NA, NA, NA, NA, NA, NA, NA, "103358", NA, NA, NA, NA, NA, NA, NA, NA, NA, "103358", NA, NA, NA, NA, NA, NA, NA, NA, NA, "103358", NA, NA, NA, NA, NA, NA, NA, NA, ... at prey_name_cleaning.R#168clean_names("Suborder", clean_fam$diet, all = TRUE, problemNames = clean_fam$badnames) at database_error_checking.R#323
clean_all_names(dietdb)