Two missing quotes and a missing part in the label string, imho.
Nick Cox wrote:
I would do this. I assume value labels attached
to -marEduc-.
separate aRate, by(marEduc) shortlabel
local aRatevars "`r(varlist)'"
twoway connected `aRatevars' year
Sometimes even the -shortlabel- is too long.
(There should be an option -veryshortlabel-
to go beyond the -shortlabel- I suggested
a while back.)
ssc inst labutil
labnoeq `aRatevars'
will cut them down further. The first principles
way to do that is something like
foreach v of local aRatevars {
local label : variable label `v'
Here a ' missing:
local eq = index(`"`label'"', "=") - 1
and here a ' and the second part of the string
local label = substr(`"`label'"',1,`eq')+substr(`"`label'"',`eq'+4,.)
label var `v' `"`label'"'
}
I'd been looking for this for some time, so I tried it right away. Thanks.
Arnold
Nick
[email protected]
[snip]
*
* For searches and help try:
* http://www.stata.com/support/faqs/res/findit.html
* http://www.stata.com/support/statalist/faq
* http://www.ats.ucla.edu/stat/stata/