Summary Data Mining Model Selection and Regularization
5 views 0 purchase
Course
Data Mining
Institution
Universiteit Gent (UGent)
This document contains a summary of the theory seen in the lab sessions. In addition, the document contains the solutions to the exercises of the lab sessions.
Model selection and regularization
is.na(): identifies missing observations(TRUE = missing, FALSE = non-missing, sum() = counts all
missing elements)
Salary is missing for 59 players
na.omit(): removes all rows that have missing values in any variable
regsubsets(): performs best subset selection (by identifying the best model that contains a given
number of predictors, where best is quantified using RSS) (syntax is same as for lm())
, summary(): outputs best set of variables for each model size
*: variable included in corresponding model( here: best two-variable model contains only Hits and
CRBI)
regsubsets(): by default, reports only the best eight-variable model
nvmax: returns as many variables as are desired
reg.summary(): returns R2, RSS, adjusted R2, Cp and BIC
R2 increases from 32% ( = 1 variable) to almost 55% ( = all variables)
Type= “1” : connect plotted points with lines
points(): like plot(), except it puts points on a plot that has already been created, instead of creating a
new plot
which.max(): identify location of the maximum point of a vector
Red dot = model
with largest
adjusted R2
statistic
The benefits of buying summaries with Stuvia:
Guaranteed quality through customer reviews
Stuvia customers have reviewed more than 700,000 summaries. This how you know that you are buying the best documents.
Quick and easy check-out
You can quickly pay through credit card or Stuvia-credit for the summaries. There is no membership needed.
Focus on what matters
Your fellow students write the study notes themselves, which is why the documents are always reliable and up-to-date. This ensures you quickly get to the core!
Frequently asked questions
What do I get when I buy this document?
You get a PDF, available immediately after your purchase. The purchased document is accessible anytime, anywhere and indefinitely through your profile.
Satisfaction guarantee: how does it work?
Our satisfaction guarantee ensures that you always find a study document that suits you well. You fill out a form, and our customer service team takes care of the rest.
Who am I buying these notes from?
Stuvia is a marketplace, so you are not buying this document from us, but from seller Worstje2021. Stuvia facilitates payment to the seller.
Will I be stuck with a subscription?
No, you only buy these notes for $3.57. You're not tied to anything after your purchase.