Problem with package

noetsi

Fortran must die
#1
I tried to install tidyverse. I thought it worked then got this

library(tidyverse)
Error: package or namespace load failed for ‘tidyverse’ in loadNamespace(i, c(lib.loc, .libPaths()), versionCheck = vI[]):
namespace ‘rlang’ 0.4.5 is already loaded, but >= 0.4.6 is required

I have the most recent R I can find.
 

noetsi

Fortran must die
#2
I thought I could just rebuild rlang and it would update. But...

install.packages("rlang")

Installing package into ‘\\fldvr.net/hq/Users/rthellein/Documents/R/win-library/4.0’
(as ‘lib’ is unspecified)
trying URL 'https://mirror.las.iastate.edu/CRAN/bin/windows/contrib/4.0/rlang_0.4.6.zip'
Content type 'application/zip' length 1109027 bytes (1.1 MB)
downloaded 1.1 MB
package ‘rlang’ successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package ‘rlang’
Warning: restored ‘rlang’
The downloaded binary packages are in
C:\Users\rthellein\AppData\Local\Temp\Rtmpgpisq4\downloaded_packages
Warning message:
In file.copy(savedcopy, lib, recursive = TRUE) :
problem copying \\fldvr.net\hq\Users\rthellein\Documents\R\win-library\4.0\00LOCK\rlang\libs\x64\rlang.dll to \\fldvr.net\hq\Users\rthellein\Documents\R\win-library\4.0\rlang\libs\x64\rlang.dll: Permission denied

I have installed a lot of packages recently without this permission issue coming up.
 

noetsi

Fortran must die
#3
I think I was able to do it through Rstudio. When you update something in Rstudio does it update what exists in Rconsole. I think so.

After the update this occurred (I have not seen this before in a package so I do not know what it means)

library(tidyverse)
-- Attaching packages ------------------------------------------------------------------------ tidyverse 1.3.0 --
v ggplot2 3.3.0 v purrr 0.3.4
v tibble 3.0.1 v dplyr 0.8.5
v tidyr 1.0.3 v stringr 1.4.0
v readr 1.3.1 v forcats 0.5.0
-- Conflicts --------------------------------------------------------------------------- tidyverse_conflicts() --
x dplyr::filter() masks stats::filter()
x dplyr::lag() masks stats::lag()
>
 

noetsi

Fortran must die
#4
Strangely a package that works in R console did not show up in RStudio.

I don't understand the following error

mydatar$standard <-mydatar$Spending/monthdays
Error in mydatar$Spending/monthdays :
non-numeric argument to binary operator

str(mydatar)
$ Spending: num

so the column looks numeric to me and division would not seem to violate this....
 
Last edited:

Dason

Ambassador to the humans
#7
So monthdays is a function. So you need to supply it an argument (or at least call the function somehow). I really don't know what you were trying to do with your code. Can you explain in plain words what you were trying to achieve?
 

noetsi

Fortran must die
#8
We have significant seasonality in our data. The otext suggested that processing days could explain much of this seasonality (in our case, days per month more generally for other phenomenon). I was trying to standardize our data by dividing spending by the days per month for a given month, following up on that suggestion.

Its under transformations and adjustments in otext

https://otexts.com/fpp2/transformations.html
 

noetsi

Fortran must die
#9
I am using R studio when I added a new package I get this warning

Rtools is required to build R packages but is not currently installed. Please download and install the appropriate version of Rtools before proceeding:

As far as i can tell it still adds the package. I don't know if this is an issue or not. Or how to add Rtools to Rstudio. If it involves a download our administrators have to be involved.

When I did this
library("fable")
I got
Loading required package: fabletools
does that mean I need to install another package?
 

Dason

Ambassador to the humans
#10
Future note: it's better if you don't try to summarize the messages you get back. Just paste the entire output here.
 

noetsi

Fortran must die
#11
The full output after I did install.packages("fable") is really really long. I was hoping I could tell if I had loaded it effectively with just that statement above.

install.packages("fable")
WARNING: Rtools is required to build R packages but is not currently installed. Please download and install the appropriate version of Rtools before proceeding:

https://cran.rstudio.com/bin/windows/Rtools/
Installing package into ‘\\fldvr.net/hq/Users/rthellein/Documents/R/win-library/4.0’
(as ‘lib’ is unspecified)
also installing the dependencies ‘tidyr’, ‘progressr’, ‘vctrs’, ‘anytime’, ‘numDeriv’, ‘fabletools’, ‘dplyr’, ‘tsibble’, ‘distributional’


There are binary versions available but the source versions
are later:
binary source needs_compilation
fabletools 0.1.3 0.2.0 FALSE
fable 0.2.0 0.2.1 TRUE

