-
Notifications
You must be signed in to change notification settings - Fork 19
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
loadReg corrupting the global environment #24
Comments
Well, the good news and bad news is that the above code doesn't corrupt my environment. I even tried downloading some non-CRAN/GRAN packages to match yours - I still can't reproduce the problem. At this point the only session_info difference I see is that I have Windows while you have Linux. So...maybe try one more time, restarting R and RStudio and ensuring that there is absolutely nothing being reloaded into your fresh session before you try the code again? You could also try reinstalling the Also, any history you can provide might help. Have you had these lines running well in the past? How long ago was that? Any guesses at which packages you've updated between when things worked and when they stopped working? session_info() Session info ------------------------------------------------------------------------------------------------------------------------------
setting value
version R version 3.4.1 (2017-06-30)
system x86_64, mingw32
ui RStudio (1.0.153)
language (EN)
collate English_United States.1252
tz America/Phoenix
date 2017-07-21
Packages ----------------------------------------------------------------------------------------------------------------------------------
package * version date source
akima 0.6-2 2016-12-20 CRAN (R 3.4.1)
assertthat 0.2.0 2017-04-11 CRAN (R 3.4.0)
base * 3.4.1 2017-06-30 local
bindr 0.1 2016-11-13 CRAN (R 3.4.1)
bindrcpp 0.2 2017-06-17 CRAN (R 3.4.1)
boot 1.3-19 2017-02-11 CRAN (R 3.4.1)
car 2.1-5 2017-07-04 CRAN (R 3.4.1)
codetools 0.2-15 2016-10-05 CRAN (R 3.4.1)
coin 1.2-1 2017-07-17 CRAN (R 3.4.1)
compiler 3.4.1 2017-06-30 local
curl 2.8.1 2017-07-21 CRAN (R 3.4.1)
dataRetrieval * 2.7.2 2017-05-23 CRAN (R 3.4.1)
datasets * 3.4.1 2017-06-30 local
devtools 1.13.2.9000 2017-07-21 Github (hadley/devtools@d3482c5)
digest 0.6.12 2017-01-27 CRAN (R 3.4.1)
dplyr 0.7.1.9000 2017-07-21 Github (tidyverse/dplyr@fa36b50)
glue 1.1.1 2017-06-21 CRAN (R 3.4.1)
graphics * 3.4.1 2017-06-30 local
grDevices * 3.4.1 2017-06-30 local
grid 3.4.1 2017-06-30 local
hms 0.3 2016-11-22 CRAN (R 3.4.1)
httr 1.2.1 2016-07-03 CRAN (R 3.4.1)
jsonlite 1.5 2017-06-01 CRAN (R 3.4.1)
KernSmooth 2.23-15 2015-06-29 CRAN (R 3.4.1)
lattice 0.20-35 2017-03-25 CRAN (R 3.4.1)
leaps 3.0 2017-01-10 CRAN (R 3.4.1)
lme4 1.1-13 2017-04-19 CRAN (R 3.4.1)
lubridate * 1.6.0 2016-09-13 CRAN (R 3.4.1)
magrittr 1.5 2014-11-22 CRAN (R 3.4.1)
MASS 7.3-47 2017-02-26 CRAN (R 3.4.1)
Matrix 1.2-10 2017-05-03 CRAN (R 3.4.1)
MatrixModels 0.4-1 2015-08-22 CRAN (R 3.4.1)
memoise 1.1.0 2017-04-21 CRAN (R 3.4.1)
methods * 3.4.1 2017-06-30 local
mgcv 1.8-17 2017-02-08 CRAN (R 3.4.1)
minqa 1.2.4 2014-10-09 CRAN (R 3.4.1)
modeltools 0.2-21 2013-09-02 CRAN (R 3.4.0)
multcomp 1.4-6 2016-07-14 CRAN (R 3.4.1)
mvtnorm 1.0-6 2017-03-02 CRAN (R 3.4.0)
NADA 1.6-1 2017-03-31 CRAN (R 3.4.1)
nlme 3.1-131 2017-02-06 CRAN (R 3.4.1)
nloptr 1.0.4 2014-08-04 CRAN (R 3.4.1)
nnet 7.3-12 2016-02-02 CRAN (R 3.4.1)
parallel 3.4.1 2017-06-30 local
pbkrtest 0.4-7 2017-03-15 CRAN (R 3.4.1)
pkgbuild 0.0.0.9000 2017-07-21 Github (r-pkgs/pkgbuild@8aab60b)
pkgconfig 2.0.1 2017-03-21 CRAN (R 3.4.1)
pkgload 0.0.0.9000 2017-07-21 Github (r-lib/pkgload@119cf9a)
plyr 1.8.4 2016-06-08 CRAN (R 3.4.1)
quantreg 5.33 2017-04-18 CRAN (R 3.4.1)
R6 2.2.2 2017-06-17 CRAN (R 3.4.1)
randtests 1.0 2014-11-17 CRAN (R 3.4.0)
Rcpp 0.12.12 2017-07-15 CRAN (R 3.4.1)
readr 1.1.1 2017-05-16 CRAN (R 3.4.1)
reshape2 1.4.2 2016-10-22 CRAN (R 3.4.1)
rlang 0.1.1.9000 2017-07-21 Github (hadley/rlang@ff87439)
rloadest * 0.4.4 2017-05-02 local
rstudioapi 0.6 2016-06-27 CRAN (R 3.4.1)
sandwich 2.3-4 2015-09-24 CRAN (R 3.4.1)
segmented 0.5-2.1 2017-06-14 CRAN (R 3.4.0)
smwrBase * 1.1.3 2017-07-21 Github (USGS-R/smwrBase@f7bef98)
smwrGraphs * 1.1.2 2017-07-21 Github (USGS-R/smwrGraphs@421d57d)
smwrQW * 0.7.12 2017-07-21 Github (USGS-R/smwrQW@dccd129)
smwrStats * 0.7.5 2017-07-21 Github (USGS-R/smwrStats@c442d28)
sp 1.2-5 2017-06-29 CRAN (R 3.4.1)
SparseM 1.77 2017-04-23 CRAN (R 3.4.0)
splines 3.4.1 2017-06-30 local
stats * 3.4.1 2017-06-30 local
stats4 3.4.1 2017-06-30 local
stringi 1.1.5 2017-04-07 CRAN (R 3.4.0)
stringr 1.2.0 2017-02-18 CRAN (R 3.4.1)
survival 2.41-3 2017-04-04 CRAN (R 3.4.1)
TH.data 1.0-8 2017-01-23 CRAN (R 3.4.1)
tibble 1.3.3 2017-05-28 CRAN (R 3.4.0)
tools 3.4.1 2017-06-30 local
truncnorm 1.0-7 2014-01-21 CRAN (R 3.4.0)
utils * 3.4.1 2017-06-30 local
withr 1.0.2 2016-06-20 CRAN (R 3.4.1)
XML 3.98-1.9 2017-06-19 CRAN (R 3.4.0)
xml2 1.1.1 2017-01-24 CRAN (R 3.4.1)
zCompositions 1.0.3-1 2016-04-14 CRAN (R 3.4.1)
zoo 1.8-0 2017-04-12 CRAN (R 3.4.1) |
That is really strange given that you have the exact same It took me quite some time (plenty of reloads and reinstalls) to pin down the cause of the error message so I'm positive that is not the issue. This is my first experience with the package so this is my first time running these lines. I think my next step is to try the package in a Docker environment to make absolutely sure the problem is not unique to my machine. |
Arg, I can't run
Traceback1: .Fortran("evalaml", NOBSC = as.integer(NOBSC), NPAR = as.integer(NPAR), XLCAL = as.matrix(X), YLCAL = Y@.Data[, 1L], YD = Y@.Data[, 2L], CENSFLAG = Y@censor.codes, PARMLE = double(NPAR + 1L), PARAML = double(NPAR + 1L), BIAS = double(NPAR + 1L), CV = matrix(0, NPAR + 1L, NPAR + 1L), SBIAS = double(NPAR + 1L), SCV = matrix(0, NPAR + 1L, NPAR + 1L), STDDEV = double(NPAR + 1L), PVAL = double(NPAR + 1L), COV = matrix(0, NPAR + 1L, NPAR + 1L), RESID = double(NOBSC), RSQ = double(1L), LLR = double(1L), SCORR = double(1L), LLRAML = double(1L), PLEVAML = double(1L), DF = integer(1L), LogNorm = dist == "lognormal", YPRED = double(NOBSC), AIC = double(1L), SPPC = double(1L), IERR = integer(1L)) 2: censReg_AMLE.fit(Y, X, "lognormal") 3: loadReg(Phosphorus ~ model(1), data = app1.calib, flow = "FLOW", dates = "DATES", conc.units = "mg/L", station = "Illinois River at Marseilles, Ill.") 4: eval(ei, envir) 5: eval(ei, envir) 6: withVisible(eval(ei, envir)) 7: source(tf, local, echo = echo, prompt.echo = paste0(prompt.prefix, getOption("prompt")), continue.echo = paste0(prompt.prefix, getOption("continue")), verbose = verbose, max.deparse.length = Inf, encoding = "UTF-8", skip.echo = skips, keep.source = TRUE) 8: example("loadReg", package = "rloadest")session_info
Session info ------------------------------------------------------------------
setting value
version R version 3.4.1 (2017-06-30)
system x86_64, linux-gnu
ui X11
language (EN)
collate en_US.UTF-8
tz UTC
date 2017-07-22
Packages ----------------------------------------------------------------------
package * version date source
akima 0.6-2 2016-12-20 cran (@0.6-2)
assertthat 0.2.0 2017-04-11 CRAN (R 3.4.1)
base * 3.4.1 2017-07-22 local
bindr 0.1 2016-11-13 CRAN (R 3.4.1)
bindrcpp 0.2 2017-06-17 CRAN (R 3.4.1)
boot 1.3-19 2017-04-21 cran (@1.3-19)
car 2.1-5 2017-07-04 cran (@2.1-5)
codetools 0.2-15 2016-10-05 CRAN (R 3.4.1)
coin 1.2-1 2017-07-17 cran (@1.2-1)
compiler 3.4.1 2017-07-22 local
curl 2.8.1 2017-07-21 CRAN (R 3.4.1)
dataRetrieval * 2.7.2 2017-05-23 cran (@2.7.2)
datasets * 3.4.1 2017-07-22 local
devtools 1.13.2 2017-06-02 CRAN (R 3.4.1)
digest 0.6.12 2017-01-27 CRAN (R 3.4.1)
dplyr 0.7.2 2017-07-20 CRAN (R 3.4.1)
glue 1.1.1 2017-06-21 CRAN (R 3.4.1)
graphics * 3.4.1 2017-07-22 local
grDevices * 3.4.1 2017-07-22 local
grid 3.4.1 2017-07-22 local
hms 0.3 2016-11-22 CRAN (R 3.4.1)
httr 1.2.1 2016-07-03 CRAN (R 3.4.1)
jsonlite 1.5 2017-06-01 CRAN (R 3.4.1)
KernSmooth 2.23-15 2015-06-29 cran (@2.23-15)
lattice 0.20-35 2017-03-25 CRAN (R 3.4.1)
leaps 3.0 2017-01-10 cran (@3.0)
lme4 1.1-13 2017-04-19 cran (@1.1-13)
lubridate * 1.6.0 2016-09-13 CRAN (R 3.4.1)
magrittr 1.5 2014-11-22 CRAN (R 3.4.1)
MASS 7.3-47 2017-04-21 CRAN (R 3.4.1)
Matrix 1.2-10 2017-04-28 CRAN (R 3.4.1)
MatrixModels 0.4-1 2015-08-22 CRAN (R 3.4.1)
memoise 1.1.0 2017-04-21 CRAN (R 3.4.1)
methods * 3.4.1 2017-07-22 local
mgcv 1.8-17 2017-02-08 CRAN (R 3.4.1)
minqa 1.2.4 2014-10-09 cran (@1.2.4)
modeltools 0.2-21 2013-09-02 cran (@0.2-21)
multcomp 1.4-6 2016-07-14 CRAN (R 3.4.1)
mvtnorm 1.0-6 2017-03-02 CRAN (R 3.4.1)
NADA 1.6-1 2017-03-31 cran (@1.6-1)
nlme 3.1-131 2017-02-06 CRAN (R 3.4.1)
nloptr 1.0.4 2014-08-04 cran (@1.0.4)
nnet 7.3-12 2016-02-02 CRAN (R 3.4.1)
parallel 3.4.1 2017-07-22 local
pbkrtest 0.4-7 2017-03-15 cran (@0.4-7)
pkgconfig 2.0.1 2017-03-21 CRAN (R 3.4.1)
plyr 1.8.4 2016-06-08 CRAN (R 3.4.1)
quantreg 5.33 2017-04-18 CRAN (R 3.4.1)
R6 2.2.2 2017-06-17 CRAN (R 3.4.1)
randtests 1.0 2014-11-17 cran (@1.0)
Rcpp 0.12.12 2017-07-15 CRAN (R 3.4.1)
readr 1.1.1 2017-05-16 CRAN (R 3.4.1)
reshape2 1.4.2 2016-10-22 CRAN (R 3.4.1)
rlang 0.1.1 2017-05-18 CRAN (R 3.4.1)
rloadest * 0.4.4 2017-07-22 Github (USGS-R/rloadest@7f285e6)
sandwich 2.3-4 2015-09-24 CRAN (R 3.4.1)
segmented 0.5-2.1 2017-06-14 cran (@0.5-2.1)
smwrBase * 1.1.3 2017-07-22 Github (USGS-R/smwrBase@f7bef98)
smwrGraphs * 1.1.2 2017-07-22 Github (USGS-R/smwrGraphs@421d57d)
smwrQW * 0.7.12 2017-07-22 Github (USGS-R/smwrQW@dccd129)
smwrStats * 0.7.5 2017-07-22 Github (USGS-R/smwrStats@c442d28)
sp 1.2-5 2017-06-29 CRAN (R 3.4.1)
SparseM 1.77 2017-04-23 CRAN (R 3.4.1)
splines 3.4.1 2017-07-22 local
stats * 3.4.1 2017-07-22 local
stats4 3.4.1 2017-07-22 local
stringi 1.1.5 2017-04-07 CRAN (R 3.4.1)
stringr 1.2.0 2017-02-18 CRAN (R 3.4.1)
survival 2.41-3 2017-04-04 CRAN (R 3.4.1)
TH.data 1.0-8 2017-01-23 CRAN (R 3.4.1)
tibble 1.3.3 2017-05-28 CRAN (R 3.4.1)
tools 3.4.1 2017-07-22 local
truncnorm 1.0-7 2014-01-21 cran (@1.0-7)
utils * 3.4.1 2017-07-22 local
withr 1.0.2 2016-06-20 CRAN (R 3.4.1)
XML 3.98-1.9 2017-06-19 cran (@3.98-1.)
xml2 1.1.1 2017-01-24 CRAN (R 3.4.1)
zCompositions 1.0.3-1 2016-04-14 cran (@1.0.3-1)
zoo 1.8-0 2017-04-12 CRAN (R 3.4.1) |
I get the error even if I install from GRAN. |
This error is fixed by USGS-R/smwrQW#28 |
I am getting an error:
when I try to run
loadReg
on the example data more than once in a row:Then my R session is completely killed. Any function call returns the error above until I restart R. The strange thing is I get no error running the first time. This also affects
selBestModel
because it iterates onloadReg
multiple times.Somehow
loadReg
is corrupting the global environment...session_info
The text was updated successfully, but these errors were encountered: