Why is my logical && comparison producing NA?

Who knew? I thought the difference between & and && for ANDing logical vectors in R was just that & evaluated the whole expression while && started at the left and went right until it hit a FALSE value. But there’s more. & is vectorized, but && only considers the first value in a vector and only returns a single value.

Continue reading “Why is my logical && comparison producing NA?”

Adding RStudio to an Amazon Lightsail Instance

Today I decided to try adding the RStudio Server to my Amazon Lightsail instance. There are three steps to this – downloading and installing the software, opening up port 8787, and adding a user with a password who can log in to the server.

Continue reading “Adding RStudio to an Amazon Lightsail Instance”

How to write a script for setting up a LEMRS stack on Amazon Lightsail

In my last post, I bumped into Amazon Lightsail and discovered the joys of virtual servers. In this post I’m going to talk about how a Linux noob like me figured out what to put in Lightsail’s Create Instance launch script to build a LEMRS stack. In my next post, I’ll show you the actual Lightsail script I’m using.

Continue reading “How to write a script for setting up a LEMRS stack on Amazon Lightsail”

Creating linked GitHub, RStudio, and shinyapps.io projects

Staying organized is a bitch. Using a separate RStudio project for each distinct task you’re working on is a core organizational principle that works on its own for statistical projects related to classwork or publications. Things get harder, however, when your RStudio project also has a GitHub repository and is a Shiny app hosted on a server like shinyapps.io.

Continue reading “Creating linked GitHub, RStudio, and shinyapps.io projects”

MySQL remote access setup in cPanel

Inexpensive shared servers, like the one Open-Meta.org is using, include MySQL database software that you might be able to access from other servers or computers. But when you try to look up how to do this, you are likely to get instructions that are out-of-date and that appear more complicated than the process actually is.

Continue reading “MySQL remote access setup in cPanel”

Project code added to repositories

I have placed the current project code, which is a functioning single-user (on your own computer) version, in both repositories. It’s called RCT. The version of RCT in my personal account includes the data files for the vitamin D project; the version in the Open-Meta account does not and is ready to be used on a new project.

Continue reading “Project code added to repositories”

How to manage multiple GitHub accounts with RStudio

One thing about Git and GitHub that has had me puzzled was how to connect RStudio to two different GitHub accounts, my personal account and the Open-Meta account. My Google searches were turning up nothing on this.

Continue reading “How to manage multiple GitHub accounts with RStudio”