My ssh connection drops after [n] minutes

Try adding the ServerAliveInterval and ServerAliveCountMax
variables to your ~/.ssh/config file on your computer.

This will tell the server that your connection is still alive and being used, and it will also keep proxy or NAT machines from closing an (apparently) unused TCP connection.

Be sure to use the host alias (the name specified after "host=" in the configuration file; in this case "hoffman2") when connecting to the cluster so that ssh applies your chosen configuration.

For instance, after adding the below configuration to your ssh config file, you would simply connect like this:
$ ssh hoffman2

Example: 
(be sure to change "your_user_name" to your user name on the hoffman2 cluster)

host=hoffman2
hostname=hoffman2.idre.ucla.edu
user=your_user_name
ServerAliveInterval=30
ServerAliveCountMax=5