This file is part of IDEAS, which uses RePEc data


[ Papers | Articles | Software | Books | Chapters | Authors | Institutions | JEL Classification | NEP reports | Search | New papers by email | Author registration | Rankings | Volunteers | FAQ | Blog | Help! ]

Speaking Stata: How to face lists with fortitude

Author info | Abstract | Publisher info | Download info | Related research | Statistics
Author Info
Nicholas J. Cox () (University of Durham, UK)

Additional information is available for the following registered author(s):

Abstract

Three commands in official Stata, foreach, forvalues, and for, provide structures for cycling through lists of values (variable names, numbers, arbitrary text) and repeating commands using members of those lists in turn. All these commands may be used interactively, and none is restricted to use in Stata programs.They are explained and compared in some detail with a variety of examples.In addition,a self-contained exposition is given on local macros, understanding of which is needed for use of foreach and forvalues. Copyright 2002 by Stata Corporation.

Download Info
To download:

If you experience problems downloading a file, check if you have the proper application to view it first. Information about this may be contained in the File-Format links below. In case of further problems read the IDEAS help page. Note that these files are not on the IDEAS site. Please be patient as the files may be large.

File URL: http://www.stata-journal.com/sjpdf.html?articlenum=pr0005
File Format: application/pdf
File Function:
Download Restriction: no

Publisher Info
Article provided by StataCorp LP in its journal Stata Journal.

Volume (Year): 2 (2002)
Issue (Month): 2 (May)
Pages: 202-222
Download reference. The following formats are available: HTML (with abstract), plain text (with abstract), BibTeX, RIS (EndNote, RefMan, ProCite), ReDIF
Handle: RePEc:tsj:stataj:v:2:y:2002:i:2:p:202-222

Contact details of provider:
Web page: http://www.stata-journal.com/

Order Information:
Web: http://www.stata-journal.com/subscription.html

For technical questions regarding this item, or to correct its listing, contact: (Christopher F. Baum).

Related research
Keywords: foreach; forvalues; for; lists; local macros; substitution first;

References listed on IDEAS
Please report citation or reference errors to , or , if you are the registered author of the cited work, log in to your RePEc Author Service profile, click on "citations" and make appropriate adjustments.:

  1. Roger Newson, 2002. "Parameters behind "nonparametric" statistics: Kendall's tau,Somers' D and median differences," Stata Journal, StataCorp LP, vol. 2(1), pages 45-64, February. [Downloadable!]
  2. Nicholas J. Cox, 2001. "Speaking Stata: How to repeat yourself without going mad," Stata Journal, StataCorp LP, vol. 1(1), pages 86-97, November. [Downloadable!]
Full references

Statistics
Access and download statistics

Did you know? There is a FAQ (frequently asked questions).

This page was last updated on 2010-1-17.


This information is provided to you by IDEAS at the Department of Economics, College of Liberal Arts and Sciences, University of Connecticut using RePEc data on a server sponsored by the Society for Economic Dynamics.