Monthly Archives: March 2011

In case you missed it: January Roundup

March 8, 2011
By

Catching up on roundups today. February roundup will follow soon, but in the meantime enjoy this trip down memory lane - DS. In case you missed them, here are some articles from January of particular interest to R users. Revolution Analytics is now offering annual sponsorship grants for local R user groups worldwide. Issue 2 of the R Journal...

Read more »

Video Tutorial on Instrumental Variables in R

March 8, 2011
By
Video Tutorial on Instrumental Variables in R

Update: I have replaced this video tutorial with a video tutorial on a newer, easier to use IV regression command. Check out that command here.In this video, I show how to use my instrumental variables function in R, ivreg(), along with its companion ...

Read more »

IV Regression

March 8, 2011
By
IV Regression

Here is my code from a previous post that performs IV regression. This may be easier to copy into an R script. I will post a video tutorial using this code shortly.

Read more »

Machine Learning Ex3 – multivariate linear regression

March 8, 2011
By
Machine Learning Ex3 – multivariate linear regression

Exercise 3 is about multivariate linear regression. First part is about finding a good learning rate (alpha) and 2nd part is about implementing linear regression using normal equations instead of the gradient descent algorithm. Data As usual hosted in google docs: mydata = read.csv("http://spreadsheets.google.com/pub?key=0AnypY27pPCJydExfUzdtVXZuUWphM19vdVBidnFFSWc&output=csv", header = TRUE) # show last 5 rows tail(mydata, 5) area bedrooms price 43 2567 ...

Read more »

An enhanced Kaplan-Meier plot

March 8, 2011
By
An enhanced Kaplan-Meier plot

We often see, in publications, a Kaplan-Meier survival plot, with a table of the number of subjects at risk at different time points aligned below the figure. I needed this type of plot (or really, matrices of such plots) for an upcoming publication. Of course, my preferred toolbox was R and the ggplot2 package. There

Read more »

Our Friend the Age-Earnings Profile

March 7, 2011
By
Our Friend the Age-Earnings Profile

I like Labor Economics. Partially because it has a nice mix of theory and practical empiricism, but mostly because it seems to be a sub-field with a number of agreed upon stylized facts that grow not out of micro theory … Continue reading →

Read more »

Initial SoilWeb Concept on Paper

March 7, 2011
By
Initial SoilWeb Concept on Paper

read more

Read more »

money is coin $ flip

March 7, 2011
By
money is coin $ flip

Well, sorta. More precisely, money is the sum of coin$flip divided by the number of coin$flip. But we'll get to that later. For now, let me introduce you to a new algorithm written in R. This one is another "quote" -- simple few lines of code -- whose ...

Read more »

Alabama is a foreign country

March 7, 2011
By
Alabama is a foreign country

Faculty and students of Iowa State University Department of Statistics published online an analysis of the data on 2009 distributions of the US Stimulus funds, aka the Recovery And Reinvestment Act. (The analysis was published in March last year as part of the Design for America competition, but I only recently came across it.) The analyses and associated charts...

Read more »

Basic Plots in R

March 7, 2011
By
Basic Plots in R

Here's a tutorial I recorded on producing basic plots in R.I lost the script file I used to create the video to a horrifying black screen of death, but I used the data from the previous post (available here). Hopefully, the video is clear enough that ...

Read more »