How can I automatically install Stata under Windows?
||Automate installation of Stata
Kevin S. Turner, StataCorp
Starting with Stata 9, the Windows installer was developed using
installer format (MSI). For the average user, whether the installer is
built using MSI matters little. MSI provides certain facilities to aid with
advanced upgrading or automating installations over many machines. These
tasks are particularly useful for system administrators.
The MSI format specifies several command-line arguments for automating an
install process, and all of these are available to the Stata installer. You
can view these command-line arguments by running the
command, which can be run from any DOS window or from the Run option on the
Although explaining every command-line argument is beyond the scope of this
FAQ, there are some that are important for automating an install.
Turns off any visual user interface.
Allows you to preset
some variables that the installer
The properties are typically installation-specific variables, so, before you
can set them, you must know what they are. There are three installation
properties you need to know to automate the Stata installer. They are
Specifies the path where Stata will be installed.
Default value is: C:\Program Files\Stata9.
Specifies the flavor of Stata to install. Possible values are:
intercooled, and small, where
se is the default.
Indicates either 32-bit or 64-bit executable. Possible values are:
32 and 64, where
32 is the default.
With just the /qn option set and no properties specified, the Stata
installer will use the default property values. You can override as many or
as few of the properties as you want. From the command line or a scripting
language, you could issue the following command to silently install Stata/MP
for 64-bit Windows (drive E: is arbitrary and represents the CD drive):
E:\setup.exe /qn EXECUTABLETYPE=64 STATAFLAVOR=mp
While this installer runs, you might notice some extra processes in the Task
Manager or simply notice that the computer is working on something, but,
because of the /qn switch, you should see no visual evidence of the
installer. When the application is installed, you will find it via the Start
menu under All Programs. Logging is available via the MSI specification
should you need confirmation of installation.
Stata for Windows
Stata for Unix
Stata for Mac