1507 search results for "regression"

Interactive visualization of non-linear logistic regression decision boundaries with Shiny

Interactive visualization of non-linear logistic regression decision boundaries with Shiny

(skip to the shiny app) Model building is very often an iterative process that involves multiple steps of choosing an algorithm and hyperparameters, evaluating that model / cross validation, and optimizing the hyperparameters. I find a great aid in this process, for classification tasks, is not only to keep track of the accuracy across models, »more

Read more »

Example 2014.7: Simulate logistic regression with an interaction

June 24, 2014
By
Example 2014.7: Simulate logistic regression with an interaction

Reader Annisa Mike asked in a comment on an early post about power calculation for logistic regression with an interaction. This is a topic that has come up with increasing frequency in grant proposals and article submissions. We'll begin by showing how to simulate data with the interaction, and in our next post...

Read more »

Stacking Regressions: Latex Tables with R and stargazer

May 3, 2014
By
Stacking Regressions: Latex Tables with R and stargazer

In my paper on the impact of the shale oil and gas boom in the US, I run various instrumental variables specifications. For these, it is nice to stack the regression results one on the other – in particular, to have one row for the IV results, one row for the Reduced Form and maybe

Read more »

Use of freqparcoord for Regression Diagnostics

April 14, 2014
By
Use of freqparcoord for Regression Diagnostics

This is the third in my series of three posts on my package freqparcoord with Yingkang Xie. (My next post after this will show how to use R to explore one of my favorite examples of “what can go wrong” in statistics.) Here is a very brief review of my previous posts regarding freqparcoord. A

Read more »

Use of freqparcoord for Regression Diagnostics

April 14, 2014
By
Use of freqparcoord for Regression Diagnostics

This is the third in my series of three posts on my package freqparcoord with Yingkang Xie. (My next post after this will show how to use R to explore one of my favorite examples of “what can go wrong” in statistics.) Here is a very brief review of my previous posts regarding freqparcoord. A

Read more »

Regressions with Multiple Fixed Effects – Comparing Stata and R

April 5, 2014
By
Regressions with Multiple Fixed Effects – Comparing Stata and R

In my paper on the impact of the recent fracking boom on local economic outcomes, I am estimating models with multiple fixed effects. These fixed effects are useful, because they take out, e.g. industry specific heterogeneity at the county level - or state specific time shocks. The models can take the form:    where is

Read more »

MoneyPuck – Best subsets regression of NHL teams

March 17, 2014
By
MoneyPuck – Best subsets regression of NHL teams

Spring is at hand and it is a time of renewal, March Madness and to settle scores in the NHL.  There are many scores to be settled: Flyers vs. Penguins, Blackhawks vs. Red Wings, Leafs vs. Habs and pretty much everyone else vs. the Bruins.  L...

Read more »

Regression with multiple predictors

February 18, 2014
By

(This article was first published on Digithead's Lab Notebook, and kindly contributed to R-bloggers) Now that I'm ridiculously behind in the Stanford Online Statistical Learning class, I thought it would be fun to try to reproduce the figure on page 36 of the slides from chapter 3 or page 81 of the book. The result is a curvaceous surface...

Read more »

Solutions for Multicollinearity in Regression(2)

February 16, 2014
By
Solutions for Multicollinearity in Regression(2)

Continue to discuss this topic about multicollinearity in regression. Firstly, it is necessary introduce how to calculate the VIF and condition number via software such as R. Of course it is really easy for us. The vif() in car and kappa() can be applied to calculate the VIF and condition number, respectively. Consider the data from … Continue reading...

Read more »

Better living through zero-one inflated beta regression

February 6, 2014
By
Better living through zero-one inflated beta regression

Dealing with proportion data on the interval $$ is tricky. I realized this while trying to explain variation in vegetation cover. Unfortunately this is a true proportion, and can’t be made into a binary response. Further, true 0’s and 1’s rule out beta regression. You could arcsine square root transform the data (but shouldn’t; Warton and Hui 2011)....

Read more »