IDEAS home Printed from https://ideas.repec.org/a/tsj/stataj/v10y2010i2p281-296.html
   My bibliography  Save this article

Speaking Stata: Finding variables

Author

Listed:
  • Nicholas J. Cox

    (Durham University, UK)

Abstract

A standard task in data management is producing a list of variable names showing which variables have specific properties, such as being of string type, or having value labels attached, or having a date format. A first-principles strategy is to loop over variables, checking one by one which have the property or properties concerned. I discuss this strategy in detail with a variety of examples. A canned alternative is offered by the official command ds or by a new command, findname, published formally with this column. Copyright 2010 by StataCorp LP.

Suggested Citation

  • Nicholas J. Cox, 2010. "Speaking Stata: Finding variables," Stata Journal, StataCorp LP, vol. 10(2), pages 281-296, June.
  • Handle: RePEc:tsj:stataj:v:10:y:2010:i:2:p:281-296
    Note: to access software from within Stata, net describe http://www.stata-journal.com/software/sj10-2/dm0048/
    as

    Download full text from publisher

    File URL: http://www.stata-journal.com/article.html?article=dm0048
    Download Restriction: no
    ---><---

    References listed on IDEAS

    as
    1. Bill Rising, 2010. "Stata tip 86: The missing() function," Stata Journal, StataCorp LP, vol. 10(2), pages 303-304, June.
    2. Martin Weiss, 2008. "Stata tip 66: ds- A hidden gem," Stata Journal, StataCorp LP, vol. 8(3), pages 448-449, September.
    Full references (including those not matched with items on IDEAS)

    Most related items

    These are the items that most often cite the same works as this one and are cited by the same works as this one.
    1. Nicholas J. Cox, 2011. "Speaking Stata: Fun and fluency with functions," Stata Journal, StataCorp LP, vol. 11(3), pages 460-471, September.

    Corrections

    All material on this site has been provided by the respective publishers and authors. You can help correct errors and omissions. When requesting a correction, please mention this item's handle: RePEc:tsj:stataj:v:10:y:2010:i:2:p:281-296. See general information about how to correct material in RePEc.

    If you have authored this item and are not yet registered with RePEc, we encourage you to do it here. This allows to link your profile to this item. It also allows you to accept potential citations to this item that we are uncertain about.

    If CitEc recognized a bibliographic reference but did not link an item in RePEc to it, you can help with this form .

    If you know of missing items citing this one, you can help us creating those links by adding the relevant references in the same way as above, for each refering item. If you are a registered author of this item, you may also want to check the "citations" tab in your RePEc Author Service profile, as there may be some citations waiting for confirmation.

    For technical questions regarding this item, or to correct its authors, title, abstract, bibliographic or download information, contact: Christopher F. Baum or Lisa Gilmore (email available below). General contact details of provider: http://www.stata-journal.com/ .

    Please note that corrections may take a couple of weeks to filter through the various RePEc services.

    IDEAS is a RePEc service. RePEc uses bibliographic data supplied by the respective publishers.