[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

st: New Stata package -saswrapper- on SSC that runs SAS code from within Stata

From   Dan Blanchette <>
Subject   st: New Stata package -saswrapper- on SSC that runs SAS code from within Stata
Date   Tue, 14 Apr 2009 10:33:56 -0400 (EDT)

Dear Statalist Members,
Thanks to Kit Baum, a new Stata package -saswrapper-
is now available for download on SSC.

-saswrapper- is a great way to quickly run some SAS code on your
Stata dataset that's in memory and see the results in your Stata
results window.


-saswrapper- runs a SAS program in batch and prints the output in the Stata
results window/log file.  This usually occurs by specifying a SAS program
file after -using-, but -saswrapper- can also run SAS code specified by the
pre_sas_prog() and/or post_sas_prog() options.  By default, -saswrapper-
will save the current data in memory using -savasas- and make it available
in SAS's WORK library.  If that is not desired, use the -nodata- option.
The -usesas- option tells -saswrapper- to load the last SAS dataset created
in the WORK library by the submitted SAS program into Stata using the

NOTE:  -saswrapper- calls SAS to run the SAS program.  This requires the
ability to run SAS on your computer.

Here's the help page in html format:

-saswrapper- uses my Stata programs that transfer data between SAS and Stata:
-savasas- and -usesas-.  My SAS macro STATA_WRAPPER runs Stata code from
within SAS and is downloaded with -saswrapper- and -usesas- when they are

Also, by installing -saswrapper- you will be updating my programs that transfer data between SAS and Stata as well.

Let me know if you have any questions or feedback,
Dan Blanchette
Research Associate
Center of Entrepreneurship and Innovation
Duke University's Fuqua School of Business
*   For searches and help try:

© Copyright 1996–2017 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index