| |
| |
Preface | |
| |
| |
Motivation and Purpose | |
| |
| |
About the National Study of Youth and Religion | |
| |
| |
A Note on Versions | |
| |
| |
A Note on Notation | |
| |
| |
References | |
| |
| |
Acknowledgments | |
| |
| |
| |
Foundations for Working with Stata | |
| |
| |
| |
Getting to Know Stata 12 | |
| |
| |
What You See | |
| |
| |
Getting Started With Data Files | |
| |
| |
Opening and Saving Stata Data Files | |
| |
| |
Data Browser and Editor | |
| |
| |
Entering Your Own Data | |
| |
| |
Using Different Types of Data Files in Stata | |
| |
| |
Types of Variables in Data Files | |
| |
| |
Exercises | |
| |
| |
| |
The Essentials | |
| |
| |
Intuition and Stata Commands | |
| |
| |
The Structure of Stata Commands | |
| |
| |
Command | |
| |
| |
Variables | |
| |
| |
if Statements | |
| |
| |
Options | |
| |
| |
Executing a Command Using the Command Window | |
| |
| |
The 5 Essential Commands | |
| |
| |
tabulate | |
| |
| |
summary | |
| |
| |
generate | |
| |
| |
replace (if) | |
| |
| |
recode | |
| |
| |
Nonessential, Everyday Commands | |
| |
| |
rename | |
| |
| |
drop/keep (if) | |
| |
| |
describe | |
| |
| |
display | |
| |
| |
set more off | |
| |
| |
Summary of Commands Used in This Chapter | |
| |
| |
Exercises | |
| |
| |
| |
Do Files and Data Management | |
| |
| |
What Is a Do File? | |
| |
| |
Opening and Saving Do Files | |
| |
| |
Translation From the Command Window | |
| |
| |
Getting the Most Out of Do Files | |
| |
| |
Data Management | |
| |
| |
Working With Labels | |
| |
| |
Missing Data | |
| |
| |
Using String Variables | |
| |
| |
Saving Results | |
| |
| |
Summary of Commands Used in This Chapter | |
| |
| |
Exercises | |
| |
| |
| |
Quantitative Analysis with Stata | |
| |
| |
| |
Descriptive Statistics | |
| |
| |
Frequency Distributions | |
| |
| |
Histograms, Bar Graphs, and Pie Charts | |
| |
| |
Measures of Central Tendency and Variability | |
| |
| |
Box Plots | |
| |
| |
Summary of Commands Used in This Chapter | |
| |
| |
Exercises | |
| |
| |
| |
Relationships Between Nominal and Ordinal Variables | |
| |
| |
Cross-Tabulations | |
| |
| |
Chi-Square Test | |
| |
| |
Measures of Association | |
| |
| |
Elaboration | |
| |
| |
Multivariate Bar Graphs | |
| |
| |
Summary of Commands Used in This Chapter | |
| |
| |
Exercises | |
| |
| |
| |
Relationships Between Different Measurement Levels | |
| |
| |
Testing Means | |
| |
| |
Confidence Intervals | |
| |
| |
Testing a Specific Value (One-Sample t Test) | |
| |
| |
Testing the Mean of Two Groups (Independent-Samples t Test) | |
| |
| |
Analysis of Variance (ANOVA) | |
| |
| |
Summary of Commands Used in This Chapter | |
| |
| |
Exercises | |
| |
| |
| |
Relationships Between Interval-Ratio Variables | |
| |
| |
Correlation | |
| |
| |
Scatterplots | |
| |
| |
Linear Regression | |
| |
| |
Multiple Linear Regression | |
| |
| |
Dichotomous (Dummy) Variables and Linear Regression | |
| |
| |
Summary of Commands Used in This Chapter | |
| |
| |
Exercises | |
| |
| |
| |
Enhancing Your Command Repertoire | |
| |
| |
Stata Help Files | |
| |
| |
Ways to Search and Access | |
| |
| |
Structure and Language | |
| |
| |
Advanced Convenience Commands | |
| |
| |
tab, gen(newvar) | |
| |
| |
egen | |
| |
| |
mark and markout | |
| |
| |
alpha, gen(newvar) | |
| |
| |
Summary of Commands Used in This Chapter | |
| |
| |
Exercises | |
| |
| |
Appendix: Getting to Know Stata 11 | |
| |
| |
Chapter Exercise Solutions | |
| |
| |
"How To" Index | |
| |
| |
About the Author | |