Giter Site home page Giter Site logo

rstudio / learnr Goto Github PK

View Code? Open in Web Editor NEW
704.0 34.0 236.0 22.63 MB

Interactive Tutorials with R Markdown

Home Page: https://pkgs.rstudio.com/learnr

License: Apache License 2.0

R 77.85% CSS 2.15% JavaScript 18.66% HTML 1.27% Python 0.07%
interactive python r r-package rmarkdown rstats shiny teaching tutorial sql

learnr's Introduction

learnr

R build status CRAN status learnr downloads per month DOI
GitHub Discussions RStudio community RStudio community

The learnr package makes it easy to turn any R Markdown document into an interactive tutorial. Tutorials consist of content along with interactive components for checking and reinforcing understanding. Tutorials can include any or all of the following:

  1. Narrative, figures, illustrations, and equations.

  2. Code exercises (R code chunks that users can edit and execute directly).

  3. Quiz questions.

  4. Videos (supported services include YouTube and Vimeo).

  5. Interactive Shiny components.

Tutorials automatically preserve work done within them, so if a user works on a few exercises or questions and returns to the tutorial later they can pick up right where they left off.

Learn more about the learnr package and try example tutorials online at https://rstudio.github.io/learnr/.

Installation

Install the latest official learnr release from CRAN:

install.packages("learnr")

Or you can install the most recent version in-development from GitHub with the remotes package:

# install.packages("remotes")
remotes::install_github("rstudio/learnr")

learnr works best with a recent version of RStudio (v1.0.136 or later) which includes tools for easily running and previewing tutorials.

learnr's People

Contributors

adamblake avatar andrie avatar angela-li avatar bborgesr avatar beatrizmilz avatar braunsb avatar cpsievert avatar gadenbuie avatar garrettgman avatar gvwilson avatar helix84 avatar indenkun avatar isteves avatar jcheng5 avatar jjallaire avatar jtransue avatar kevinushey avatar mikelmadina avatar mine-cetinkaya-rundel avatar nischalshrestha avatar olivroy avatar robbyshaver avatar rossellhayes avatar schloerke avatar shalom-lab avatar stragu avatar trestletech avatar wch avatar yabellini avatar yihui avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

learnr's Issues

Method to turn progressive reveal off for individual sub-sections

It would be useful to have a way to turn progressive reveal off for individual sub-sections, e.g.

### A not-hidden sub-section {data-progressive = FALSE}

In this case, the sub-section would appear when the previous sub-section appears (which might itself be triggered by a progressive reveal).

Puzzling C stack usage error

I'm getting a puzzling C stack usage error when I combine an exercise that calls nycflights13::flights with an html formatted exercise hint. As in the document below.

---
title: "Data basics - Error"
output: tutor::tutorial
runtime: shiny_prerendered
---

```{r setup, include=FALSE}
library(tutor)
library(tidyverse)
library(nycflights13)
```
 
```{r flights2, exercise = TRUE, exercise.eval = TRUE}
flights
``` 

<div id="flights2-hint">
**Hint:** Type the name of the data frame that you want to print and then click the blue button. I've already loaded the nycflight13 package for you.
</div>

screen shot 2017-03-06 at 4 37 35 pm

If I remove the hint, or transform it into a knitr hint (like below), the error disappears.

---
title: "Data basics"
output: tutor::tutorial
runtime: shiny_prerendered
---

```{r setup, include=FALSE}
library(tutor)
library(tidyverse)
library(nycflights13)
```
 
```{r flights2, exercise = TRUE, exercise.eval = TRUE}
flights
``` 

```{r flights2-hint}
"**Hint:** Type the name of the data frame that you want to print and then click the blue button. I've already loaded the nycflight13 package for you."
```

This is a minimal example trimmed down from a real tutorial where the hint applied to a different exercise (not the one that calls nycflights13::flights).

The exercises above always return the C stack usage error -- even without a hint -- if you remove the library(tidyverse) call (in which case flights does not print as a concise tibble, but as a very large data set).

HTML formatted hints seem to work generally, I've only received this error in combination with flights, which is an example data set used throughout R for Data Science and the tutorials.

Progressive reveal does not yet function as an educational aid.

