Bookmark and Share

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]

st: postfile, using variable name not value or label


From   "Karen Wright" <[email protected]>
To   <[email protected]>
Subject   st: postfile, using variable name not value or label
Date   Mon, 26 Apr 2010 18:37:17 +0100

Dear All,

I am using Stata 10.0 and have written the following code.

**************

foreach j in 1000 750 500 400 300 250 200 150 {
	use "E:\Small Clusters Paper\INIS datasets\INIS.0.04.`j'.dta", clear
	foreach var of varlist b24age_lm_coef-n24delay_2_lm_coef {
		summ `var', det
		post INIS_coef (4) (`j') (`var') (r(mean)) (r(p5)) (r(p95))
	}
}


****************

However I was wondering how I would be able to -post- the name of the variable in question rather than the value of the variable?   I have searched the FAQ and archive but have not found how to post the variable name and not the label.

Thank you,
Karen 


The Institute of Cancer Research: Royal Cancer Hospital, a charitable Company Limited by Guarantee, Registered in England under Company No. 534147 with its Registered Office at 123 Old Brompton Road, London SW7 3RP.

This e-mail message is confidential and for use by the addressee only.  If the message is received by anyone other than the addressee, please return the message to the sender by replying to it and then delete the message from your computer and network.

*
*   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/


© Copyright 1996–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index