*-------------------------------------------------------------------------------------------------------------------. * REGISTER CENSUS 2011 * Dataset HOUSEHOLD * * This STATA routine adds variable and value labels. * It works with Register Census 2011 microdata, prepared by SORS in April 2014. * Your dataset might have a smaller set of variables. * * Version 1, December 2014 * STATA 9.2 * * Social Science Data Archives, University of Ljubljana * Sebastian Kocar * http://www.adp.fdv.uni-lj.si/ * Contact:arhiv.podatkov@fdv.uni-lj.si * * This STATA code is protected under the Creative Commons licence. *-------------------------------------------------------------------------------------------------------------------. *--- CONFIGURATION SECTION --- START --- * The following commands should contain the complete path and * name of the .txt file to be read (e.g. 'C:/Census2011_v1.txt') * and the .dta file to be saved (e.g. 'C:/Census2011_v1.dta') * Change TXT_DATA_PATH to your filename. * Change DTA_DATA_PATH to your filename. *--- CONFIGURATION SECTION --- END --- *-------------------------------------------------------------------------------------------------------------------. *----------------------------------------------Start data processing------------------------------------------------. *--- importing data insheet using "TXT_DATA_PATH", tab *--- adding labels for variables label variable id_go "Household ID" label variable tip_go "Type of household" label variable go_os "Household size" label variable go_m "Number of men in the household" label variable go_z "Number of women in the household" label variable go_sk_0_5 "Number of members aged 0-5 years - total" label variable go_sk_6_14 "Number of members aged 6-14 years - total" label variable go_sk_15_19 "Number of members aged 15-19 years - total" label variable go_sk_20_29 "Number of members aged 20-29 years - total" label variable go_sk_30_49 "Number of members aged 30-49 years - total" label variable go_sk_50_64 "Number of members aged 50-64 years - total" label variable go_sk_65_84 "Number of members aged 65-84 years - total" label variable go_sk_85_plus "Number of members aged 85 years or more - total" label variable go_m_0_5 "Number of members aged 0-5 years - men" label variable go_m_6_14 "Number of members aged 6-14 years - men" label variable go_m_15_19 "Number of members aged 15-19 years - men" label variable go_m_20_29 "Number of members aged 20-29 years - men" label variable go_m_30_49 "Number of members aged 30-49 years - men" label variable go_m_50_64 "Number of members aged 50-64 years - men" label variable go_m_65_84 "Number of members aged 65-84 years - men" label variable go_m_85_plus "Number of members aged 85 years or more - men" label variable go_z_0_5 "Number of members aged 0-5 years - women" label variable go_z_6_14 "Number of members aged 6-14 years - women" label variable go_z_15_19 "Number of members aged 15-19 years - women" label variable go_z_20_29 "Number of members aged 20-29 years - women" label variable go_z_30_49 "Number of members aged 30-49 years - women" label variable go_z_50_64 "Number of members aged 50-64 years - women" label variable go_z_65_84 "Number of members aged 65-84 years - women" label variable go_z_85_plus "Number of members aged 85 years or more - women" label variable go_sk_0_14 "Number of members aged 0-14 years - total" label variable go_sk_0_29 "Number of members aged 0-29 years - total" label variable go_sk_65_plus "Number of members aged 65 years or more - total" label variable go_m_0_14 "Number of members aged 0-14 years - men" label variable go_m_0_29 "Number of members aged 0-29 years - men" label variable go_m_65_plus "Number of members aged 65 years or more - men" label variable go_z_0_14 "Number of members aged 0-14 years - women" label variable go_z_0_29 "Number of members aged 0-29 years - women" label variable go_z_65_plus "Number of members aged 65 years or more - women" label variable go_sk_0_34 "Number of members aged 0-34 years - total" label variable go_sk_35_49 "Number of members aged 35-49 years - total" label variable go_sk_50_69 "Number of members aged 50-69 years - total" label variable go_sk_70_plus "Number of members aged 70 years or more - women" label variable tip_star_go "Age structure of household" label variable go_otr "Number of children in the household" label variable go_otr_0_5 "Number of children in the household aged 0-5 years" label variable go_otr_0_17 "Number of children in the household aged 0-17 years" label variable go_otr_0_24 "Number of children in the household aged 0-24 years" label variable tip_gen_go "Generational composition of household" label variable tip_drz_go "Household composition by citizenship" label variable go_p1 "Number of resident type 1 in the household" label variable go_p2 "Number of resident type 2 in the household" label variable go_p3 "Number of resident type 3 in the household" label variable go_p4 "Number of resident type 4 in the household" label variable tip_pris_go_2 "Immigrant background of household" label variable go_pris_1 "Number of first generation immigrants in the household" label variable go_pris_2 "Number of second generation immigrants in the household" label variable go_pris_3 "Number of third generation immigrants in the household" label variable go_ni_pris "Number of members without immigrant background in the household" label variable go_nn_pris "Number of members with unknown immigrant background in the household" label variable go_akt "Number of economically active members in the household" label variable go_dakt "Number of employed members in the household" label variable go_bp "Number of unemployed members in the household" label variable go_neakt "Number of not economically active members in the household" label variable go_sol "Number of students in the household" label variable go_upok "Number of pension recipients in the household" label variable go_dr_neakt "Number of other not economically active members in the household" label variable go_izb_os "Number of members with basic education or less in the household" label variable go_izb_ss "Number of members with secondary education or less in the household" label variable go_izb_ter "Number of members with tertiary education or less in the household" label variable go_st_druz "Number of families in the household" label variable go_druz_tip_1 "Number of family type 1 in the household" label variable go_druz_tip_2 "Number of family type 2 in the household" label variable go_druz_tip_3 "Number of family type 3 in the household" label variable go_druz_tip_4 "Number of family type 4 in the household" label variable go_druz_tip_5 "Number of family type 5 in the household" label variable go_druz_tip_6 "Number of family type 6 in the household" label variable go_druz_tip_7 "Number of family type 7 in the household" label variable go_druz_tip_8 "Number of family type 8 in the household" label variable go_druz_tip_9 "Number of family type 9 in the household" label variable sp_ref_go "Sex of the reference person of the household" label variable star_ref_go "Age of the reference person of the household" label variable zs_ref_go "Marital status of the reference person of the household" label variable hs_mid_nast "Type of accommodation" label variable id_kohezijska "Usual residence - cohesion region - LOOK UP CODEBOOK RPE_POPIS_2011" label variable id_statisticna "Usual residence - statistical region - LOOK UP CODEBOOK RPE_POPIS_2011" label variable id_obcina "Usual residence - municipality - LOOK UP CODEBOOK RPE_POPIS_2011" label variable na_id "Usual residence - settlement - LOOK UP CODEBOOK RPE_POPIS_2011" label variable tip_naselja "Type of settlement / area" label variable vel_nas "Size of locality" label variable st_stan_go "Number of dwellings used by household" label variable st_go_stan "Number of households in the housing unit" label variable tip_stan_enote "Type of living quarters" label variable tip_lastnistva "Dwelling ownership" label variable go_upor "Tenure status of person" label variable upor_povr_stan "Useful floor space" label variable upor_povr_go "Useful floor space per household" label variable upor_povr_go_r "Useful floor space - range" label variable upor_povr_go_os "Density standard" label variable upor_povr_go_os_r "Density standard - range" label variable st_sob_stan "Number of rooms" label variable st_sob_go "Number of rooms per household" label variable id_kuhinja "Kitchen in the dwelling" label variable id_stranisce "Toilet in the dwelling" label variable id_kopalnica "Bathroom in the dwelling" label variable voda_vstan "Piped water in the dwelling" label variable id_elektrika "Electricity in the dwelling" label variable id_telefon "Telephone in the dwelling" label variable id_plin "Piped gas in the dwelling" label variable id_vodovod "Water supply system in the dwelling" label variable id_kanalizacija "Sewage disposal system in the dwelling" label variable id_ogrevanje "Type of heating" label variable kop_wc_go "Basic dwelling facilities" label variable leto_izg_sta "Year of construction" label variable leto_izg_sta_r "Year of construction - range" label variable dst_sid_k "Building part ID - final" *--- adding labels for variable values label define tip_go 1"One-person" 2"Multi-person non-family of relatives and non-relatives" 3"Multi-person non-family of grandparents, grandchildren or si" 4"Multi-person one-family" 5"Multi-person one-family extended" 6"Multi-person two or more-family" 7"Multi-person two or more-family extended" 8"Institutional household" 9"Other household" label define tip_star_go 1"Young generation household, all members under 35 years" 2"Young and middle generation household, all members under 50" 3"Middle generation household, all members aged 35-49 years" 4"Middle and older generation household, all members aged 35-6" 5"Older generation household, all members aged 50-69 years" 6"Older and elderly generation household, all members over 50" 7"Elderly generation household, all members over 70 years" 8"Skip age-group generation household" 9"Household with three or four age-group generations" label define tip_gen_go 1"First generation only" 2"Two successive generations" 3"Three successive generations" 4"Four successive generations" 5"First, second and fourth generation" 6"First and third generation" 7"First, third and fourth generation" 8"One-person household" 9"Data on generation not available" label define tip_drz_go 1"Citizens of the RS with permanent residence only" 2"Citizens of the RS with temporary residence only" 3"Citizens of the RS with permanent and temporary residence" 4"Foreign citizens with permanent residence only" 5"Foreign citizens with temporary residence only" 6"Foreign citizens with permanent and temporary residence" 7"Citizens of the RS and foreign citizens" label define tip_pris_go_2 1"First generation immigrants only" 2"First and second generation of immigrants" 3"Second generation immigrants only" 4"Second and third generation of immigrants" 5"Third generation immigrants only" 6"First generation immigrants and persons without immigrant ba" 7"First and second generation of immigrants and persons withou" 8"Second generation immigrants and persons without immigrant b" 9"Second and third generation of immigrants and persons withou" 10"Third generation immigrants and persons without immigrant ba" 11"First, second and third generation of immigrants" 12"First, second and third generation of immigrants and persons" 13"First and third generation of immigrants" 14"First and third generation of immigrants and persons without" 15"No persons with immigrant background" 16"Persons without immigrant background and persons without dat" 17"Persons without data on immigrant background" label define sp_ref_go 1"Male" 2"Female" label define zs_ref_go 1"Single" 2"Married" 3"Widow/er" 4"Divorced" 5"Same gender partnership" 6"Terminated IPS -death" 7"Terminated IPS - other" 9"Unknown" label define hs_mid_nast 1"Social work center without conventional dwellings" 2"Residence for pupils and students" 3"Postgraduate´s house" 4"Special social care institute" 5"Community" 6"Prison" 7"Religious institution" 8"Elderly home" 9"Elderly home with private households" 10"Residence for students and religious institution" 11"Elderly home, religious institution and private households" 12"Elderly home and private households" 13"Residence for students, religious institution and private ho" 14"Worker dormitory in non-residential building" 15"Worker dormitory with short-term settlement" 16"Worker dormitory for communities" 17"Worker dormitory in one-dwelling building" 18"Worker dormitory in multi-dwelling building" 19"Residence for students, worker dormitory and conventional dw" 20"Religious institution, residence for students and private ho" 21"Special social care institute with private households" 22"Roma settlement" 23"Social work center with conventional dwellings" 24"Special accommodation center" 25"Residence for students in building with conventional dwellin" 26"Residence for pupils and students without institutional hous" 27"Religious institution without institutional household" 28"Special social care institute without institutional househol" 29"Hotel and other tourist accommodation" 30"Collective living quarter as a part of the building" 31"Collective living quarter with 7 or less residents" label define vel_nas 1"1,000,000 inhabitants or more" 2"From 500,000 to 999,999 inhabitants" 3"From 200,000 to 499,999 inhabitants" 4"From 100,000 to 199,999 inhabitants" 5"From 50,000 to 99,999 inhabitants" 6"From 20,000 to 49,999 inhabitants" 7"From 10,000 to 19,999 inhabitants" 8"From 5,000 to 9,999 inhabitants" 9"From 2,000 to 4,999 inhabitants" 10"From 1,000 to 1,999 inhabitants" 11"From 500 to 999 inhabitants" 12"From 200 to 499 inhabitants" 13"From 100 to 199 inhabitants" 14"From 50 to 99 inhabitants" 15"From 25 to 49 inhabitants" 16"From 1 to 24 inhabitants" 17"No inhabitants" label define tip_stan_enote 1"Conventional dwelling" 2"Collective living quarter" 3"Other housing unit" 4"Different intitutions dealling also with homless people like" 5"Unknown" 6"Other parts of buildings" label define tip_lastnistva 1"Owner-occupied dwellings" 2"Dwellings in cooperative ownership" 3"Rented dwellings" 4"Dwellings in other types of ownership" 5"Not stated" 6"Not applicable" label define go_upor 1"At least one household member is the owner of the housing un" 2"At least one household member is the tenant of the housing u" 3"Household occupying a housing unit under some other form of" label define upor_povr_go_r 1"Under 30 square metres" 2"30 - less than 40 square metres" 3"40 - less than 50 square metres" 4"50 - less than 60 square metres" 5"60 - less than 80 square metres" 6"80 - less than 100 square metres" 7"100 - less than 120 square metres" 8"120 - less than 150 square metres" 9"150 square metres and over" 10"Not stated" label define upor_povr_go_os_r 1"less than 10 m2" 2"10 - less than 15 m2" 3"15 - less than 20 m2" 4"20 - less than 30 m2" 5"30 - less than 40 m2" 6"40 - less than 60 m2" 7"60 - less than 80 m2" 8"80 m2 and more" 9"Not stated" label define id_kuhinja 1"Yes" 2"No" label define id_stranisce 1"Yes" 2"No" label define id_kopalnica 1"Yes" 2"No" label define voda_vstan 1"Piped water in the housing unit" 2"No piped water in the housing unit" 3"Not stated" label define id_elektrika 1"Yes" 2"No" label define id_telefon 1"Yes" 2"No" label define id_plin 1"Yes" 2"No" label define id_vodovod 1"Yes" 2"No" label define id_kanalizacija 1"Yes" 2"No" label define id_ogrevanje 1"Heating by community heating centre" 2"Central heating" 3"Other type of heating" 4"No heating" label define kop_wc_go 1"Dwelling with water supply system, toilet and bathing facili" 2"Dwelling with water supply system and toilet facilities with" 3"Dwelling with water supply system and bathing facilities wit" 4"Dwelling with water supply system without bathing and toilet" 5"Dwelling without water supply system with bathing and toilet" 6"Dwelling without water supply system and bathing facilities" 7"Dwelling without water supply system and toilet facilities w" 8"Dwelling without water supply system, toilet and bathing fac" 9"Other housing unit" label define leto_izg_sta_r 1"Earlier than 1919" 2"1919 - 1945" 3"1946 - 1960" 4"1961 - 1970" 5"1971 - 1980" 6"1981 - 1990" 7"1991 - 2000" 8"2001 - 2005" 9"2006 and after" 10"Not specified" *----------------------------------------------End data processing------------------------------------------------. *--- displaying all labels label list *--- saving dta dataset with labels save "DTA_DATA_PATH"