Skip to content

Instantly share code, notes, and snippets.

@marutter
Created October 30, 2010 18:10
Show Gist options
  • Select an option

  • Save marutter/655587 to your computer and use it in GitHub Desktop.

Select an option

Save marutter/655587 to your computer and use it in GitHub Desktop.
Hints for Homework 9
#
# To add better variable names to data read in from a text file
# The names are assigned in numerical order
#
data <- read.table("CH06PR18.txt")
names(data) <- c("rental.rate","age","exp.tax","vacancy","sq.foot")
#
# To drop the 13 and 73 observation from a regression
#
res <- lm(Y~X1+X2+X3,subset=-c(13,73))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment