Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Code Handout #794

Closed
ericcrandall opened this issue May 13, 2022 · 3 comments
Closed

Code Handout #794

ericcrandall opened this issue May 13, 2022 · 3 comments

Comments

@ericcrandall
Copy link

This is a really great lesson, and I'm glad it includes a code handout for beginners. However, as I went to teach the lesson for my checkout, I found myself getting lost in the handout, as only challenges and some section headings are given. Would be helpful to provide commented headings for each of the episodes, and any subheadings that include code as part of the instruction. I wanted to try to do this as a pull request, but am not very familiar with make files.

@seanbergin
Copy link

I was assigned the beginning of the starting with data section of this lesson. There is a long command/url that students must enter correctly: download.file(url = "https://ndownloader.figshare.com/files/2292169",
destfile = "data_raw/portal_data_joined.csv")

I know that we want students to type everything on their own, but waiting for typos in this section to be resolved seems like an unnecessary roadblock. I would like to suggest that the code handout include the above URL so that students can copy/paste it. One can include the url - but not the command so that the instructor can live code the rest.

@Teebusch
Copy link
Contributor

Both great suggestions!

@ericcrandall good point. The code handout doesn't really have much to do with the make file, I think. What ends up in the handout is determined by putting it in the lesson .Rmd inside a knitr chunks with purl=TRUE set. For example

## Vectors and data types

```{r, echo = FALSE, purl = TRUE}
### Vectors and data types
```

(see in file)

This will show the level 2 heading in the lesson and put a level 3 heading with the same text in the handout (not sure why one is level 2 and the other one level 3, to be honest). As you can imagine, this is a bit redundant and difficult to maintain. To fix the issue you are mentioning, someone needs to go through the code alongside the handout and fix the inconsistencies. For example, to add a level 1 heading before each chapter, one would have to add, at the beginning of each .Rmd file, something like

```{r, echo = FALSE, purl = TRUE}
# Before we Start
```

@seanbergin, I usually copy-paste the URL into the etherpad that I share with the learners. But it wouldn't hurt to have the link in the code handout, too.

@tobyhodges
Copy link
Member

Thanks everyone for contributing to this discussion. The lesson underwent a major update and reorganisation when #887 was merged. The current version of the lesson does not include the code handout, so I am going to close this issue. Please open a new issue if you believe it would be helpful to include a handout for the redesigned lesson.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants