Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

'EVALID' not found error using 'readFIA' from file & using 'getFIA' for multiple states #35

Open
malloryb opened this issue Oct 26, 2022 · 7 comments

Comments

@malloryb
Copy link

Tried to read in FIA data from my local computer by pointing to the directory containing .csv files for a single state, and by downloading the data via 'getFIA'. Both throw errors: 'object 'EVALID' not found'. Tried multiple states (always just one at a time) - MI, WI, and IN, and got the same.

Thanks for making this helpful package!

@khs9461
Copy link

khs9461 commented Oct 27, 2022

Yes, I got the same error.

@whalend
Copy link
Contributor

whalend commented Oct 27, 2022

Could you provide a reproducible example of your code and sessionInfo() for R to help with troubleshooting?

The error message looks like it is syntax so this will help with whether it is the evaluation of the code you’ve input or the underlying function code.

@khs9461
Copy link

khs9461 commented Oct 28, 2022

My code:

library(rFIA)
options(timeout=606024*30) # 30 days.

getwd()
ct <- getFIA(states = 'RI')


My sessionInfo:

R version 4.2.0 (2022-04-22 ucrt)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 10 x64 (build 22000)

Matrix products: default

locale:
[1] LC_COLLATE=Korean_Korea.utf8 LC_CTYPE=Korean_Korea.utf8 LC_MONETARY=Korean_Korea.utf8
[4] LC_NUMERIC=C LC_TIME=Korean_Korea.utf8

attached base packages:
[1] stats graphics grDevices utils datasets methods base

other attached packages:
[1] rFIA_1.0.1

loaded via a namespace (and not attached):
[1] tidyselect_1.1.2 remotes_2.4.2 purrr_0.3.4 sf_1.0-8 colorspace_2.0-3
[6] vctrs_0.4.1 generics_0.1.2 usethis_2.1.6 utf8_1.2.2 rlang_1.0.3
[11] pkgbuild_1.3.1 e1071_1.7-11 pillar_1.7.0 glue_1.6.2 withr_2.5.0
[16] DBI_1.1.3 bit64_4.0.5 sessioninfo_1.2.2 lifecycle_1.0.1 stringr_1.4.0
[21] munsell_0.5.0 gtable_0.3.0 devtools_2.4.3 memoise_2.0.1 callr_3.7.0
[26] fastmap_1.1.0 ps_1.7.1 parallel_4.2.0 curl_4.3.2 class_7.3-20
[31] fansi_1.0.3 Rcpp_1.0.8.3 KernSmooth_2.23-20 scales_1.2.0 classInt_0.4-7
[36] cachem_1.0.6 pkgload_1.3.0 fs_1.5.2 bit_4.0.4 ggplot2_3.3.6
[41] stringi_1.7.6 processx_3.6.1 dplyr_1.0.9 grid_4.2.0 cli_3.3.0
[46] tools_4.2.0 magrittr_2.0.3 proxy_0.4-27 tibble_3.1.7 dtplyr_1.2.1
[51] tidyr_1.2.0 crayon_1.5.1 pkgconfig_2.0.3 ellipsis_0.3.2 data.table_1.14.2
[56] prettyunits_1.1.1 assertthat_0.2.1 rstudioapi_0.13 R6_2.5.1 units_0.8-0
[61] compiler_4.2.0

@khs9461
Copy link

khs9461 commented Oct 28, 2022

and it shows following error:

Error in dplyr::mutate():
! Problem while computing END_INVYR = dplyr::case_when(...).
Caused by error in EVALID %in% c(561800, 561801, 561803, 561807):
! object 'EVALID' not found
Run rlang::last_error() to see where the error occurred.

@hunter-stanke
Copy link
Owner

Believe I have this fixed. Datamart is now distributing csv's again, but all variable names are now lowercase (previously all uppercase). Easy fix, but I haven't had time to test thoroughly yet.

Can you please re-install from GitHub w/ remotes::install_github('hunter-stanke/rFIA') and confirm that fixes the read issues?

Thanks for reaching out, and thanks for jumping in here (+ other threads) @whalend. I apologize for the (severely) delayed replies on here. Doing my best to keep up.

@khs9461
Copy link

khs9461 commented Oct 28, 2022

Thank you for the quick reply!
I re-installed the rFIA, and "getFIA" function works now!

@hunter-stanke
Copy link
Owner

Ok cool - I've heard we're still having issues reading multiple states simultaneously, so I'll work on that tonight and follow up then.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants