Statistics and Data Visualization Using R (2024)

Preface

Acknowledgments

About the Author

Chapter 1: Getting Started

Learning Objectives
Overview
R, RStudio, and R Markdown
Objects and Functions
Getting Started in RStudio
Navigating RStudio With R Markdown
Using R Markdown Files Versus R-Scripts
A Little Practice
Summary
Common Problems
Review Questions
Practice on Analysis and Visualization
Annotated R Functions
Answers

Chapter 2: An Introduction to Data Analysis

Learning Objectives
Overview
Motivating Data Analysis
The Main Components of Data Analysis
Developing Hypotheses by Describing Data
Model Building and Estimation
Diagnostics
Next Questions
Summary
Common Problems
Review Questions
Practice on Analysis and Visualization
Annotated R Functions
Answers

Chapter 3: Describing Data

Learning Objectives
Overview
Data Sets and Variables
Different Kinds of Variables
Describing Data Saves Time and Effort
Measurement
Summary
Common Problems
Review Questions
Practice on Analysis and Visualization
Annotated R Functions
Answers

Chapter 4: Central Tendency and Dispersion

Learning Objectives
Overview
Measures of Central Tendency: The Mode, Mean, and Median
Mean Versus Median
Measures of Dispersion: The Range, Interquartile Range, and Standard Deviation
Interquartile Range Versus Standard Deviation
Summary
Common Problems
Review Questions
Practice on Analysis and Visualization
Annotated R Functions
Answers

Chapter 5: Univariate and Bivariate Descriptions of Data

Learning Objectives
Overview
The Good, the Bad, and the Outlier
Five Views of Univariate Data
Are They in a Relationship?
Summary
Common Problems
Review Questions
Practice on Analysis and Visualization
Annotated R Functions
Answers

Chapter 6: Transforming Data

Learning Objectives
Overview
Theoretical Reasons for Transforming Data
Transforming Data for Practical Reasons
Transforming Data—Continuous to Categorical Variables
Transforming Data—Changing Categories
Box-Cox Transformations
Summary
Common Problems
Review Questions
Practice on Analysis and Visualization
Annotated R Functions
Answers

Chapter 7: Some Principles of Displaying Data

Learning Objectives
Overview
Some Elements of Style
The Basic Elements of a Story
Documentation (Establishing Credibility as a Storyteller)
Build an Intuition (Setting the Context)
Show Causation (The Journey)
From Causation to Action (The Resolution)
Summary
Common Problems
Review Questions
Practice on Analysis and Visualization
Annotated R Functions
Answers

Chapter 8: The Essentials of Probability Theory

Overview
Learning Objectives
Populations and Samples
Sample Bias and Random Samples
The Law of Large Numbers
The Central Limit Theorem
The Standard Normal Distribution
Summary
Common Problems
Review Questions
Practice on Analysis and Visualization
Annotated R Functions
Answers

Chapter 9: Confidence Intervals and Testing Hypotheses

Learning Objectives
Overview
Confidence Intervals With Large Samples
Small Samples and the t-Distribution
Comparing Two Sample Means
Confidence Levels
A Brief Note on Statistical Inference and Causation
Summary
Common Problems
Review Questions
Practice on Analysis and Visualization
Annotated R Functions
Answers

Chapter 10: Making Comparisons

Overview
Learning Objectives
Why Do We Make Comparisons?
Questions That Beg Comparisons
Comparing Two Categorical Variables
Comparing Continuous and Categorical Variables
Comparing Two Continuous Variables
Exploratory Data Analysis: Investigating Abortion Rates in the United States
Good Analysis Generates Additional Questions
Summary
Common Problems
Review Questions
Practice on Analysis and Visualization
Annotated R Functions
Answers

Chapter 11: Controlled Comparisons

Learning Objectives
Overview
What Is a Controlled Comparison?
Comparing Two Categorical Variables, Controlling for a Third
Comparing Two Continuous Variables, Controlling for a Third
Arguments and Controlled Comparisons
Summary
Common Problems
Review Questions
Practice on Analysis and Visualization
Annotated R Functions
Answers
Practice on Analysis and Visualization

Chapter 12: Linear Regression

Learning Objectives
Overview
The Advantages of Linear Regression
The Slope and Intercept in Linear Regression
Goodness of Fit (R2 Statistic)
Statistical Significance
Examples of Bivariate Regressions
Summary
Common Problems
Review Questions
Practice on Analysis and Visualization
Annotated R Functions
Answers

Chapter 13: Multiple Regression

Learning Objectives
Overview
What Is Multiple Regression?
Regression Models and Arguments
Regression Models, Theory, and Evidence
Interpreting Estimates in Multiple Regression
Example: Homicide Rate and Education
Summary
Common Problems
Review Questions
Practice on Analysis and Visualization
Annotated R Functions
Answers
Practice on Analysis and Visualization

Chapter 14: Dummies and Interactions

Learning Objectives
Overview
What Is a Dummy Variable?
Additive Models and Interactive Models
Bivariate Dummy Variable Regression
Multiple Regression and Dummy Variables
Interactions in Multiple Regression
Summary
Common Problems
Review Questions
Practice on Analysis and Visualization
Annotated R Functions
Answers

Chapter 15: Diagnostics I: Is Ordinary Least Squares Appropriate?

Learning Objectives
Overview
Diagnostics in Regression Analysis
Properties of Statistics and Estimators
The Gauss-Markov Assumptions
The Residual Plot
Summary
Common Problems
Review Questions
Practice on Analysis and Visualization
Annotated R Functions
Answers

Chapter 16: Diagnostics II: Residuals, Leverages, and Measures of Influence

Learning Objectives
Overview
Outliers
Leverages
Measures of Influence
Added Variable Plots
Summary
Common Problems
Review Questions
Practice on Analysis and Visualization
Annotated R Functions
Answers

Chapter 17: Logistic Regression

Learning Objectives
Overview
Questions and Problems That Require Logistic Regression
Logistic Regression Violates Gauss-Markov Assumptions
Working With Logged Odds
Working With Predicted Probabilities
Model Fit With Logistic Regression
Summary
Common Problems
Review Questions
Practice on Analysis and Visualization
Annotated R Functions
Answers

Appendix: Developing Empirical Implications

Overview
Developing Empirical Implications
Testing Additional Dependent Variables
Testing Additional Independent Variables
Using Information on Cases
Causal Mechanisms
The Rabbit Hole

Glossary

References

Index

Statistics and Data Visualization Using R (2024)
Top Articles
Latest Posts
Article information

Author: Saturnina Altenwerth DVM

Last Updated:

Views: 5846

Rating: 4.3 / 5 (64 voted)

Reviews: 95% of readers found this page helpful

Author information

Name: Saturnina Altenwerth DVM

Birthday: 1992-08-21

Address: Apt. 237 662 Haag Mills, East Verenaport, MO 57071-5493

Phone: +331850833384

Job: District Real-Estate Architect

Hobby: Skateboarding, Taxidermy, Air sports, Painting, Knife making, Letterboxing, Inline skating

Introduction: My name is Saturnina Altenwerth DVM, I am a witty, perfect, combative, beautiful, determined, fancy, determined person who loves writing and wants to share my knowledge and understanding with you.