Skip to content

Commit

Permalink
Render site
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions[bot] committed Jan 13, 2025
1 parent 8d46289 commit c405c01
Show file tree
Hide file tree
Showing 7 changed files with 62 additions and 30 deletions.
8 changes: 4 additions & 4 deletions help.html
Original file line number Diff line number Diff line change
Expand Up @@ -347,14 +347,14 @@ <h2><strong>Why are my changes not taking effect? It’s making my results look
<p>Here we are creating a new object from an existing one:</p>
<pre class="r"><code>new_rivers &lt;- sample(rivers, 5)
new_rivers</code></pre>
<pre><code>## [1] 310 1100 2348 380 500</code></pre>
<pre><code>## [1] 360 255 600 377 720</code></pre>
<p>Using just this will only print the result and not actually change <code>new_rivers</code>:</p>
<pre class="r"><code>new_rivers + 1</code></pre>
<pre><code>## [1] 311 1101 2349 381 501</code></pre>
<pre><code>## [1] 361 256 601 378 721</code></pre>
<p>If we want to modify <code>new_rivers</code> and save that modified version, then we need to reassign <code>new_rivers</code> like so:</p>
<pre class="r"><code>new_rivers &lt;- new_rivers + 1
new_rivers</code></pre>
<pre><code>## [1] 311 1101 2349 381 501</code></pre>
<pre><code>## [1] 361 256 601 378 721</code></pre>
<p>If we forget to reassign this can cause subsequent steps to not work as expected because we will not be working with the data that has been modified.</p>
<hr />
</div>
Expand Down Expand Up @@ -403,7 +403,7 @@ <h2><strong>Error: object ‘X’ not found</strong></h2>
<p>Make sure you run something like this, with the <code>&lt;-</code> operator:</p>
<pre class="r"><code>rivers2 &lt;- new_rivers + 1
rivers2</code></pre>
<pre><code>## [1] 312 1102 2350 382 502</code></pre>
<pre><code>## [1] 362 257 602 379 722</code></pre>
<hr />
</div>
<div id="error-unexpected-in-error-unexpected-in-error-unexpected-x-in" class="section level2">
Expand Down

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ install.packages("ggplot2")

```{r, comment = FALSE}
library(esquisse)
library(ggplot2)
library(tidyverse)
```

### 1.1
Expand Down

Large diffs are not rendered by default.

39 changes: 30 additions & 9 deletions modules/Manipulating_Data_in_R/Manipulating_Data_in_R.html

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,7 @@ knitr::opts_chunk$set(echo = TRUE)
Data in this lab comes from the CDC (https://covid.cdc.gov/covid-data-tracker/#vaccinations_vacc-total-admin-rate-total - snapshot from January 12, 2022) and the Bureau of Economic Analysis (https://www.bea.gov/data/income-saving/personal-income-by-state).

```{r message=FALSE}
library(readr)
library(dplyr)
library(tidyr)
library(tidyverse)
```

# Part 1
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -166,9 +166,7 @@ <h1 class="title toc-ignore">Manipulating Data in R Lab - Key</h1>


<p>Data in this lab comes from the CDC (<a href="https://covid.cdc.gov/covid-data-tracker/#vaccinations_vacc-total-admin-rate-total" class="uri">https://covid.cdc.gov/covid-data-tracker/#vaccinations_vacc-total-admin-rate-total</a> - snapshot from January 12, 2022) and the Bureau of Economic Analysis (<a href="https://www.bea.gov/data/income-saving/personal-income-by-state" class="uri">https://www.bea.gov/data/income-saving/personal-income-by-state</a>).</p>
<pre class="r"><code>library(readr)
library(dplyr)
library(tidyr)</code></pre>
<pre class="r"><code>library(tidyverse)</code></pre>
<div id="part-1" class="section level1">
<h1>Part 1</h1>
<div id="section" class="section level3">
Expand Down

0 comments on commit c405c01

Please sign in to comment.