Book Image

Clojure for Data Science

By : Henry Garner
Book Image

Clojure for Data Science

By: Henry Garner

Overview of this book

Table of Contents (18 chapters)
Clojure for Data Science
Credits
About the Author
Acknowledgments
About the Reviewer
www.PacktPub.com
Preface
Index

Regression


While it may be useful to know that two variables are correlated, we can't use this information alone to predict the weights of Olympic swimmers given their height or vice versa. In establishing a correlation, we have measured the strength and sign of a relationship, but not the slope. Knowing the expected rate of change for one variable given a unit change in the other is required in order to make predictions.

What we'd like to determine is an equation that relates the specific value of one variable, called the independent variable, to the expected value of the other, the dependent variable. For example, if our linear equation predicts the weight given the height, then the height is our independent variable and the weight is our dependent variable.

Note

The lines described by these equations are called regression lines. The term was introduced by the 19th century British polymath Sir Francis Galton. He and his student Karl Pearson (who defined the correlation coefficient) developed...