Hi all,
I want to write some text to a text file that contains the label text, but I keep getting a numeric value back. Grateful to anyone who could help or provide some insights.
A simplified version is:
I get the level digit back instead of the label text
Thank you
I want to write some text to a text file that contains the label text, but I keep getting a numeric value back. Grateful to anyone who could help or provide some insights.
A simplified version is:
Code:
use my_data
generate id = _n
* label attributes and levels
label define WFHlab 1"Allowed" 2 "Not allowed"
label values WFH WFHlab
foreach obs of numlist 1/`=_N' {
quietly summarize id if id == `obs'
local WFH_lab = WFH[r(min)]
display `WFH_lab'
}
Thank you

Comment