1st Edition

Data Visualization and Analysis in Second Language Research




  • Available for pre-order. Item will ship after May 31, 2021
ISBN 9780367469610
May 31, 2021 Forthcoming by Routledge
232 Pages 30 B/W Illustrations

USD $44.95

Prices & shipping based on shipping country


Preview

Book Description

This introduction to visualization techniques and statistical models for second language research focuses on three types of data (continuous, binary, and scalar), helping readers to understand regression models fully and to apply them in their work. Garcia offers advanced coverage of Bayesian analysis, real and simulated data, exercises, implementable script code, and practical guidance on the latest R software packages. The book, also demonstrating the benefits to the L2 field of this type of statistical work, is a resource for graduate students and researchers in SLA, applied linguistics, and corpus linguistics who are interested in quantitative data analysis.

Table of Contents

Contents

Acknowledgments 1

Preface 3

Part I Getting ready 9

1 Introduction 11

1.1 Main objectives of this book . . . . . . . . . . . . . . . . . . . . . . . . . . . 11

1.2 A logical series of steps . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13

1.2.1 Why focus on data visualization techniques? . . . . . . . . . . . . . 14

1.2.2 Why focus on full-fledged statistical models? . . . . . . . . . . . . . 14

1.3 Statistical concepts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15

1.3.1 p-values . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16

1.3.2 Effect sizes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18

1.3.3 Confidence intervals . . . . . . . . . . . . . . . . . . . . . . . . . . . 18

1.3.4 Standard Errors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20

1.3.5 Further reading . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21

2 R basics 23

2.1 Why R? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23

2.2 Fundamentals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25

2.2.1 Installing R and RStudio . . . . . . . . . . . . . . . . . . . . . . . . 25

2.2.2 Interface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26

2.2.3 R basics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29

2.3 Data frames . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 38

iii

Contents

2.4 Reading your data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42

2.4.1 Is your data file ready? . . . . . . . . . . . . . . . . . . . . . . . . . 42

2.4.2 R Projects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43

2.4.3 Importing your data . . . . . . . . . . . . . . . . . . . . . . . . . . . 44

2.5 The tidyverse package . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 46

2.5.1 Wide-to-long transformation . . . . . . . . . . . . . . . . . . . . . . 47

2.5.2 Grouping, filtering, changing, and summarizing data . . . . . . . . . 51

2.6 Figures . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53

2.6.1 Using ggplot2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54

2.6.2 General guidelines for data visualization . . . . . . . . . . . . . . . . 58

2.7 Basic statistics in R . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61

2.7.1 What’s your research question? . . . . . . . . . . . . . . . . . . . . . 63

2.7.2 t-tests and ANOVAs in R . . . . . . . . . . . . . . . . . . . . . . . . 63

2.7.3 A post-hoc test in R . . . . . . . . . . . . . . . . . . . . . . . . . . . 66

2.8 More packages . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67

2.9 Additional readings on R . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68

2.10 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68

2.11 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 70

Part II Visualizing the data 75

3 Continuous data 77

3.1 Importing your data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 79

3.2 Preparing your data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 80

3.3 Histograms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 82

3.4 Scatter plots . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 84

3.5 Box plots . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 91

3.6 Bar plots and error bars . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 93

3.7 Line plots . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 97

3.8 Additional readings on data visualization . . . . . . . . . . . . . . . . . . . 99

3.9 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 99

3.10 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 101

4 Categorical data 103

iv

Contents

4.1 Binary data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 105

4.2 Ordinal data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 112

4.3 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 115

4.4 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 116

5 Aesthetics: optimizing your figures 119

5.1 More on aesthetics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 124

5.2 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 125

Part III Analyzing the data 127

6 Linear regression 129

6.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 131

6.2 Examples and interpretation . . . . . . . . . . . . . . . . . . . . . . . . . . . 135

6.2.1 Does Hours affect scores? . . . . . . . . . . . . . . . . . . . . . . . . 136

6.2.2 Does Feedback affect scores? . . . . . . . . . . . . . . . . . . . . . . 140

6.2.3 Do Feedback and Hours affect scores? . . . . . . . . . . . . . . . . . 144

6.2.4 Do Feedback and Hours interact? . . . . . . . . . . . . . . . . . . . . 147

6.3 Beyond the basics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 153

