Running RStudio on the ORC Clusters
RStudio Server is available as one of the interactive apps that can be launched directly from Open OnDemand.
To use RStudio on Hopper, the first step is to start an Open OnDemand (OOD)session. In your browser, go to ondemand.orc.gmu.edu. You will need to authenticate with your Mason credentials before you can access the dashboard.
- Once you authenticate, you should be directed to the OOD dashboard.
- You'll need to click on the "Interactive Apps" icon to see the apps that are available.
From the OOD Dashboard
- Select RStudio from the listed apps
- Set your configuration from the given options and launch.
- Once your session is ready to start, you can 'Connect'
- This will start a RStudio session where you can start running R Scripts.
Changing Working Directory
To change RStudio's working directory, you can use the setwd()
function from within a R terminal or script. e.g.
setwd("/home/clusteruser")
You can also use menu commands to change the working directory and the GUI file browser directory, to change RStudio's working directory using menus do the following:
Navigate to Session->Set Working Directory->Choose Directory
Select the ellipsis to manually enter a path and type in the desired working directory
Using Symlinks for easy /projects, /groups, or /scratch access
You can add links to other directories from your home directory to access other locations easily. To create a symlink (symbolic link) enter the following command:
ln -s <target-directory> symlink_name
e.g. to create a link named "scratch" to a scratch directory located in /scratch/clusteruser, run the following
ln -s /scratch/clusteruser ~/scratch
Note: that if you would like your link to appear at the top of alphabetically sorted files, you can add a tilde (~) to the symlink name. e.g.:
ln -s /scratch/clusteruser ~/~scratch
Once this has been done, you can navigate to the linked directory and access scratch or other linked directories as if they were located in your home directory.