I have a stata file named "survey.dta" which contains the following labelled data:
identifiant | educ | gender | region | income |
11111 | primary | female | rural | 800 |
11112 | secondary | male | urban | 900 |
11113 | primary | male | rural | 900 |
11114 | university | female | rural | 1000 |
This file is accompanied with the following excel file named "variables.xls" which contains the question related to the variables in "survey.dta":
Variable name | Value label | Variable label |
identifiant | Farmers' ID | |
educ | educ | What is your highest level of education? |
gender | gender | Farmers' gender |
region | region | Where do you mostly live for your activities? |
income | What is the total value of your production? |
I would like to label variables in the first file (i.e., "survey.dta") using variable labels from the second file (i.e., "variables.xls") in Stata 13. I have 2K variables in my data and I would like to write a do-file that will help me to do all of that at once.
NB: The values of the variables contained in the first file "survey.dta" are already labelled.
I will be grateful for any comments and suggestions.
Best regards,
Antoine
0 Response to Label Variables
Post a Comment