Day 11 Methodological Lecture Migration. Measuring migration Create a event variable from comparison of unique values of UNIQUE_VILLAGE_ID Make sure to.

Slides:



Advertisements
Similar presentations
Stata as a Data Entry Management Tool
Advertisements

Sociology 601 Class 24: November 19, 2009 (partial) Review –regression results for spurious & intervening effects –care with sample sizes for comparing.
Generating new variables and manipulating data with STATA Biostatistics 212 Lecture 3.
 Purpose: To apply concepts learned in class to the real world  4 Parts  A: Profile of a Census Tract  B: Maps  C: Comparison of the Tract to the.
CMGPD-LN Methodological Lecture Day 7 Health and Mortality.
SAS Programming: Working With Variables. Data Step Manipulations New variables should be created during a Data step Existing variables should be manipulated.
SJTU CMGPD 2012 Methodological Lecture Day 2 TABLE, COLLAPSE, HISTOGRAM, TWOWAY BAR.
CMGPD-LN Methodological Lecture Day 1 Why Use Historical Data? Origins of the CMGPD-LN Basic Characteristics of the CMPGD-LN.
How to download data? An example of downloading the most recent 100 cases from the Hand-Size activity. First, click on the ‘Download’ link to take you.
Stata Review: Part II Biost/Epi 536 Discussion Section October 13, 2009.
CMGPD-LN Methodological Lecture Day 7 Health and Mortality.
Getting Started with your data
Pet Fish and High Cholesterol in the WHI OS: An Analysis Example Joe Larson 5 / 6 / 09.
Household Projections for Northern Ireland 9 th September 2009 Dr David Marshall & Dr Jos IJpelaar Demography & Methodology Branch Northern Ireland Statistics.
Consumption calculations with real data – CORRECTED VERSION (CORRECTIONS IN RED) Gretchen Donehower Day 3, Session 2, NTA Time Use and Gender Workshop.
Stata 12 Merging Guide Nathan Favero Texas A&M University October 19, 2012.
Coding for Excel Analysis Optional Exercise Map Your Hazards! Module, Unit 2 Map Your Hazards! Combining Natural Hazards with Societal Issues.
London, Microsimulation in decision support The latest news about our results József Csicsman
Srinivasulu Rajendran Centre for the Study of Regional Development (CSRD) Jawaharlal Nehru University (JNU) New Delhi India
Patron Self-Registration. Self-Registration As of September 2014, patrons may register for a PINES library card through the PINES web site at:
SJTU CMGPD 2012 Methodological Lecture Day 9 Kinship.
G Lecture 121 Analysis of Time to Event Survival Analysis Language Example of time to high anxiety Discrete survival analysis through logistic regression.
1 4HPlus – Retrieving Information March Retrieving Information The real value of any information based software is in the data and reports that.
SJTU CMGPD Methodological Lecture Day 8 Family and contextual influences.
Lead Management Tool Partner User Guide March 15, 2013
Key Data Management Tasks in Stata
SJTU CMGPD 2012 Methodological Lecture Recommended Acknowledgments Contemporary Applications of Historical Data Origins of the CMGPD-LN Key Features.
SJTU CMGPD 2012 Methodological Lecture Day 4 Household and Relationship Variables.
Chapters 1 and 2 Week 1, Monday. Chapter 1: Stats Starts Here What is Statistics? “Statistics is a way of reasoning, along with a collection of tools.
MathXL ® for School Student Training Series Enrolling in Your MathXL ® for School Class & Setting Up Your Computer for MathXL ® for School.
FIRST GADGETEER PROJECT. Where are you? Making a VS project Parts of a C# program Basics of C# syntax Debugging in VS Questions? 2.
Being Productive with Stata and VA Data Give me six hours to chop down a tree and I will spend the first four sharpening the axe. --Abraham Lincoln Todd.
Data Analysis Lab 02 Using Crosstabs to compare percentages.
Statistics Division Beijing, China 25 October, 2007 EC-FAO Food Security Information for Action Programme Side Event Food Security Statistics and Information.
The Chicago Guide to Writing about Multivariate Analysis, 2nd Edition. Data structure for a discrete-time event history analysis Jane E. Miller, PhD.
SJTU CMGPD 2012 Methodological Lecture Day 3 Position and Status Variables.
Consumption calculations with real data Gretchen Donehower Day 3, Session 2, NTA Time Use and Gender Workshop Wednesday, May 23, 2012 Institute for Labor,
Crude Rates and Standardisation Standardisation: used widely when making comparisons of rates between population groups and over time (ie. Number of health.
CHAPTER 6: Two-Way Tables. Chapter 6 Concepts 2  Two-Way Tables  Row and Column Variables  Marginal Distributions  Conditional Distributions  Simpson’s.
Please turn off cell phones, pagers, etc. The lecture will begin shortly.
Math 409/409G History of Mathematics The Fibonacci Sequence Part 1.
Stat1510: Statistical Thinking and Concepts Two Way Tables.
Computing for Research I Spring 2014 Primary Instructor: Elizabeth Garrett-Mayer Introduction to Stata February 19.
SJTU CMGPD 2012 Methodological Lecture Day 1 (supplemental) Strengths and Weaknesses of the CMGPD-LN.
1.1 Analyzing Categorical Data Pages 7-24 Objectives SWBAT: 1)Display categorical data with a bar graph. Decide if it would be appropriate to make a pie.
APPLIED DATA ANALYSIS IN CRIMINAL JUSTICE CJ 525 MONMOUTH UNIVERSITY Juan P. Rodriguez.
SW388R7 Data Analysis & Computers II Slide 1 Incorporating Nonmetric Data with Dummy Variables The logic of dummy-coding Dummy-coding in SPSS.
1 M04- Graphical Displays 2  Department of ISM, University of Alabama, 2003 Graphical Displays of Data.
Hukou Identity, Education and Migration: The Case of Guangdong
Econometrics-3 XENA BONDARENKO. I. Preparation for Data Analysis a)Create / change working directory b)Specify data c)End Stata d)The four Stata windows.
National Center for Health Statistics DCC CENTERS FOR DISEASE CONTROL AND PREVENTION Measuring Injury Using the National Health Interview Survey Margaret.
Two file sequential file processing (maximum 1 record per id on each file) Please use speaker notes for additional information!
Stata: Getting Starting and Being Productive with VA Data Give me six hours to chop down a tree and I will spend the first four sharpening the axe. --Abraham.
3.3 More about Contingency Tables Does the explanatory variable really seem to impact the response variable? Is it a strong or weak impact?
Mannheim Research Institute for the Economics of Aging SHARE Data Cleaning General rules and procedures Stephanie Stuck MEA Antwerp.
SAS ® 101 Based on Learning SAS by Example: A Programmer’s Guide Chapters 5 & 6 By Ravi Mandal.
ECONOMETRICS ii – spring 2018
Dale Rhoda & Mary Kay Trimner Stata Conference 2018
Week 5 Lecture 2 Chapter 8. Regression Wisdom.
Do Statistical Analysis with Stata
Introduction to Stata Spring 2017.
Transparency 4a.
Stata Basic Course Lab 4.
CMGPD-LN Methodological Lecture
Data Management – Processing
Warm-Up (Add to your notes!)
CMGPD-LN Methodological Lecture Day 4
Graphing Notes Graphs and charts are great because they communicate information visually. For this reason, graphs are often used in science, newspapers,
CMGPD-LN Methodological Lecture Day 3
A Brief Introduction to Stata(2)
Presentation transcript:

