I'm following the many online tutorials for setting up a Shiny server using AWS. I created a free tier EC2 instance with Ubuntu 20.04 (64-bit), and I've installed R 3.6.3.
I can't install the httpuv package, which is a dependency of shiny. (Other packages, such as dplyr, work just fine.) This gist shows the output I see when I try to install httpuv; it's extremely long, and unfortunately the beginning of the output is cut off. Before terminating, it sat at line 1205 for hours with no movement.
I'm not the first user to encounter this problem. This RStudio community post from just a week ago looks like the same thing I'm experiencing. This SO question has some suspiciously similar warning messages, but in that case the user solved the problem by re-installing R. I have a brand-new R installation, so that solution doesn't help me. One of the comments mentions encountering problems with limited memory on AWS and suggests installing from source; I get the same output. I've also tried using a larger EC2 instance (30 GiB) and an older Ubuntu version (16.04); no difference.
This GitHub issue also involves httpuv, but the output seems to be different and the problem may have been specific to Raspberry Pi. The first post in this issue mentions that it takes a long time to install httpuv, but installation didn't actually fail.
Related
After i tried to install a package in R i can't install packages anymore, it's somehow blocked. I get this box with the question if i want to create a personal library etc. and if i press yes the same box comes again and again, if i press no then comes a box that says unable to install packages. I've tried several solutions but nothing has worked. Any ideas? I'm really desperate cause I can't go further with my studying for the university. Thanks in advance!
I've tried uninstalling and reinstalling R and Rstudio, closing Firewalls and Antiviruses, opening Rstudio as administrator. Maybe i've done somthings the wrong way, so any tips from zero point would be helpful. Thanks
I had used R-studio for exploratory Data analysis a few months back. I also faced the same issue, some times R-studio refuses to install packages, so what I did was uninstall the IDE and install it again, it starts from the beginning and loads up with default configuration. Once installed I used the command
install.packages('tidyverse')
Here's the link to official R-studio IDE documentation :
https://support.posit.co/hc/en-us/articles/200554786-Problem-Installing-Packages-in-the-RStudio-IDE
The above solution worked for me.
Recently I've tried to install keras package in R. I ran the following commands:
install.packages("keras") library(keras)
But when I ran is_keras_avalable() I got FALSE.
I was told, that the problem with unsuccessful 'keras' installation may come from the old RStudio version, which is installed on my notebook (I work in RStudio 3.4.0). I was adviced to reinstall RStudio and to get a brand new version.
Could you, please, tell me how to do it? I'd be very pleased if you provide me with the necessary links for installing the latest RStudio version on Windows 8.1.
Thank you for your help.
RStudio is an application (specifically, an Integrated Development Environment, or IDE). This is a common tool for using R, which is a computer language. Much like Microsoft Word is a common tool for writing documents in English (or other languages - and in fact you can use RStudio to write files other languages like RMarkdown, Python, SQL, French, or Swahili.). However, just like you can write English in programs other than Word, you can also write and run R code in programs other than RStudio.
You can find the most recent version on the RStudio website, or you can look in the Help menu and select "Check for updates", which will give you a download link if a newer version is available.
Given the version number you show, 3.4.0, you need to upgrade R (the language), not RStudio (the application). The current RStudio version as I write this is 1.3.*, while the current R version is 4.0.*.
The place you need to go to update R is CRAN - their website has download links for Windows, Mac, and Linux.
I feel pretty comfortable working with R, and I want to get into Python through Anaconda.
Upon trying the Jupyter Notebook and finding it has compatibility with R, I really want to use it.
I'm having problem installing the R packages that don't come in R-essentials; and mainly because I noticed it uses a different R installation than the one I had before. Not only is this a different R installation, but it also uses a previous version of R. In my local installation I have updated to 3.2.3 but in the Anaconda environment for Jupyter I got 3.1.
I also found a post to change the .libPaths variable to include the packages that I had already installed. Still, I see this as a potential problem because of the different R versions.
I wanted to know if I can update the R version that's used in Anaconda, or if I can point to the one that's installed locally.
Thank you.
You can install IRkernel in the normal R installation and then register the kernel: simply follow the instructions at http://irkernel.github.io/installation/
I have been having some weird issues with R (3.1.1) and RStudio (0.98.1079) and I suspect that it is due to the fact that these programs are not longer referencing the right places after I upgraded to Mac OSX 10.10.
In particular, I cannot seem to find packages that I know I have installed on my computer to run using the system command in the R console. That is, running man pdflatex in a Terminal window yields the help manual for PDFLATEX. However running system('man pdflatex') from the R console yields the error message No manual entry for pdflatex.
The issue persists even though I reinstalled R, RStudio and MacTex since I upgraded to Mac OSX 10.10. Any help would be appreciated!
Yosemite has a bug wherein some environment variables, including PATH, appear twice in a program's environment with different values. For instance, you might notice that Sys.getenv("PATH") will show you one PATH, and system("echo $PATH") will show you an entirely different one.
I expect that most of your problems are due to this bug.
There are a few workarounds you can try immediately:
You can manually forward PATH yourself. Try this:
> system2("man", "pdflatex", env=paste0("PATH=", Sys.getenv("PATH")))
Or, you can start RStudio from Terminal:
$ open /Applications/RStudio.app
Both the R and RStudio engineers have implemented workarounds in the last few days. R (as of 3.1.2) and RStudio (as of 0.98.1087) should behave as you'd expect.
There are a host of questions about similar problems. All of them appear to come up when you update OS X to either Yosemite or Sierra with an older version of R already installed.
The easiest solution is to completely uninstall R (note the comments about using which R !), and then to install it again.
This also solves problems such as R showing different version numbers in terminal and the GUI.
I am developing a framework for reproducible computing with R. One problem that I am struggling with is that some R code might run perfectly in version X.Y-Z of a package, but then why you try to reproduce it 3 years later, the packages have updated, some functions are changed, and the code doesn't run anymore. This problem affects also for example Sweave documents that use packages.
The only way to confidently reproduce the results is by installing the R version and version of the packages that were used by the original author. If this was a single case, one could pull stuff from the CRAN archives and install appropriate versions. But for my framework this is impractical, and I need to have the package versions preinstalled.
Assume for now that I restrict myself to a single version of R, e.g. 2.14. What would be a practical way to install many versions of R packages, so that I can load them on the fly? I suppose I can do something like creating separate library directories for every version of every package and then using custom lib.loc arguments while loading them. This is going to be messy though. Any tips or previous attempts to do something similar?
My framework runs on Ubuntu server.
You could install packages with versions (e.g. rename to foo_1.0 directory instead of foo) and softlink the versions you want to re-create a given R + packages snapshot into one library. Obviously, the packages could actually live in a separate tree, so you could have library.projectX/foo -> library.all/foo/1.0.
The operating system gives you even more handles for complete separation, and the Debian / Ubuntu stack as a ton of those available. Two I have played with are
chroot environments: We use this to complete separate build environments from host machines. For example, all Debian uploads I produced are built in a i386 pbuilder chroot hosted on my amd64 Ubuntu server. Chroot is a very powerful Unix system call. Chroots, and particularly the pbuilder system built on top of it (for Debian package building) are meant to operate headless.
Virtual machines: This gives you full generality. My not-so-powerful box easily handles three virtual machines: Debian i386, Ubuntu i386 as well as Windoze XP. For this, I currently use KVM along with libvirt; this is Linux specific. I have also used VirtualBox and VMware in the past.
I would try to modify the DESCRIPTION file, and change the field "Package" there by adding the version number.
For example, you download the package source a from CRAN page (http://cran.r-project.org/web/packages/pls/). Unpack the compressed file (pls_2.3-0.zip) to a directory ("pls/"). The following steps are to change the package name in DESCRIPTION ("pls/DESCRIPTION") and installation with R command 'R CMD INSTALL pls/', where 'pls/' is a path to the package source with modified DESCRIPTION file.
Playing with R library paths seems a dangerous thing to me.