Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.

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

From |
Pamela Oliver <pamelaoliver1180@gmail.com> |

To |
statalist@hsphsun2.harvard.edu |

Subject |
Re: st: How do I put a value of a local macro into a variable label |

Date |
Fri, 27 Jan 2012 08:31:31 -0600 |

It is possible simply to write local label something label var varname " `label' " I do this often, generally to create composite labels within loops. Example: local b Black local w White local h Hispanic local viol violence local drug drug local theft theft local rob robbery foreach r in b w h { foreach c in v d t { label var `r'`c'o "``r'' ``c'' arrest rate" } }

* * For searches and help try: * http://www.stata.com/help.cgi?search * http://www.stata.com/support/statalist/faq * http://www.ats.ucla.edu/stat/stata/

**Follow-Ups**:**RE: st: How do I put a value of a local macro into a variable label***From:*Nick Cox <n.j.cox@durham.ac.uk>

- Prev by Date:
**re: re: st: ---texdoc--- Problem with the /*tex...tex*/ feature** - Next by Date:
**RE: st: How do I put a value of a local macro into a variable label** - Previous by thread:
**Re: st: How do I put a value of a local macro into a variable label** - Next by thread:
**RE: st: How do I put a value of a local macro into a variable label** - Index(es):