Binaries will be installed
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.0/tidyr_1.1.0.zip'
Content type 'application/zip' length 1516049 bytes (1.4 MB)
downloaded 1.4 MB

trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.0/progressr_0.6.0.zip'
Content type 'application/zip' length 198860 bytes (194 KB)
downloaded 194 KB

trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.0/vctrs_0.3.1.zip'
Content type 'application/zip' length 1145695 bytes (1.1 MB)
downloaded 1.1 MB

trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.0/anytime_0.3.7.zip'
Content type 'application/zip' length 1193156 bytes (1.1 MB)
downloaded 1.1 MB

trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.0/numDeriv_2016.8-1.1.zip'
Content type 'application/zip' length 116026 bytes (113 KB)
downloaded 113 KB

trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.0/dplyr_1.0.0.zip'
Content type 'application/zip' length 1294122 bytes (1.2 MB)
downloaded 1.2 MB

trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.0/tsibble_0.9.0.zip'
Content type 'application/zip' length 1121855 bytes (1.1 MB)
downloaded 1.1 MB

trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.0/distributional_0.1.0.zip'
Content type 'application/zip' length 419498 bytes (409 KB)
downloaded 409 KB

trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.0/fable_0.2.0.zip'
Content type 'application/zip' length 1416858 bytes (1.4 MB)
downloaded 1.4 MB

package ‘tidyr’ successfully unpacked and MD5 sums checked
package ‘progressr’ successfully unpacked and MD5 sums checked
package ‘vctrs’ successfully unpacked and MD5 sums checked
package ‘anytime’ successfully unpacked and MD5 sums checked
package ‘numDeriv’ successfully unpacked and MD5 sums checked
package ‘dplyr’ successfully unpacked and MD5 sums checked
package ‘tsibble’ successfully unpacked and MD5 sums checked
package ‘distributional’ successfully unpacked and MD5 sums checked
package ‘fable’ successfully unpacked and MD5 sums checked

The downloaded binary packages are in
C:\Users\rthellein\AppData\Local\Temp\Rtmpk7VfRw\downloaded_packages
installing the source package ‘fabletools’

trying URL 'https://cran.rstudio.com/src/contrib/fabletools_0.2.0.tar.gz'
Content type 'application/x-gzip' length 443753 bytes (433 KB)
downloaded 433 KB

* installing *source* package 'fabletools' ...
** package 'fabletools' successfully unpacked and MD5 sums checked
** using staged installation
** R
** inst
** byte-compile and prepare package for lazy loading
** help
*** installing help indices
converting help for package 'fabletools'
finding HTML links ... done
MAAPE html
accuracy html
aggregate_key html
aggregation-vctrs html
as-dable html
as-fable html
as_mable html
augment html
autoplot.dcmp_ts html
autoplot.fbl_ts html
autoplot.tbl_ts html
bias_adjust html
box_cox html
combination_ensemble html
combination_model html
components html
construct_fc html
dable-vctrs html
dable html
decomposition_model html
distribution_accuracy_measures html
distribution_var html
distributions html
estimate html
fable-vctrs html
fable html
fabletools-package html
fcdist html
feature_set html
features html
features_by_pkg html
features_by_tag html
fitted.mdl_df html
forecast html
freq_tools html
generate.mdl_df html
glance html
interpolate html
interval_accuracy_measures html
is_aggregated html
is_dable html
is_fable html
is_mable html
is_model html
mable-vctrs html
mable html
finding level-2 HTML links ... done

mable_vars html
min_trace html
model html
model_lhs html
model_rhs html
model_sum html
new-model-class html
new_specials html
new_transformation html
null_model html
parse_model html
parse_model_lhs html
parse_model_rhs html
point_accuracy_measures html
reconcile html
reexports html
refit html
register_feature html
report html
residuals.mdl_df html
response html
response_vars html
stream html
tidy html
traverse html
unpack_hilo html
validate_formula html
*** copying figures
** building package indices
** installing vignettes
** testing if installed package can be loaded from temporary location
*** arch - i386
*** arch - x64
Warning in file.rename(instdir, final_instdir) :
cannot rename file '\\fldvr.net/hq/Users/rthellein/Documents/R/win-library/4.0/00LOCK-fabletools/00new/fabletools' to '\\fldvr.net/hq/Users/rthellein/Documents/R/win-library/4.0/fabletools', reason 'Access is denied'
WARNING: moving package to final location failed, copying instead
** testing if installed package can be loaded from final location
*** arch - i386
*** arch - x64
** testing if installed package keeps a record of temporary installation path
* DONE (fabletools)

The downloaded source packages are in
‘C:\Users\rthellein\AppData\Local\Temp\Rtmpk7VfRw\downloaded_packages’