Skip to content

Commit

Permalink
small fix on first dplyr lesson
Browse files Browse the repository at this point in the history
  • Loading branch information
ncarchedi committed Aug 22, 2014
1 parent 6cb9227 commit 8f25dd4
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@
Hint: See what -5:20 gives us.

- Class: cmd_question
Output: Oops! That gaves us a vector of numbers from -5 through 20, which is not what we want. Instead, we want to negate the entire sequence of numbers from 5 through 20, so that we get -5, -6, -7, ... , -18, -19, -20. Try the same thing, except surround 5:10 with parentheses so that R knows we want it to first come up with the sequence of numbers, then apply the negative sign to the whole thing.
Output: Oops! That gaves us a vector of numbers from -5 through 20, which is not what we want. Instead, we want to negate the entire sequence of numbers from 5 through 20, so that we get -5, -6, -7, ... , -18, -19, -20. Try the same thing, except surround 5:20 with parentheses so that R knows we want it to first come up with the sequence of numbers, then apply the negative sign to the whole thing.
CorrectAnswer: -(5:20)
AnswerTests: omnitest(correctExpr='-(5:20)')
Hint: -(5:20) will do the job.
Expand Down

0 comments on commit 8f25dd4

Please sign in to comment.