#if (!require(cranlogs)) install.packages('cranlogs') pkgs <- cranlogs::cran_top_downloads(when = 'last-month') my_sol <- pkgs$package[1]
my_answers <- make_random_answers(my_sol, unique(pkgs$package)) check_answers(my_answers)
The cranlogs
package allows access to downloads statistics of CRAN packages. After installing cranlogs
on your computer, use the cranlogs::cran_top_downloads
function to check which are the 10 most installed packages by the global community in the last month. Which package comes first? Tip: Set the cran_top_downloads
function input to when = 'last-month'
. Also, be aware that the answer here may not be the same as you got because it depends on the day the R code was executed.
exams::answerlist(my_answers, markup = "markdown")
extype: schoice
exsolution: r mchoice2string(c(TRUE, FALSE, FALSE, FALSE, FALSE), single = TRUE)
exname: "install pkgs 03"
exshuffle: TRUE
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.