The problem: I thought I was being clever by leaving my laptop in Canada. Bringing only a phone and iPad meant a slightly lighter pack and not having to worry about getting my relatively new laptop lost or stolen or broken. I’ve managed to get myself involved in a research project, though, which required some nice statistical analysis. With no laptop or computer access, I had to be creative.
- phone with wifi hotspot capabilities
- iPad with Dropbox, Textastic, and Prompt
- a remotely-accessible Unix-based server with Dropbox
I used Prompt to log into the remote server and install R. Installing tmux has helped preserve my sanity with this setup, as Prompt drops the connection quickly (I suspect it’s a general iOS issue). I have automatically run ‘tmux a’ when it connects, which allows me to reconnect to the same session.
Dropbox is used to, surprise, sync files between my iPad and the remote server. I set up a directory structure with ProjectTemplate (though I wasn’t able to use any of its other benefits, as I couldn’t get its Excel support to work).
I then wrote a script for the remote server that watches my R source directory (the one in Dropbox) and automatically runs it when files are update. It dumps the output to a log file, also in Dropbox.
Now I can edit my R scripts in Textastic, upload the changes through Dropbox (from within Textastic), and download the updated log file (also from within Textastic). Textastic has the best take on a programming keyboard for a touchscreen that I’ve seen so far, which is part of why I prefer it to coding remotely with vim or Emacs–Prompt’s keyboard doesn’t support the variety of special characters you need to code.
This setup unfortunately means that every single change of code that I want to test requires an upload, wait, download, wait. Painful, yes, but not as painful as it would be to try programming remotely.