CENTER FOR FAMILY & DEMOGRAPHIC RESEARCH · PDF filemarital status of mother, 2005-2010 ......
Transcript of CENTER FOR FAMILY & DEMOGRAPHIC RESEARCH · PDF filemarital status of mother, 2005-2010 ......
CENTER FOR FAMILY & DEMOGRAPHIC RESEARCH
Making Charts & Tables Fall 2017 Workshop Series
Nearly all men can stand adversity, but if you want to test a man’s character, give him power.
Abraham Lincoln
Source: “Slide:ology: The art and science of creating great presentations” by Nancy Durante
Today’s Presentation…
1. Why Charts?
2. Structure of an Excel Chart
3. Different Types of Charts (w/ dos and don’ts)
4. Basic Principles of Design
5. Getting Tables from Stata Excel Word
CHARTS?
WHY-
“Designing good charts, however, presents more challenges than tabular display as it draws on the talents of both the scientist and the artist. You have to know and understand your data, but you also need a good sense of how the reader will visualize the chart’s graphical elements.”
~Gary Klass
Picture Superiority EffectInformation is better remembered in
tests of recall and item recognition
when presented as pictures rather
than words
Fruit <
THE STRUCTURE OF
AN EXCEL CHART?
What makes up-
Let’s Dissect…
36.0
24.2
0
5
10
15
20
25
30
35
40
45
50
$0 $5 $10 $15 $20 $25 $30 $35 $40
Rat
es
pe
r 1
,00
0 a
t R
isk
Po
pu
lati
on
HMI Spending Per Population at Risk of Marriage or Divorce
Predicted Marriage & Divorce RatesUpper Bounds (UB) & Lower Bounds (LB)
UB Mar Rt LB UB Div Rt LB
Chart Title
Legend
Axis Titles
Axis
Gridlines
Data Labels
Sources: U.S. Census Bureau, American Community Survey, 2008-2011; HMI spending data– Hawkins et al., 2013. Source
THE DIFFERENT
TYPES OF CHARTS?
What are-
HistogramsA vertical bar chart that depicts the
distribution of a set of data
Histograms, example
Pie ChartsGenerally used to show percentage or
proportional data classified into nominal or
ordinal categories
Pie Charts, examples
Simple Pie
Childcare15%
School/Training
20%
Layoff19%
Other46%
Top Reasons for Fathers Leaving the Workforce in 2008
Source: Survey of Income and Program Participation, 2008 March Supplement
Pie Charts, examples
Pie-of-Pie Doughnut
Did not finish44%
Associate's degree
7%
Bachelor's degree
49%
Percent of young adults who enroll in a 4-year program by
degree earned by age 25
Source: National Longitudinal Survey of Youth 1997, Rounds 1-13: 1997-2009 weighted. U.S. Department of Labor, Bureau
of Labor Statistics, NCFMR analyses of valid cases.
Single18%
Cohabiting25%
Married57% Unmarried
43%
Percent of births by informal marital status of mother, 2005-
2010
Source: NSFG 2006-2010
Bar Chart vs. Pie Charts
19%
20%
12%
8%
2%
33%
13%
7%
9%
11%
None
GED
H.S.
Assoc. Deg.
B.A.+
Blacks
Hispanics
Whites
Men
Women
Pre
-un
ion
Fir
st B
irth
Prevalence of Pre-union First Birth across Demographic Characteristics
Yes33%
No67%
Prevalence of Pre-union First Birth by Race/Ethnicity:Blacks
Yes13%
No87%
Hispanics
Yes7%
No93%
Whites
Source: National Longitudinal Survey of Youth 1997 (NLSY97), Rounds 1-13: 1997-2009 (weighted). U.S. Department of Labor, Bureau of Labor Statistics, NCFMR analyses of valid cases.
Bar Chart vs. Pie Charts• Percentage Distribution of Number of Births Among Mothers Aged 40-44
20%
39%
26%
15%
1 Birth
2 Births
3 Births
4+ Births
Clustered Bar Chart
1 Birth20%
2 Births39%
3 Births26%
4+ Births15%
Doughnut Chart
1 Birth20%
2 Births39%
3 Births26%
4+ Births15%
2-D Pie Chart
Bar Chart vs. Pie Charts
Column & Bar ChartsUseful for showing data changes over a
period of time or for illustrating
comparisons among items
Column Charts, examplesSimple
74%
80%
49%
62%
70%
All fathers White Black NB Hispanic FB Hispanic
Fathers Living with All of Their ChildrenRace, Ethnicity & Nativity
Side-by-Side
11%
25%20% 22%
25%
44%
38% 37%
0%
10%
20%
30%
40%
50%
60%
70%
80%
White Black Asian Hispanic
Percentage of Same-Sex Couple Households with Minor Children by Sex of Couple and Race/Ethnicity of Household
Head
Male-Male Female-Female
Source: NSFG 2006-2010 Source: U.S. Census Bureau, American Community Survey, 1-Year Estimates, 2012
Column Charts, examples
-25%
-18%
-12%
-8%
16%
Percent Change in Share of Aggregate Income from 1970-2009
Lowest fifth Second fifth Third fifth Fourth fifth Highest fifth
Source: U.S. Census Bureau, Current Population Survey, Annual Social and Economic Supplements
Column Charts, examples
55%
65%
31%
52% 53%
76%
6%11%
1%6%
11%19%
Married CoupleHouseholds
Different SexCouples
MaleSame SexCouples
FemaleSame SexCouples
FatherOnly
MotherOnly
Cohabiting Households Single Parent Households
Public Assistance Participation among U.S. Children in Poverty by Family Structure, 2010
SNAP TANF
Source: U.S. Census Bureau, American Community Survey, 1-Year Estimates, 2010
Column Charts, examples
15% 16% 17% 18%
6%11%
18%24%21%
27%
35%42%
0%
20%
40%
60%
80%
100%
1980-1984 1990-1994 1997-2001 2005-2009
Changes in the Shares of Births to Single and Cohabiting Mothers Under Age 40
Single Cohabiting Total Non-Marital
Sources: 1980-1984 data, Bumpass & Lu (2000) using NSFH, 1987/1988; 1990-1994 & 1997-2001 data, Kennedy & Bumpass (2008) using NSFG 1995 & NSFG 2002; 2005-2009, NCFMR analyses using NSFG 2006-2010.
Line ChartsIdeal for showing trends over time
Line Charts, examples
4.4
30.9
2.4
20.422.1
57.1
0
10
20
30
40
50
60
70
1955-59 1960-64 1965-69 1970-74 1975-79 1980-84 1985-89 1990-94 1995-99 2000-04 2005-09
Overall
White
Black
Source: The Integrated Fertility Survey Series (IFSS) is a project of the Population Studies Center and the Inter-university Consortium for Political and Social Research at the University of Michigan, with funding from the Eunice Kennedy Shriver National Institute of Child Health and Human Development (NICHD, grant 5R01 HD053533; Pamela J. Smock, PI).
Share of Married Mothers Experiencing a Premarital Birth, by Race and Marriage Cohort
Line Charts, examples
46.1
33.9
18.4 18.4
$5
$122
$0
$20
$40
$60
$80
$100
$120
$140
$160
0
5
10
15
20
25
30
35
40
45
50
2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010
Do
llar
Am
ou
nts
in M
illio
ms
Rat
es
pe
r 1
,00
0 a
t R
isk
Annual HMI Spending and Marriage & Divorce Rates, 2000 - 2010
Marriage Rate Divorce Rate HMI Spending
Sources: CDC/NCHS, National Vital Statistics System, 2000; Glass & Levchak, 2010, NCFMR County-Level Marriage & Divorce Data, 2000; U.S. Census Bureau, Decennial Census, 2000; U.S. Census Bureau, American Community Survey, 1-Year Estimates, 2008 – 2010; HMI Spending data – Hawkins et al., 2013.
Line Charts, examplesFigure. Crossover in the Median Age at First Marriage and First Birth, 1980-Present
Source: Centers for Disease Control and Prevention, National Center for Health Statistics, Vital Stats and U.S. Census Bureau, American Community Survey, 2015
Scatter PlotsCommonly used to show the relationship
between two variables e.g. correlation
Scatter Plots, example
AL
AZ
ARCA
CO
CT
DE
DC
FLGA HI
IDIN
IA
KY
LA
ME
MD
MAMI
MN
MS
MO
NENH
NJ
NM
NYNC
ND
OHOK
PA
RI
SCTN
TX
UT
VA
WV
WI
WY
230
240
250
260
270
280
290
0 5 10 15 20 25 30
19
92
Sta
te 8
th-g
rad
e N
AEP
Mat
h S
core
% Students watching TV 6 hrs+ per day
State Math Scores and Students' TV Viewing Habits
Source: National Center for Educational Statistics, 1994
Line Graph vs. Scatter Plots
Year Ratio1970 3.01980 2.01990 2.12000 2.42008 1.72009 1.82010 1.72011 1.72012 1.72013 1.82014 2.02015 2.1
Women’s Marriage to Divorce Ratio, 1970-2015
Sources: 1970-2000, National Center for Health Statistics; 2008-2015, U.S. Census Bureau, American Community Survey 1-yr est.
Line Graph vs. Scatter Plots
Line with Markers Scatter with Smooth Lines and Markers
3.0
2.0 2.1
2.4
1.7
2.1
0.0
0.5
1.0
1.5
2.0
2.5
3.0
3.5
1970 1980 1990 2000 2010
Women's Marriage to Divorce Ratio, 1970-2015
3.0
2.0 2.1
2.4
1.7
2.1
0.0
0.5
1.0
1.5
2.0
2.5
3.0
3.5
19
70
19
80
19
90
20
00
20
08
20
09
20
10
20
11
20
12
20
13
20
14
20
15
Women's Marriage to Divorce Ratio, 1970-2015
Area ChartsShow percentage or proportional data
classified into nominal or ordinal categories
over time
Area Charts, example
0%
20%
40%
60%
80%
100%
1970 1980 1990 2000 2008 2012
Marital Status of U.S. Population Aged 15 and Older, 1970-2012
Married
Never Married
Divorced
Widowed
Source: 1970-2000 data, U.S. Census Bureau, Current Population Survey, March and Annual Social and Economic Supplements. 2008 and 2012 data, U.S. Census Bureau, American Community Survey, (IPUMS)
*Charts to be Cautious of…
• Pie/Doughnut Charts
• Area Charts
• Radar Charts
Charts to be Cautious of…
• Doughnut Charts
• Area Charts
• Radar Charts
• Circle Charts
Divorce Rates per 1,000 by Age Groups, 2015
Source: U.S. Census Bureau, American Community Survey, 2015 1-year est.
Charts to be Cautious of…Divorce Rates per 1,000 by Age Groups, 2015
Source: U.S. Census Bureau, American Community Survey, 2015 1-year est.
Vs.
Charts to be Cautious of…
• Doughnut Charts
• Area Charts
• Radar Charts
• Circle Charts
• Unit Charts
Charts to be Cautious of…
• Doughnut Charts
• Area Charts
• Radar Charts
• Circle Charts
• Unit Charts
• Funnel Charts
Source: https://peltiertech.com/bad-graphics-funnel-chart/
Charts to be Cautious of…
• Doughnut Charts
• Area Charts
• Radar Charts
• Circle Charts
• Unit Charts
• Funnel Charts
• Waterfall Charts
Source: http://community.powerbi.com/t5/Desktop/Stacked-waterfall-chart/td-p/188067
Charts to be Cautious of…
• Doughnut Charts
• Area Charts
• Radar Charts
• Circle Charts
• Unit Charts
• Funnel Charts
• Waterfall Charts
Source: http://community.powerbi.com/t5/Desktop/Stacked-waterfall-chart/td-p/188067
Charts to be Cautious of…
• Doughnut Charts
• Area Charts
• Radar Charts
• Circle Charts
• Unit Charts
• Funnel Charts
• Waterfall Charts Source: https://en.wikipedia.org/wiki/Waterfall_chart
BASIC PRINCIPLES OF
CHART DESIGN?
What are some-
1. Simplify
• Sort data in a meaningful way
• Minimize ink-to-data ratio Remove unneeded chart elements
– Gridlines
– Chart borders
– Axis titles
– Legends
– Markers & data labels
– Decimal points (in axis & data labels)
– Trend lines
– NO 3D charts!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
1. Simplify
NO 3D charts!
2. Color vs. Black & White
• When in doubt black & white
• Color can help tell a story
• Color = branding (e.g. CFDR, NCFMR,
BGSU)
– Use a cohesive and consistent color palette
– Be mindful of how audience will view
• Excel vs. Word vs. PDF
• Color vs. B&W print copy
• Colorblind audience
3. Do NOT Use Distorted Charts
• Do NOT misrepresent your data!
• Use appropriate and consistent axis and
scales
4. Present Related Charts Simultaneously
• One-after-another or side-by-side if
possible
– Emphasizes importance of appropriate axis
and scales
5. Know Your Audience
• Academics vs. lay folks
• Undergraduate students vs. graduate
students
• Graduate students vs. professors
• PAA presentation vs. job talk
6. TMC = TMI
• Too many charts (TMC) is as bad as too
much information (TMI)…
Do NOT overload your audience!
Let’s apply some principles:
Which is easier to understand?
35.97
24.25
05
101520253035404550
$0.00 $10.00 $20.00 $30.00 $40.00Rat
es
pe
r 1
,00
0 a
t R
isk
Po
pu
lati
on
HMI Spending Per Population at Risk of Marriage or Divorce
Predicted Marriage & Divorce RatesUpper Bounds (UB) & Lower Bounds (LB)
UB Mar Rt LB
UB Div Rt LB
3936
19
24***
0
5
10
15
20
25
30
35
40
45
$0 $8 $16 $24 $32
Predicted Marriage & Divorce Rates Given State-level HMI Spending
Mar Rt Div Rt
Sources: U.S. Census Bureau, American Community Survey, 2008-2011; HMI spending data– Hawkins et al., 2013.
Unformatted Formatted
-5.000
0.000
5.000
10.000
15.000
20.000
25.000
1 2 3 4 5 6 7 8 9 10111213141516
Black Women
White Women
-10
-5
0
5
10
15
20
25
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
Parity
Effect of Parity on Ever Marrying for Black and White Women
Black Women White Women
7. Do you need a chart?
$117 mill
ion Increase in annual
HMI spending in the U.S. from 2000 – 2010
Sources: U.S. Census Bureau, American Community Survey, 2008-2011; HMI spending data– Hawkins et al., 2013.
7. Do you need a chart?
Source: U.S. Census Bureau, American Community Survey, 2015 1-yr est.
7. Do you need a chart?
Source: U.S. Census Bureau, American Community Survey, 2015 1-yr est.
Geographic Variation of Women’s Marriage to Divorce Ratio Among States, 2015
GET MY STATA OUTPUT
INTO A TABLE?
How do I-
1. Know Your Audience…
What type of table do you need to produce?
• For the prof you work for?
• For a class paper, conference, or journal?
• For a conference poster?
2. Gather your materials…
• Find a recently published article with a
similar research design in the journal you
will be submitting to.
• If you don’t know, go with APA format.
https://owl.english.purdue.edu/owl/resource/560/01/
2. Gather your materials, cont.
Open the necessary programs on your
computer:
• Stata
• Excel
• Word
3. Set Your Margins in Excel
3. Set Your Margins in Excel
4. Generate Table in Stata
Use the estimates store command in Stata
4. Generate Table in Stata
Use the estimates store command in Stata
4. Generate Table in StataUse the estimates table command in Stata. estimates table model1 model2 model3 model4 model5
-------------------------------------------------------------------------------
Variable | model1 model2 model3 model4 model5
-------------+-----------------------------------------------------------------
boomerang_cs | -.38394325 -.32289543 -.29467411 -.36142479 -.34357681
plnmvout_cs | -.42568424 -.4941286 -.50524127 -.52201004
payany_cs | -.29451219 -.33561217 -.21573598 -.19835859
age1923 | .02314174 .05050027 .0464386
male | .01879246 -.02130933 -.04100863
|
ethrace |
2. Black | .3896079 .45061936 .45208932
3. Hispanic | .5645867 .60556757 .61579612
4. Other | -.57156084 -.69895938 -.66721316
|
goodhlth_cs | .69876912 .71110143
mhealth_cs | -.18117434 -.17903428
|
edu |
1. <H.S. | -.04948128 -.03471297
2. H.S. | -.05778116 -.05438757
3. S.Col. | -.12287664 -.1248107
|
enrolled | .06616018 .0571787
curwork | -.00256022 -.01759482
ln_indinc_~s | .01462601 .01383715
|
relstdater~s |
1. Single | .06739666
2. Dating | .14322095
|
dbiokd | -.10739817
|
parentcomp |
1. Mom, o.. | -.05301778
2. Dad, o.. | -.19255328
|
sibagecomp |
1: Only ..) | .03496901
2: Only ..) | -.04589592
3: Both ..) | .07596144
|
_cons | 5.7554709 6.1174281 6.0206667 5.6450508 5.58019
-------------------------------------------------------------------------------
4. Generate Table in Stata
. help estimates
4. Generate Table in Stata. estimates table model1 model2
model3 model4 model5, b(%10.2f) star
4. Generate Table in Stata. estimates table model1 model2 model3 model4 model5,
b(%10.2f) stats(N r2) varlabel allbaselevels se
5. Get Stata Table Into Excel. estimates table model1 model2 model3 model4 model5,
b(%10.2f) stats(N r2) varlabel allbaselevels se
Copy Ctrl+C
Copy table Ctrl+Shift+C
Copy table as HTML Ctrl+Shift+Alt+C
Select all Ctrl+A
Clear results
Preferences…
Font…
Print…
6. Paste Table Into Excel
7. Format…in Excel First
7. Format…in Excel First
7. Format…in Excel First
7. Format…in Excel First
7. Format…in Excel First
7. Format…in Excel First
Variables SE SE SE SE SE
Boomeranged -0.38 * 0.16 -0.32 * 0.16 -0.29 0.16 -0.36 * 0.16 -0.34 * 0.16
Plans to move out -0.43 ** 0.15 -0.49 ** 0.15 -0.51 *** 0.15 -0.52 *** 0.15
Pays room and board -0.29 0.18 -0.34 0.19 -0.22 0.18 -0.20 0.19
Aged 19-23 0.02 0.18 0.05 0.17 0.05 0.18
Male 0.02 0.15 -0.02 0.15 -0.04 0.16
Race/Ethnicity (White,
ref.)
Black 0.39 * 0.16 0.45 ** 0.16 0.45 * 0.18
Hispanic 0.56 ** 0.21 0.61 ** 0.21 0.62 ** 0.21
Other -0.57 0.43 -0.70 0.44 -0.67 0.44
Good physical health 0.70 ** 0.25 0.71 ** 0.26
Depressive symptomology -0.18 ** 0.07 -0.18 ** 0.07
Table 2. Logistic Regression Predicting Young Adult Satisfcation with Parental Coresidence Situation
Model 1 Model 2 Model 3 Model 4 Model 5
b b b b b
8. Paste in Word
8. Paste in Word