E-learning/Multimedia Learning theory suggests that progressive reveal will enhance student learning when it:

  1. divides large segments of information into digestible chunks
  2. gives students time to reflect on what they've learned before moving on
  3. places the student in control of when to move on
  4. guides student attention to the small chunk of information that they should focus on
  5. (implied: not distract or confuse the student)

I think we need to make several changes to meet these goals (all but one mentioned in other issues):

  1. Have reveal occur at every third level header as well as after every exercise (not yet implemented). This is because each exercise/feedback combination forms an important chunk of information that requires the student to reflect and conserve attention.

  2. Add explicit "Go On" buttons everywhere a hidden section occurs #26, #25. This makes it obvious that a progressive reveal system exists and it provides an effortless way for the student to use it.

  3. Have new sections fade or dissolve in to attract the student's attention. Instant change disorients, moderate change attracts attention, very slow change becomes subliminal. #27

Back button

I think a Back button to the left of the Continue button would be useful. Currently there are two ways to go back:

  • Click on the previous lesson/chapter on the table of contents on the side -- This requires knowing where you are, which I realize is obvious from the title of the current page, but still potentially a two-step process for students.
  • Scroll up -- This wasn't as obvious to me initially.

In going through the tutorials I felt like this would be a useful functionality to have when a student thinks "wait, what did I just do?".

Incompatibilities with shinyapps.io and/or rsconnect

The tutorial below can be deployed successfully to shinyapps.io from the RStudio IDE. But two small changes break the process (scroll down):

---
title: "Data Visualization Basics"
output: tutor::tutorial
runtime: shiny_prerendered
---

```{r setup, include=FALSE}
library(tutor)
library(ggplot2)
checker <- function(label, user_code, check_code, envir_result, evaluate_result, ...) {
  list(message = check_code, correct = TRUE, location = "append")
}
tutor_options(exercise.timelimit = 60, exercise.checker = checker)
```

## Aesthetic mappings

```{r aesthetics, exercise = TRUE, exercise.eval = FALSE}
ggplot(data = mpg) + 
  geom_point(mapping = aes(x = displ, y = hwy))
```

```{r aesthetics-check}
"Great Job! You can now tell which class of car each point represents by examining the color of the point."
```

screen shot 2017-03-03 at 4 39 42 pm

  1. The tutorial goes grey as soon as it is opened on shinyapps.io if it does not include an R Markdown header, e.g.
---
title: "Data Visualization Basics"
output: tutor::tutorial
runtime: shiny_prerendered
---

```{r setup, include=FALSE}
library(tutor)
library(ggplot2)
checker <- function(label, user_code, check_code, envir_result, evaluate_result, ...) {
  list(message = check_code, correct = TRUE, location = "append")
}
tutor_options(exercise.timelimit = 60, exercise.checker = checker)
```

Aesthetic mappings (no heading)

```{r aesthetics, exercise = TRUE, exercise.eval = FALSE}
ggplot(data = mpg) + 
  geom_point(mapping = aes(x = displ, y = hwy))
```

```{r aesthetics-check}
"Great Job! You can now tell which class of car each point represents by examining the color of the point."
```

screen shot 2017-03-03 at 4 39 53 pm

  1. The tutor fails to deploy if an exercise includes example code with "fill in the blank" sections, like this (which we should expect):
---
title: "Data Visualization Basics"
output: tutor::tutorial
runtime: shiny_prerendered
---

```{r setup, include=FALSE}
library(tutor)
library(ggplot2)
checker <- function(label, user_code, check_code, envir_result, evaluate_result, ...) {
  list(message = check_code, correct = TRUE, location = "append")
}
tutor_options(exercise.timelimit = 60, exercise.checker = checker)
```

## Aesthetic mappings

```{r aesthetics, exercise = TRUE, exercise.eval = FALSE}
ggplot(data = mpg) + 
  geom_point(mapping = aes(x = displ, y = hwy, _________))
```

```{r aesthetics-check}
"Great Job! You can now tell which class of car each point represents by examining the color of the point."
```

screen shot 2017-03-03 at 4 42 56 pm

Note: all of these examples work fine locally.

R CMD check warnings on use of completion utilities

We get the following warnings related to use of the private utils completion functions:

