Hey - just thought I would share my success with installing RStudio on a chromebook (Pixelbook to be exact). I'm a Physician/Engineer (Practicing research engineer and training Medical Geneticist) and have lurked on here a long time, but registered today to post this for others. I love this pixelbook - I've found workarounds for most things that had me using Windows devices in the past. For most big data/R/Rstudio work I can (and will) use cloud computing and my Pixelbook is great for remote desktop work like that. However...The ONLY downfall is my data science stuff can't be done on the chromebook locally - at least not easily. My wife also uses RStudio in grad school and was strongly discouraged by her Stats professor from using a chromebook for RStudio. She ultimately gave up on the chromebook because she doesn't like to be dependent on a remote desktop to run her scripts/code (all it takes is one slow connection to make remote work tedious).
Anyway - There are a couple previous threads discussing side-loading/installing crouton etc to get linux to run Rstudio on chromebook hardware. My wife was not comfortable with taking our nice laptop computer and doing that. However, I was finally convinced yesterday to try to install it via the new (Beta) Linux feature directly "baked into" the latest Chromebook OS in a container.
It is probably super simple for hardcore Linux folks out there, but I thought I'd do other people a "solid" and post this. For data scientists / students like my wife who have a nice pixelbook but can't run R - they should try this! Pretty fast and simple!
So here's my Halloween good deed for the day:
-
First, you need to activate the Linux option. Follow the instructions as follows from Google:
https://support.google.com/chromebook/answer/9145439 -
Then you need to open up the new terminal with the icon and proceed with the following code:
#First update the beta chromebook Linux "update" and "upgrade" under "sudo" or superuser credentials...By the way this is Debian 9 64-bit Linux when you are choosing packages to install...
sudo apt-get update && sudo apt-get upgrade
#installing basic R package and the development package...there's more options available bt-dubs.
sudo apt-get install r-base r-base-dev
#need to install this next tool "gdebi" to install the downloaded install package..
sudo apt-get install gdebi-core
#need to install wget to actually get the file first
sudo apt-get install wget
#this one library wasn't installed for me ultimately, and I got an error when I ran Rstudio from the command line the first time , so I went back and installed it manually and THEN re-installed Rstudio...
sudo apt-get install libxslt1.1
#get the file - the actual target will definitely change when newer versions come up, I just made sure it matched the version Linux (Debian 9 / 64-bit)...
sudo wget https://download1.rstudio.org/rstudio-xenial-1.1.463-amd64.deb
#installed the keyring (think this was superfluous to be honest, but I did it and am including it just in case...) per https://www.rstudio.com/code-signing/
sudo apt-get install dpkg-sig
gpg --keyserver keys.gnupg.net --recv-keys 3F32EE77E331692F
dpkg-sig --verify rstudio-xenial-1.1.463-amd64.deb
#install Rstudio...
sudo gdebi rstudio-xenial-1.1.463-amd64.deb
#clean it up...
rm rstudio-xenial-1.1.463-amd64.deb
#UPDATE: Needed to add write permissions to the R folders as follows:
sudo chmod -R 777 /usr/lib/R
sudo chmod -R 777 /usr/share/R
-
I out of voodoo Halloween superstition shut down the pixelbook and restarted it before attempting to use R studio. So far working great! Good luck grad students with chromebooks!
-
Few things I've figure out: In RStudio menu tools>global settings>appearance I had to change font to DejaVu Sans Mono(space) as the default courier font isn't installed and will cause cursor problems. Personally I went with dark background to save chromebook battery life and zoomed font size to 175% to be more reasonably sized/consistent with the Pixel resolution. YMMV.
-
Edited the above code to add some read/write permissions to the R folders giving some grief in the program.
PS - Mad props to my older brother Ulysses for helping me figure this out!