Day 11 Methodological Lecture Migration

Measuring migration Create a event variable from comparison of unique values of UNIQUE_VILLAGE_ID Make sure to exclude Guosantun 1780 and Aerjishan Make sure to exclude observations with missing values. – Some location names in the data were originally administrative units ( annotated with suo shu ge tun) and have been converted to missing. Because of problems in the original data, some people appear to move somewhere, then move back in the next register. – Need to address those in creation of a variable.

Creating a variable for village moves use "C:\Users\Cameron Campbe\Documents\Baqi\CMGPD-LN from ICPSR\ICPSR_27063\DS0001\ Data.dta", clear merge 1:1 RECORD_NUMBER using "C:\Users\Cameron Campbe\Documents\Baqi\CMGPD-LN from ICPSR\ICPSR_27063\DS0003\ Data.dta" drop if (DATASET == 10 & YEAR == 1780) | (DATASET == 25 & YEAR == 1906) drop if UNIQUE_VILLAGE_ID == -99 bysort PERSON_ID (YEAR): generate at_risk_move = PRESENT == 1 & _n < _N & YEAR[_n+1] == YEAR+3 bysort PERSON_ID (YEAR): generate next_move = (UNIQUE_VILLAGE_ID[_n+1] != UNIQUE_VILLAGE_ID) & at_risk_move bysort PERSON_ID (YEAR): generate move_back = next_move & UNIQUE_VILLAGE_ID[_n+2] == UNIQUE_VILLAGE_ID & _n+2 <= _N tab move_back if next_move bysort PERSON_ID (YEAR): replace move_back = 1 if next_move & _n < _N & UNIQUE_VILLAGE_ID[_n-1]==UNIQUE_VILLAGE_ID[_n+1] & UNIQUE_VILLAGE_ID != UNIQUE_VILLAGE_ID[_n+1] tab move_back if next_move replace next_move = next_move & (move_back == 0)