Status: 1 WARNING, 1 NOTE
checking dependencies in R code ... WARNING
Unexported objects imported by ':::' calls:
  ‘utils:::.assignEnd’ ‘utils:::.assignLinebuffer’
  ‘utils:::.completeToken’ ‘utils:::.guessTokenFromLine’
  ‘utils:::.retrieveCompletions’
  See the note in ?`:::` about the use of this operator.
  Including base/recommended package(s):
  ‘utils’

Seems like we need to either:

a) Find a way to call these without associated warnings;

b) Clone the code from base R (we'd then also need to change our license to GPL, which I'd be fine with); or

c) Write our own clean room versions of the functions.

Feature request: pre-checking of code

The student's submitted code is evaluated before handing it off to the checker function. This makes sense, but when the evaluation fails, the student gets feedback from R rather than from the checking code.

Might it be arranged to send the code to a pre-evaluation checking chunk. Then the checking system can have at it before R. Feedback messages would be returned in the usual way. Only if the feedback is passing, should the code be evaluated. Then the evaluated code can be sent again to the checking system. Since the checking system knows specifically what the code should look like, it can perhaps identify problems that don't produce helpful errors from R.

promote a set of example tutorials within the documentation

I'd like to promote a set of 4-6 example tutorials within the documentation (really just a link to the running tutorial and it's source code). @garrettgman Could you let me know which tutorials you think would be the best examples and provide links to them / their source code? Once you do this I'll add an "Examples" tab to the documentation website.

Wrong event-recorder entry for questions when random order is TRUE.

For multiple-choice questions, the data argument passed to the function assigned to tutor.event_recorder can have the wrong value in the answers: field when random_answer_order = TRUE. Instead of giving the answer text that corresponds to the selected option in the HTML display, the text is pulled out from the original order given in the question() function that set up the possible answers. In other words, randomization is done correctly so far as the display and the evaluation of correctness, but the event recorder doesn't seem to know about the randomization.

ensure that docs on progressive reveal and skipping reflect latest behavior

@garrettgman I know that you and @robbyshaver iterated on the behavior of progressive display and skipping quite a bit after I wrote these initial docs:

https://rstudio.github.io/tutor/formats.html#progressive_reveal

