Skip to content

Commit

Permalink
Clarifying a question. Will add test for variable "fit" creation late…
Browse files Browse the repository at this point in the history
…r when I have time to test.
  • Loading branch information
WilCrofter committed Sep 11, 2014
1 parent 0d3d0a6 commit 654df26
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@
Output: "The remaining function, eliminate, applies regressOneOnOne to all variables except a given predictor and collects the residuals in a data frame. We'll first show that when we eliminate one regressor from the data, a regression on the remaining will produce their correct coefficients. (Of course, the coefficient of the eliminated regressor will be missing, but more about that later.)"

- Class: cmd_question
Output: "For reference, create a model based on all three regressors, Girth, Height, and Constant, and assign the result to a variable named fit. Use an expression such as fit <- lm(Volume ~ Girth + Height + Constant -1, trees). Don't forget the -1."
Output: "For reference, create a model named fit, based on all three regressors, Girth, Height, and Constant, and assign the result to a variable named fit. Use an expression such as fit <- lm(Volume ~ Girth + Height + Constant -1, trees). Don't forget the -1, and be sure to name the model fit for later use."
CorrectAnswer: fit <- lm(Volume ~ . - 1, trees)
AnswerTests: creates_lm_model('fit <- lm(Volume ~ . - 1, trees)')
Hint: "Enter an expression such as fit <- lm(Volume ~ Girth + Height + Constant - 1, trees), or fit <- lm(Volume ~ . -1, trees) at the R prompt."
Expand Down

0 comments on commit 654df26

Please sign in to comment.