6.3.1 Comparing models and plotting estimates . . . . . . . . . . . . . . . 153

6.3.2 Scaling variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 157

6.4 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 162

6.5 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 163

7 Logistic regression 167

7.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 168

7.1.1 Defining the best curve in a logistic model . . . . . . . . . . . . . . . 173

7.1.2 A family of models . . . . . . . . . . . . . . . . . . . . . . . . . . . . 173

7.2 Examples and interpretation . . . . . . . . . . . . . . . . . . . . . . . . . . . 174

7.2.1 Can reaction time differentiate learners and native speakers? . . . . 175

7.2.2 Does Condition affect responses? . . . . . . . . . . . . . . . . . . . . 181

7.2.3 Do Proficiency and Condition affect responses? . . . . . . . . . . . 185

7.2.4 Do Proficiency and Condition interact? . . . . . . . . . . . . . . . 190

7.3 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 197

v

Contents

7.4 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 199

8 Ordinal regression 201

8.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 202

8.2 Examples and interpretation . . . . . . . . . . . . . . . . . . . . . . . . . . . 203

8.2.1 Does Condition affect participants’ certainty? . . . . . . . . . . . . . 203

8.2.2 Do Condition and L1 interact? . . . . . . . . . . . . . . . . . . . . . 211

8.3 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 215

8.4 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 218

9 Hierarchical models 219

9.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 219

9.2 Examples and interpretation . . . . . . . . . . . . . . . . . . . . . . . . . . . 225

9.2.1 Random-intercept model . . . . . . . . . . . . . . . . . . . . . . . . . 225

9.2.2 Random-slope and random-intercept model . . . . . . . . . . . . . . 230

9.3 Additional readings on regression models . . . . . . . . . . . . . . . . . . . . 239

9.4 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 239

9.5 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 240

10 Going Bayesian 243

10.1 Introduction to Bayesian data analysis . . . . . . . . . . . . . . . . . . . . . 245

10.1.1 Sampling from the posterior . . . . . . . . . . . . . . . . . . . . . . . 251

10.2 The RData format . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 255

10.3 Getting ready . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 256

10.4 Bayesian models: linear and logistic examples . . . . . . . . . . . . . . . . . 257

10.4.1 Bayesian model A: Feedback . . . . . . . . . . . . . . . . . . . . . . 257

10.4.2 Bayesian model B: Relative clauses with prior specifications . . . . . 265

10.5 Additional readings on Bayesian inference . . . . . . . . . . . . . . . . . . . 269

10.6 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 271

10.7 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 273

11 Final remarks 277

References 285

Appendix A Troubleshooting 287

vi

Contents

A.1 Versions of R and RStudio . . . . . . . . . . . . . . . . . . . . . . . . . . . . 287

A.2 Different packages, same function names . . . . . . . . . . . . . . . . . . . . 287

A.3 Errors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 288

A.4 Warnings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 289

A.5 Plots . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 289

Appendix B RStudio shortcuts 291

Appendix C Symbols and acronyms 293

Appendix D Files used in this book 295

Appendix E Contrast coding 299

Appendix F Models and nested data 301

Glossary 303

Subject Index 307

Function Index 309

vi

 

...
View More

Author(s)

Biography

Guilherme D. Garcia is Assistant Professor of Linguistics at Ball State University, USA.

Reviews

Highly recommended as an accessible introduction to the use of R for analysis of second language data. Readers will come away with an understanding of why and how to use statistical models and data visualization techniques in their research.

Lydia White, McGill University, Canada.

 

Curious where the field’s quantitative methods are headed? The answer is in your hands right now! Whether we knew it or not, this is the book that many of us have been waiting for. From scatter plots to standard errors and from beta values to Bayes theorem, Garcia provides us with all the tools we need—both conceptual and practical—to statistically and visually model the complexities of L2 development.

Luke Plonsky, Northern Arizona University, USA.

 

This volume is a timely and must-have addition to any quantitative SLA researcher’s data analysis arsenal, whether you are downloading R for the first time or a seasoned user ready to dive into Bayesian analysis. Guilherme Garcia’s accessible, conversational writing style and uncanny ability to provide answers to questions right as you’re about to ask them will give new users the confidence to make the move to R and will serve as an invaluable resource for students and instructors alike for years to come. 

Jennifer Cabrelli, University of Illinois at Chicago, USA.