Could you make any revisions to these documents which you believe are required? (Note that there is a separate 'docs' RStudio project within the docs subdirectory of the repo which you can use to edit/rebuild the docs website.

Fade in for progressive reveal

Can new section dissolve (quickly) into view instead of appearing all at once? This would:

  1. Better draw the student's attention to the new section
  2. Reduce the disorientation of a section appearing when the student may not expect it

(This last point may be due to the connection between exercise completion and reveals: the student submits their code, which primes them to see a piece of feedback. Then, an entire new section appears, burying the feedback. #25, #26)

Exercise blocks for teaching R Markdown and Shiny

If possible, I would like to create tutorials that teach students how to use R Markdown. To do this interactively, I would need a second type of interactive exercise block: a block whose content is assumed to be an R Markdown document and whose display comes with a "Knit Document" button.

Is it technically feasible to create such a block?
Is it desirable to do so given the complications that R Markdown will introduce to security, grading, and execution?

The obvious follow up would be a third type of exercise block for teaching Shiny: a block whose content is assumed to be an app.R file and whose display comes with a "Run App" button.

refine appearance of javascript alert/confirm dialogs

I am now using bootbox for JavaScript alerts which works very nicely, however I think we need some CSS refinements to make it look/act the way we want to:

  1. The side menu ends up drawing way too much attention to itself when rendered with the modal overlay.

  2. The z-order on the bootbox alert isn't right.

See screenshot here:

screen shot 2017-03-17 at 8 25 30 am

File names can't start with non-alpha

A tutor Rmd file whose name begins with a non-alphabetic character, e.g. 05-collection.Rmd, will run only if there are no graphics chunks in the document. This behavior is inherited from shiny::add_resource_path. Files without graphics chunks work find, even with names starting with a numeral.

The obvious quick fix is not to start tutor Rmd file names with a non-alphabetic character. (This is a moral conflict with the naming style encouraged by bookdown, but not a technical conflict.) Still, the start-with-alphabetical-character-if-graphics-chunk is perhaps unnecessarily obscure.

Feature request: Hints with markdown formatting

Might there be a markdown = TRUE chunk option added so that hints will be displayed in formatted text rather than in monospace? Often, I would like to give a hint that is narrative, rather than code based.

Markdown hints spawn multiple instantiations of hint div on repeated button click

When using the <div> setup to create hints, pressing on the hint button multiple times generates an equal amount of "Hint" divs for the given problem. The only way to hide the hints is to reset the state of the document.

Seems as if the child element is not being detected here.

Example:

---
title: "Tutorial"
output: tutor::tutorial
runtime: shiny_prerendered
---

```{r setup, include=FALSE}
library(tutor)
knitr::opts_chunk$set(echo = FALSE)
```

## Exercise 1

Write the R code required to add two plus two:

```{r two-plus-two, exercise=TRUE}

```

<div id="two-plus-two-hint">
**Hint:** You may wish to review the difference between `Integer` and `Numeric`
types.
</div>

multiple_hint_spawns

Next tutorial button?

JJ,

Is it possible to include an easy way to insert a centered bootstrap button at the bottom of the tutorial that the developer could link to another tutorial (e.g. the next tutorial)? Something like:

```{r echo = FALSE, results = 'asis'}
  button(label = "Next Lesson", link = "/tutorial2.html")
```

TOC does not appear for sections that occur before the first exercise

The table of contents does not appear for a tutorial until you navigate to the first section that has an exercise. You can see the effect in the demo document below:

---
title: "Demo Tutorial"
output: tutor::tutorial
runtime: shiny_prerendered
---

```{r setup, include=FALSE}
library(tutor)
```

## Welcome

This is the Welcome section

## First task

This is the First Task section

## Second Task

This is the Second Task section

```{r one, exercise = TRUE}

```

It prints like this the first time through:

screen shot 2017-03-03 at 2 20 20 pm

screen shot 2017-03-03 at 2 20 23 pm

screen shot 2017-03-03 at 2 20 25 pm

Improve padding when topic index scrolls

I think we need a bit more left padding for the body. I also think it would be nice if the scroll-bar had better extension all the way to the top (it's not the end of the world, but the scrollbar ending short of the top creates a border effect which is odd because there is no other visual signs of a border).

screen shot 2017-03-01 at 3 40 27 pm

@robbyshaver

The second section in a document without an exercise cannot be skipped

The issue is that the method for communicating "skip" from tutorial-format.js to the tutor code uses the data-label attribute of the exercise. If there is no exercise, the label is "undefined", which works for the first exercise-less section, but fails on the second. Hmmm ....

Sample code:

---
title: "Two exercise-less sections"
output: 
  tutor::tutorial:
    progressive: true
    allow_skip: true
runtime: shiny_prerendered
---

```{r setup, include=FALSE}
library(tutor)
```

## Welcome

### Section 1

This section can be skipped.

### Section 2

But not this one

### Section 3

Sad! Write the R code required to add two plus two:

```{r two-plus-two, exercise=TRUE}

```

Tutorial with no exercises produces an error in the console

Here's the error:

Listening on http://127.0.0.1:5671
Warning: Error in shinysession$handleRequest: attempt to apply non-function
Stack trace (innermost first):
3:
2: do.call
1: rmarkdown::run
Error : attempt to apply non-function

Here's the RMD:

---
title: "Demo Tutorial"
output: 
  tutor::tutorial:
    progressive: false
    allow_skip: false
runtime: shiny_prerendered
---

```{r setup, include=FALSE}
library(tutor)
```

## Welcome

### Visible sub-section

This sub-section is visible.

Progressive reveal does not provide a cue that a hidden section follows.

When progressive reveal is on, there is no indication to the reader that a tutorial contains hidden sections to unlock. For example, there is a hidden section waiting to be revealed here (code below):

screen shot 2017-03-03 at 2 48 17 pm

A user can miss the hidden sub-section by using the TOC to navigate past them. Related to #25 because a user will always miss sub-sections if the current sub-section does not contain an exercise (the method for revealing sub-sections). They will also miss hidden sections when they choose not to do an exercise.

Both issues can be resolved by separating progressive reveal from exercise completion and tying it to a "Go On" button that appears whenever a hidden section follows.

---
title: "Demo Tutorial"
output: 
  tutor::tutorial:
    progressive: true
runtime: shiny_prerendered
---

```{r setup, include=FALSE}
library(tutor)
checker <- function(label, user_code, check_code, envir_result, evaluate_result, ...) {
  list(message = "Good Job!", correct = TRUE, location = "append")
}
tutor_options(exercise.checker = checker)
```

## Welcome

### Visible sub-section

This sub-section is visible. It contains a boring exercise that you choose not to do. Notice that there is no "Next Topic" button.

```{r one, exercise = TRUE}

```

```{r one-check}
"foo"
```

### Hidden sub-section

This sub-section is hidden. You do not know that it exists.

## Second Task

Once "finished" above, you can navigate here with the TOC.

Obtaining assessment data (pass/fail/trials)

Glancing over the documentation, the event recorders only supply data presently for submission, error, or hint. Is there any way to obtain more granularity on this such that the outcome of the submission could be discriminate as being either correct or incorrect?

If so, then potentially the responses could be aggregated in a database and used to effectively assess students under a Shiny Pro Server setup assuming login was required. In essence, this has the potential to be the nbgrader feature of the Jupyter notebooks but for R.

Use Next Topic button as the Continue button for the last sub-section in a topic.

When progressive reveal is set to true, the last sub-section of a topic ends up with a continue button that when pressed reveals a Next Topic button (demo's below). Can we combine the two buttons for the last sub-section in a topic?

---
title: "Continue to the Next Topic button"
output: 
  tutor::tutorial:
    progressive: true
runtime: shiny_prerendered
---

```{r setup, include=FALSE}
library(tutor)
```

## Topic 1

### Sub-section 1

A sub-section.

### Sub-section 2

A second sub-section

### Sub section 3

A third sub-section. Click through two buttons to advance.

## Topic 2

```{r foo, exercise = TRUE}

```

Improve formatting for help pages?

Is it possible to improve how the content of help pages is formatted when a student uses an exercise to open a help page? Students will open help pages often, since these are learning documents.

The current formatting is odd, but legible (so feel free to close the issue immediately). Two adjustments would make a big difference:

  1. Disable text wrap
  2. Display titles in header case (vs _t_h_i_s _c_a_s_e)

To quickly see how the help pages display, just add a ?plot chunk to a tutorial:

---
title: "Help pages display awkwardly"
output: tutor::tutorial
runtime: shiny_prerendered
---

```{r setup, include=FALSE}
library(tutor)
```

```{r help, exercise = TRUE}
?plot
```

screen shot 2017-02-21 at 11 08 08 am

Record and restore the user's current topic

We currently remember and restore the progress a user has made through a tutorial, but we don't record & restore which topic you were last on. It makes picking up where you left off a bit difficult if close and re-open a tutorial.

Start Over confirmation dialog

Start Over uses a window.confirm dialog box. Could we do this with a JavaScript modal dialog instead? It'd be great if we could give it consistent styling and control the text a bit more. Additionally, if you click "Prevent this page from creating additional dialogs", the Start Over functionality no longer works (not surprising, but not exactly what we want, either).

Bumping against C stack limit?

I get this error:

Output created: 03-data-manip-basics.html
Error: C stack usage  8678916 is too close to the limit
Execution halted

when I try to run the tutorial below

---
title: "Data Manipulation Basics"
output: tutor::tutorial
runtime: shiny_prerendered
---

```{r setup, include=FALSE}
library(tidyverse)
library(nycflights13)
```

what's going on?

```{r}
flights
```

I'm not sure what is happening, but I can avoid the error it in two ways. If I do either of these things, the tutorial runs without error:

  1. (sensibly) show only the head of flights (but notice that flights is a tibble, so it displays concisely anyhow)

     ---
     title: "Data Manipulation Basics"
     output: tutor::tutorial
     runtime: shiny_prerendered
     ---
     
     ```{r setup, include=FALSE}
     library(tidyverse)
     library(nycflights13)
     ```
     
     what's going on?
    
     ```{r}
     head(flights)
     ```
    
  2. Remove the ' in the line before the last code chunk:

     ---
     title: "Data Manipulation Basics"
     output: tutor::tutorial
     runtime: shiny_prerendered
     ---
     
     ```{r setup, include=FALSE}
     library(tidyverse)
     library(nycflights13)
     ```
    
     whats going on?
    
     ```{r}
     flights
     ```
    

Do not reveal next section on exercise completion

Garrett suggests that students should always have to press the skip/go on button to reveal the next exercise.

Questions:

  • Would we make this an option? i.e. Are there cases where the current behavior of revealing the next exercise on completion is preferable?
  • If skip is not enabled, would the button only appear (or be enabled) once the exercise is completed? Yes.

Allow students to download a copy of the .Rmd with answers filled in

Perhaps I'm overthinking this, but would it be possible to have the students retain a copy of their work (outside of the saved session) via a .Rmd file that mimcs the form?

The closest I can think is to have them just print the form page. But, I would like them to be able to interact with it at a later time.

Skip section instead of (or in addition to) skip exercise

The current tutor api includes a method: skipExercise() and fires an event: progressEvent.event === "exercise_skipped". However, the UI actually allows the user to skip sections, not exercises.

The code in tutorial-format.js works around this, but it's kind of a hack. It passes in the id of a section to skipExercise, and in the handler for the "exercise_skipped" event, fishes the id from the empty jquery object like so:

function exerciseSkipped(exerciseElement) {
var sectionSkippedLabel;
if (exerciseElement.length) {
console.log('something changed in tutor ...');
return;
// sectionSkippedLabel = exerciseElement.attr('data-label');
}
else { // fish out the id of the section that got skipped
sectionSkippedLabel = $(exerciseElement).selector.split('"')[1];
}

It would be much cleaner if we had a skipSection method and a "section_skipped" event to work with - particularly if somebody looks at tutorial-format.js and tries to figure out what's going on.

R CMD check warning on use of attach

We are currently getting this warning in R CMD check:

Found the following calls to attach():
File ‘tutor/R/http-handlers.R’:
  attach(state[[label]], name = "tutor:state")
See section ‘Good practice’ in ‘?attach’.

allow-skip and progressive attributes need to have data prefix

We want our HTML to be valid HTML5 so as a result we preface attributes with data-. Here are the two cases where we are using attributes without the prefix (progressive and allow-skip):

https://github.com/rstudio/tutor/blob/feature/new-tutorial-format/inst/rmarkdown/templates/tutorial/resources/tutorial-format.js#L145

https://github.com/rstudio/tutor/blob/feature/new-tutorial-format/inst/rmarkdown/templates/tutorial/resources/tutorial-format.js#L179

@robbyshaver

Cannot progressively reveal sub-sections that follow a sub-section that has no exercises

Progressive reveal seems to rely on exercise completion to trigger reveals. As a result, you cannot reveal the next sub-section if the current sub-section does not contain an exercise. Related to #26.

To see this in action, launch the tutorial below and then compare the behavior of "First Section" to the behavior of "Second Section".

---
title: "Demo Tutorial"
output: 
  tutor::tutorial:
    progressive: true
runtime: shiny_prerendered
---

```{r setup, include=FALSE}
library(tutor)
checker <- function(label, user_code, check_code, envir_result, evaluate_result, ...) {
  list(message = "Good Job!", correct = TRUE, location = "append")
}
tutor_options(exercise.checker = checker)
```

## Welcome

This is the Welcome section. It has an exercise to ensure that the TOC appears. Click "Submit Code" to move on.

```{r one, exercise = TRUE}

```

```{r one-check}
"foo"
```

## First task

### Visible sub-section

This sub-section is visible. If it had an exercise to complete, you could move on to the next sub-section, which is hidden. Notice that there is no "Next Topic" button.

### Hidden sub-section

This sub-section is hidden. You cannot access it because there is no exercise to complete in the previous section.

## Second Task

### Another Visible sub-section

This is the Second Task section. It has an exercise to complete, so you can move on to the hidden sub-section.

This is the Welcome section. It has an exercise to ensure that the TOC appears. Click "Submit Code" to move on.

```{r two, exercise = TRUE}

```

```{r two-check}
"foo"
```

### Another Hidden sub-section

This section is hidden, but you can reveal it by completing the exercise above. Notice that there is no "Next Topic" button.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.