Hands-On Data Science with R
by Doug Ortiz, Vitor Bianchi Lanzetta, Nataraj Dasgupta, Ricardo Anjoleto Farias
Linear regression with R
Linear regressions are traditional statistical models. Regressions are meant to understand how two or more variables are related and/or to make predictions. Taking limitations into account, regressions may answer questions such as: How does the National Product respond to government expenditure in the short run? or What should be the expected revenue for next year?
Of course, there are drawbacks. An obvious one is that linear regression is only meant to grasp linear relations. Plotting variables ahead may give you hints on linearity—sometimes, you can turn things around with data transformation. Note that a relation does not necessarily imply causation.
A strong relation (correlation) could also result from coincidence ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access