Git Product home page Git Product logo

r4sl's Introduction

TravisCI Build Status

r4sl

This text is currently written as a supplement to ISL for use in STAT 432, Basics of Statistical Learning at The University of Illinois at Urbana-Champaign. Some additional details and additional topics are included, but the main focus in on providing more thorough R examples. Eventually the goal is to have a completely self-contained text. However, given its massively popularity in the field, we feel that it is still extremely useful to read ISL in its entirety.

Development Status

  • April 2020 - Significant updates are expected during the Summer of 2020.
    • Re-unification of r4sl with bsl.

r4sl's People

Contributors

ak-org avatar binxiangni avatar cbonsig avatar coatless avatar daviddalpiaz avatar gburtini avatar mmahmoudian avatar ruiqili2 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

r4sl's Issues

One standard error rule details

Please could you provide details of how you get standard errors from CV in caret to implement the one standard error rule?

Fix broken KNN code

Pretty sure data in some package that is being used was switched form a data.frame to a tibble and something that used to be passed as a vector is now a tibble.....

Adding Python code

Hi David,

This is Nima, and I am almost at the end of my PhD program.

I was searching about something related to Introduction to Statistical Learning, and found your work (pdf file and then I used it to find this repo). Such a great work!

I have had a similar idea about this book. My idea was to create an interactive environment so that reader can play around the code and try "what if" questions they have in mind. I recently uploaded three of my notebooks here: blog (it might seem a little bit messy and I may go through it later to refine it)

I am using python and I know it is usually harder to get some statistics (e.g. I think regression in scikit-learn does not provide p-value or at least I couldn't find an easy way for it there, so I had to use statsmodels library. ). My goal is to provide python-code not just for lab/exercise, but for examples of the book and try to reproduce them. I also provided some links to stackoverflow /youtube videos/ ... when I felt reader might get benefit by getting into some details (e.g. I added a link that explains why we need to z-normalize before PCA).

I was wondering if you have any feedback/suggestion about my work. Also, do you think readers of your book will benefit from my notebooks? Because, to be honest, the format you used for writing the book is very nice and clean. And, it would be really great if I could use your insight on cleaning my notebooks and (if you are interested) adding it to the book. For example, maybe just provide a hyperlink that takes reader to a notebook and they can just play with the code. (or maybe try it on their own and then click on it to see the difference and ....)

Please let me know what you think. Sorry for the long post as I got super excited when I found about this repo :)

Typo 'glment'

It's in chapter 25. It should be glmnet.

Also, is this Git actively updated?

External References

Gather external references that are usually posted on course website at end of chapters. Also consider ISL and mathematicalmonk videos.

Tables

Change all tables to knitr::kable().

Cache code chunks

As you continue to add on code that is computationally intensive, you will need to start caching the code chunk results. This in turn means you should start labeling your code chunks (otherwise, they're treated like cattle). Otherwise, we'll have to move you to pushing a rendered product via a netlify setup.

caret model$results outputs SD not se, right?

Here you take RMSESD from the results attribute of a train (model) object and then refer to this as se and standard error in the text. However, SD is commonly refers to standard deviation. I think something has to be done to calculate standard error from standard deviation. Or is the output of caret misleading?

Another view of Sim Bias Variance Tradeoff

First, I really like the Bias Variance Tradeoff Simulation Section!! Thank you very much for making such a great book.

One suggestion from me.

Figure 1 is not very intuitive for me, it shows too many information.
image

Alternatively I think this visualization may be better, which only shows the prediction for the x=0.95 cross different model. From 4 sub plots we can clean see, bias and variance.

image

Here is the code.

  par(mfrow=c(1,4))
  plot(rep(0.95,n_sims),predictions[,1],col="red", xlim = c(0.75, 1), ylim = c(0, 1.5))
  points(x0, f(x0), col = "black", pch = "x", cex = 2)
  plot(rep(0.95,n_sims),predictions[,2],col="blue", xlim = c(0.75, 1), ylim = c(0, 1.5))
  points(x0, f(x0), col = "black", pch = "x", cex = 2)
  plot(rep(0.95,n_sims),predictions[,3],col="green", xlim = c(0.75, 1), ylim = c(0, 1.5))
  points(x0, f(x0), col = "black", pch = "x", cex = 2)
  plot(rep(0.95,n_sims),predictions[,4],col="orange", xlim = c(0.75, 1), ylim = c(0, 1.5))
  points(x0, f(x0), col = "black", pch = "x", cex = 2)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.