Publications by Matt Bogard

Why does IFELSE logic work differently on what appear to be the same values?

22.02.2013

 Embarrassingly I’m stumped on this…I have a program in R for looking at grade distributions in my class. I found something weird recently with my ‘ifelse’ processing. I noticed that my program seemed to be over counting Cs and under counting Bs. I’m not sure what’s going on. It happened in the case where I was adding...

1606 sym R (1582 sym/1 pcs)

A Toy Instrumental Variable Application

19.06.2013

I have previously discussed instrumental variables (hereand here)  from a somewhat technical standpoint, but now I’d like to present a very basic example with a toy data set that demonstrates how IV estimation works in practice. The data set below is fabricated for demonstration purposes. The idea is to develop intuition about the mechanics of...

9043 sym R (1186 sym/1 pcs) 2 img

Using the R MatchIt package for propensity score analysis

28.03.2015

Descriptive analysis between treatment and control groups can reveal interesting patterns or relationships, but we cannot always take descriptive statistics at face value. Regression and matching methods allow us to make controlled comparisons to reduce selection bias in observational studies. For a couple good references that I am ba...

6627 sym R (3105 sym/1 pcs)

SAS vs R? The right answer to the wrong question?

13.06.2015

For a long time I tracked a discussion on LinkedIn that consisted of various opinions about using SAS vs R. Some people can take this very personal.  Recently there was an interesting post at the DataCamp blog addressing this topic. They also provided an interesting infographic making some comparisons between SAS and R as well as SPS...

2419 sym

Divide by 4 Rule for Marginal Effects

25.05.2016

Previously I wrote about the practical differences between marginal effects and odds ratios with regard to logistic regression. Recently, I ran across a tweet from Michael Grogan linking to one of his posts using logistic regression to model dividend probabilities. This really got me interested:“Moreover, to obtain a measure in prob...

2981 sym R (5672 sym/1 pcs)