Skip to content

Commit

Permalink
merge main
Browse files Browse the repository at this point in the history
  • Loading branch information
lgatto committed Jul 12, 2024
2 parents 498b226 + d95c749 commit d15871f
Show file tree
Hide file tree
Showing 8 changed files with 563 additions and 407 deletions.
10 changes: 5 additions & 5 deletions .github/workflows/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

This directory contains workflows to be used for Lessons using the {sandpaper}
lesson infrastructure. Two of these workflows require R (`sandpaper-main.yaml`
and `pr-recieve.yaml`) and the rest are bots to handle pull request management.
and `pr-receive.yaml`) and the rest are bots to handle pull request management.

These workflows will likely change as {sandpaper} evolves, so it is important to
keep them up-to-date. To do this in your lesson you can do the following in your
Expand Down Expand Up @@ -94,9 +94,9 @@ branch called `update/workflows` and a pull request is created. Maintainers are
encouraged to review the changes and accept the pull request if the outputs
are okay.

This update is run ~~weekly or~~ on demand.
This update is run weekly or on demand.

### 03 Maintain: Update Pacakge Cache (update-cache.yaml)
### 03 Maintain: Update Package Cache (update-cache.yaml)

For lessons that have generated content, we use {renv} to ensure that the output
is stable. This is controlled by a single lockfile which documents the packages
Expand Down Expand Up @@ -140,7 +140,7 @@ Once the checks are finished, a comment is issued to the pull request, which
will allow maintainers to determine if it is safe to run the
"Receive Pull Request" workflow from new contributors.

### Recieve Pull Request (pr-recieve.yaml)
### Receive Pull Request (pr-receive.yaml)

**Note of caution:** This workflow runs arbitrary code by anyone who creates a
pull request. GitHub has safeguarded the token used in this workflow to have no
Expand Down Expand Up @@ -171,7 +171,7 @@ The artifacts produced are used by the next workflow.

### Comment on Pull Request (pr-comment.yaml)

This workflow is triggered if the `pr-recieve.yaml` workflow is successful.
This workflow is triggered if the `pr-receive.yaml` workflow is successful.
The steps in this workflow are:

1. Test if the workflow is valid and comment the validity of the workflow to the
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/sandpaper-version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.12.4
0.16.5
4 changes: 1 addition & 3 deletions episodes/25-starting-with-data.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ columns represent:
| age | The age of the mouse (all mice were 8 weeks here) |
| sex | The sex of the mouse |
| infection | The infection state of the mouse, i.e. infected with Influenza A or not infected. |
| strain | The Influenza A strain; C57BL/6 in all cases. |
| strain | The Influenza A strain. |
| time | The duration of the infection (in days). |
| tissue | The tissue that was used for the gene expression experiment, i.e. cerebellum or spinal cord. |
| mouse | The mouse unique identifier. |
Expand Down Expand Up @@ -206,8 +206,6 @@ questions?
- class: data frame
- how many rows: 32428, how many columns: 19



:::::::::::::::::::::::::

::::::::::::::::::::::::::::::::::::::::::::::::::
Expand Down
15 changes: 7 additions & 8 deletions episodes/30-dplyr.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,11 @@ exercises: 75
::::::::::::::::::::::::::::::::::::::: objectives

- Describe the purpose of the **`dplyr`** and **`tidyr`** packages.
- Describe several of their functions that are extremely useful to manipulate data.
- Describe the concept of a wide and a long table format, and see how to reshape a data frame from one format to the other one.
- Describe several of their functions that are extremely useful to
manipulate data.
- Describe the concept of a wide and a long table format, and see
how to reshape a data frame from one format to the other one.
- Demonstrate how to join tables.

::::::::::::::::::::::::::::::::::::::::::::::::::

Expand All @@ -24,7 +27,7 @@ exercises: 75

```{r loaddata_dplyr, echo=FALSE, purl=FALSE, message=FALSE}
if (!file.exists("data/rnaseq.csv"))
download.file(url = "https://github.com/Bioconductor/bioconductor-teaching/raw/master/data/GSE96870/rnaseq.csv",
download.file(url = "https://github.com/carpentries-incubator/bioc-intro/raw/main/episodes/data/rnaseq.csv",
destfile = "data/rnaseq.csv")
```

Expand Down Expand Up @@ -511,7 +514,6 @@ rna %>%
## 3.
rna %>%
filter(sample == "GSM2545336") %>%
group_by(gene_biotype) %>%
count(gene_biotype) %>%
arrange(desc(n))
## 4.
Expand Down Expand Up @@ -612,16 +614,13 @@ Let's imagine that for some reason, we had some missing expression values for so
genes in certain samples. In the following fictive example, the gene Cyp2d22 has only
one expression value, in GSM2545338 sample.

```{r, purl=TRUE, echo=FALSE}
```{r, purl=TRUE}
rna_with_missing_values <- rna %>%
select(gene, sample, expression) %>%
filter(gene %in% c("Asl", "Apod", "Cyp2d22")) %>%
filter(sample %in% c("GSM2545336", "GSM2545337", "GSM2545338")) %>%
arrange(sample) %>%
filter(!(gene == "Cyp2d22" & sample != "GSM2545338"))
```

```{r, purl=TRUE}
rna_with_missing_values
```

Expand Down
2 changes: 1 addition & 1 deletion episodes/40-visualization.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ exercises: 60

```{r loaddata_vis, echo=FALSE, purl=FALSE, message=FALSE}
if (!file.exists("data/rnaseq.csv"))
download.file(url = "https://raw.githubusercontent.com/Bioconductor/bioconductor-teaching/master/data/GSE96870/rnaseq.csv",
download.file(url = "https://github.com/carpentries-incubator/bioc-intro/raw/main/episodes/data/rnaseq.csv",
destfile = "data/rnaseq.csv")
```

Expand Down
3 changes: 1 addition & 2 deletions learners/setup.md
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,6 @@ commands. For now, simply follow the instructions below:

```r
install.packages(c("BiocManager", "remotes"))
BiocManager::install(c("tidyverse", "SummarizedExperiment",
"UCLouvain-CBIO/rWSBIM1207", "hexbin",
BiocManager::install(c("tidyverse", "SummarizedExperiment", "hexbin",
"patchwork", "gridExtra", "lubridate"))
```
Loading

0 comments on commit d15871f

Please sign in to comment.