Indiana University
University Information Technology Services
  
What are archived documents?
Login>>
Login

Login is for authorized groups (e.g., UITS, OVPIT, and TCC) that need access to specialized Knowledge Base documents. Otherwise, simply use the Knowledge Base without logging in.

Close

How do I use SAS for Unix on Quarry and Mason at IU?

At Indiana University, SAS for Unix is available on the Quarry and Mason clusters. You can run SAS interactively, non-interactively, or as a background process.

On this page:


Adding SAS to your user environment

To add SAS to your user environment on Quarry or Mason, load the SAS module:

module load sas

To make permanent changes to your environment, edit your ~/.modules file. For more, see In Modules, how do I save my environment with a .modules file?

For more about using the Modules package, see On IU's Mason and Quarry clusters, how do I use Modules to manage my software environment?

Note: Following a system-wide upgrade in December 2012, Quarry now runs Red Hat Enterprise Linux version 6 (RHEL 6) and uses the Modules package (instead of SoftEnv) for manipulating user environments. For more, see Information about the 2012 upgrade to Quarry at IU. If you encounter any problems or have questions, email the High Performance Systems group.

Back to top

Running SAS interactively

To run SAS interactively, at the Unix prompt, enter:

sas -nodms

When SAS initializes, the SAS command prompt (1?) will display. The number appearing with the question mark in the prompt will increase with each subsequent command line. Enter your command(s) and terminate each SAS command with  ;  (semicolon). For example, to execute a statement, enter:

run;

To end the session, at the SAS prompt, enter:

endsas;

Back to top

Running SAS in non-interactive mode

To run a SAS job non-interactively, at the Unix prompt, enter:

sas program.sas

Replace program.sas with your SAS program's filename. When the job has been executed, two new files will exist in your default directory. The SAS log, program.log, will contain the code that was run along with any notes, warnings, or errors that resulted during execution. The listing report, program.lst, will contain output from the program, if any. In both cases, program represents the name of your SAS program file. If your program file contains errors, the .lst file may not be generated.

Back to top

Running SAS as a background process

When you run a non-interactive job, your terminal is not free for other computing tasks until the job is completed. If you want to use your terminal for computing activities while the job runs in the background, include  &  (ampersand) at the end of the command:

sas program.sas &

Again, replace program with the name of your SAS program.

This will free your terminal for other computing tasks while the job runs in the background. When the job is completed, a message will be displayed on the screen, and the .log and the .lst files will be stored in the default directory.

Back to top

Getting help

For help learning how to use SAS on a Unix system, UITS Research Analytics provides an online tutorial: Getting Started with SAS for Unix. For more on SAS, see the Research Analytics SAS page. For tutorials on other statistical and mathematical applications, see the Research Analytics Tutorials and Working Papers page.

If you have questions about using statistical and mathematical software at Indiana University, email UITS Research Analytics (formerly known as the Stat/Math Center). Research Analytics is located on the IU Bloomington campus at 410 N. Park Avenue and is open for consultation by appointment Monday-Friday 9am-5pm. For more, visit Research Analytics on the web, or call 812-855-4724 (IUB) or 317-278-4740 (IUPUI).

Back to top

This is document agik in domain all.
Last modified on April 30, 2013.

I need help with a computing problem

  • Fill out this form to submit your issue to the UITS Support Center.
  • Please note that you must be affiliated with Indiana University to receive support.
  • All fields are required.



Please provide your IU email address. If you currently have a problem receiving email at your IU account, enter an alternate email address.

I have a comment for the Knowledge Base

  • Fill out this form to submit your comment to the IU Knowledge Base.
  • If you are affiliated with Indiana University and need help with a computing problem, please use the I need help with a computing problem section above, or contact your campus Support Center.