Skip to content

Instantly share code, notes, and snippets.

@alanmarazzi
Created August 2, 2016 09:04
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save alanmarazzi/7288866b60a982c7b0d1cdd0746e74d5 to your computer and use it in GitHub Desktop.
Save alanmarazzi/7288866b60a982c7b0d1cdd0746e74d5 to your computer and use it in GitHub Desktop.
R Intro
# Read data from csv
df <- read.csv("some_data.csv")
# Make a plot of the data
plot(df$debt, df$gdp)
# Fit a linear regression
lm(gdp ~ debt, data = df)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment