set.seed(10) x <- rnorm(n = 1000, mean = 10, sd = 10) my_group <- cut(x, breaks = c(-Inf, 15, Inf)) # solution my_sol <- table(my_group)[1]
my_answers <- make_random_answers(my_sol) #check_answers(my_answers)
Using set.seed (10)
, create an object called x
with random values from the Normal distribution with a mean of 10 and standard deviation of 10. Using the cut
function, create another object that defines two groups based on values of x
greater than 15 and lower than 15. How many observations you find in the first group?
exams::answerlist(my_answers, markup = "markdown")
extype: num
exsolution: r my_sol
exname: "numeric "
exshuffle: TRUE
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.