Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: Re: Batch variable?

From   Brendan Halpin <>
Subject   st: Re: Batch variable?
Date   28 Oct 2005 15:15:40 +0100

Brendan Halpin <> writes:

> Can Stata tell me whether it has been invoked batch-style (stata
> -b) or not? I'd like to have behave differently in the
> two cases.

Given that it's Friday afternoon, I'll continue following myself up
and let you all know I found the answer by trial and error and now
have the following code in

if "$S_MODE" != "batch" {
  set memory 100m

This allows me to set memory on a "stata -m200 -b do"
shell command and not have it overridden by 

Query: is there any reason to prefer one or other of "$S_VARNAME" and

Brendan Halpin,  Department of Sociology,  University of Limerick,  Ireland
Tel: w +353-61-213147 f +353-61-202569 h +353-61-338562; Room F2-025 x 3147
*   For searches and help try:

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