Skip to content

Commit

Permalink
markdown source builds
Browse files Browse the repository at this point in the history
Auto-generated via {sandpaper}
Source  : 2defd09
Branch  : main
Author  : Jason Williams <JasonJWilliamsNY@gmail.com>
Time    : 2024-03-13 15:42:17 +0000
Message : Merge pull request #259 from naupaka/main

Add callout differentiating %in% and == to address #258
  • Loading branch information
actions-user committed Mar 13, 2024
1 parent f471608 commit 3dc050b
Show file tree
Hide file tree
Showing 4 changed files with 1,092 additions and 1 deletion.
17 changes: 17 additions & 0 deletions 01-r-basics.md
Original file line number Diff line number Diff line change
Expand Up @@ -809,6 +809,23 @@ c("ACTN3","APOA5") %in% snp_genes
[1] TRUE TRUE
```

::::::::::::::::::::::::::::::::::::::::: callout

## Tip: What's the difference between the `%in% and the `==` operators?

The `%in%` operator is used to test if the elements of a vector are
present in another vector. In the example above, if both "ACTN3" and "APOA5" are in
the vector `snp_genes`, then R will return `TRUE TRUE` since they are both present.
If "ACTN3" is but "APOA5" is not in `snp_genes`, then R will return `TRUE FALSE`. The `==` operator
is used to test if two vectors are exactly equal. For example, if you wanted to know if the vector `c(1, 2, 3)`
was equal to the vector `c(1, 2, 3)`, you could use the `==` operator. One trick people sometimes
use is to check a single value against a vector with the `==` operator. For example, if you wanted to know
if the value `1` was in the vector `c(1, 2, 3)`, you could use the expression `1 == c(1, 2, 3)`. This would
return `TRUE FALSE FALSE` since the value `1` is only in the first position of the vector `c(1, 2, 3)`. Note that
`c(1, 2) == c(1, 2, 3)` will return an error since the vectors are of different lengths.

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

::::::::::::::::::::::::::::::::::::::: challenge

## Review Exercise 1
Expand Down
88 changes: 88 additions & 0 deletions config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,88 @@
#------------------------------------------------------------
# Values for this lesson.
#------------------------------------------------------------

# Which carpentry is this (swc, dc, lc, or cp)?
# swc: Software Carpentry
# dc: Data Carpentry
# lc: Library Carpentry
# cp: Carpentries (to use for instructor training for instance)
# incubator: The Carpentries Incubator
carpentry: 'dc'

# Overall title for pages.
title: 'Intro to R and RStudio for Genomics'

# Date the lesson was created (YYYY-MM-DD, this is empty by default)
created: '2018-03-12'

# Comma-separated list of keywords for the lesson
keywords: 'software, data, lesson, The Carpentries'

# Life cycle stage of the lesson
# possible values: pre-alpha, alpha, beta, stable
life_cycle: 'beta'

# License of the lesson materials (recommended CC-BY 4.0)
license: 'CC-BY 4.0'

# Link to the source repository for this lesson
source: 'https://github.com/datacarpentry/genomics-r-intro'

# Default branch of your lesson
branch: 'main'

# Who to contact if there are any issues
contact: 'team@carpentries.org'

# Navigation ------------------------------------------------
#
# Use the following menu items to specify the order of
# individual pages in each dropdown section. Leave blank to
# include all pages in the folder.
#
# Example -------------
#
# episodes:
# - introduction.md
# - first-steps.md
#
# learners:
# - setup.md
#
# instructors:
# - instructor-notes.md
#
# profiles:
# - one-learner.md
# - another-learner.md

# Order of episodes in your lesson
episodes:
- 00-introduction.Rmd
- 01-r-basics.Rmd
- 02-data-prelude.Rmd
- 03-basics-factors-dataframes.Rmd
- 04-bioconductor-vcfr.Rmd
- 05-dplyr.Rmd
- 06-data-visualization.Rmd
- 07-r-help.Rmd

# Information for Learners
learners:

# Information for Instructors
instructors:

# Learner Profiles
profiles:

# Customisation ---------------------------------------------
#
# This space below is where custom yaml items (e.g. pinning
# sandpaper and varnish versions) should live


url: 'https://datacarpentry.github.io/genomics-r-intro'
analytics: carpentries
lang: en
2 changes: 1 addition & 1 deletion md5sum.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"config.yaml" "b91cd97fa3b408bd1ac0a00e67ab3219" "site/built/config.yaml" "2024-03-12"
"index.md" "7f9c30e6487338a0c3f8ecc4018873ab" "site/built/index.md" "2024-03-12"
"episodes/00-introduction.Rmd" "0703d3a4fb9cd0dfc4d54c78dea6fee6" "site/built/00-introduction.md" "2024-03-12"
"episodes/01-r-basics.Rmd" "cf0ee85e99104da0316a085faf32ae21" "site/built/01-r-basics.md" "2024-03-12"
"episodes/01-r-basics.Rmd" "0ae61163db8e5696c89db014882eb315" "site/built/01-r-basics.md" "2024-03-13"
"episodes/02-data-prelude.Rmd" "ab2b1fd3cdaae919f9e409f713a0a8ad" "site/built/02-data-prelude.md" "2024-03-12"
"episodes/03-basics-factors-dataframes.Rmd" "cab7ab3fe53143558e6af3eee5774d35" "site/built/03-basics-factors-dataframes.md" "2024-03-12"
"episodes/04-bioconductor-vcfr.Rmd" "10eb69b4697d7ecb9695d36c0d974208" "site/built/04-bioconductor-vcfr.md" "2024-03-12"
Expand Down
Loading

0 comments on commit 3dc050b

Please sign in to comment.