. bysort PERSON_ID (YEAR): generate move_back = next_move & UNIQUE_VILLAGE_ID[_n+2] == UNIQUE_VILLAGE > _ID & _n+2 <= _N. tab move_back if next_move move_back | Freq. Percent Cum | 14, | 1, Total | 16, bysort PERSON_ID (YEAR): replace move_back = 1 if next_move & _n < _N & UNIQUE_VILLAGE_ID[_n-1]==UN > IQUE_VILLAGE_ID[_n+1] & UNIQUE_VILLAGE_ID != UNIQUE_VILLAGE_ID[_n+1] (2773 real changes made). tab move_back if next_move move_back | Freq. Percent Cum | 12, | 4, Total | 16, replace next_move = next_move & (move_back == 0) (4642 real changes made)

keep if at_risk_move bysort YEAR: egen mean_next_move = mean(next_move) bysort YEAR: generate first_in_year = _n == 1 twoway bar mean_next_move YEAR if first_in_year & YEAR >= 1789, scheme(s1mono) xtitle("Year") ytitle("Prop. individuals changing village in next 3 years") /* Note that this is picking up if anyone in the household moves in the next 3 years */ bysort YEAR HOUSEHOLD_ID: egen hh_next_move = max(next_move) bysort YEAR HOUSEHOLD_ID: keep if _n == 1 bysort YEAR: egen mean_hh_next_move = mean(hh_next_move) bysort YEAR: replace first_in_year = _n == 1 twoway bar mean_hh_next_move YEAR if first_in_year & YEAR >= 1789, scheme(s1mono) xtitle("Year") ytitle("Prop. households changing village in next 3 years")

Illegal departure (tao) ABSCONDED – Indicates that a male is currently annotated in the register as tao. – Never annotated for females. EVER_ABSCONDED – Indicates that a male at some point in his life was annotated as tao, even if it wasn’t in this register. – May be used to exclude observations in mortality analysis, since recording of men ever identified as tao seems poor.

use "C:\Users\Cameron Campbe\Documents\Baqi\CMGPD-LN from ICPSR\ICPSR_27063\DS0001\ Data.dta", clear merge 1:1 RECORD_NUMBER using "C:\Users\Cameron Campbe\Documents\Baqi\CMGPD-LN from ICPSR\ICPSR_27063\DS0003\ Data.dta" generate at_risk_tao = ABSCONDED == 0 & PRESENT == 1 & NEXT_3 == 1 bysort PERSON_ID (YEAR): generate next_tao = at_risk_tao & _n < _N & ABSCONDED[_n+1] == 1 keep if at_risk_tao bysort YEAR: egen mean_next_tao = mean(next_tao) bysort YEAR: generate first_in_year = _n == 1 twoway bar mean_next_tao YEAR if first_in_year, scheme(s1mono) ytitle("Proportion of men absconding in next 3 years")