Tutorial: Data Manipulation with dplyr
<p><a class="btn btn-primary" href="https://mdlama.github.io/Data_Manipulation/">Launch Tutorial</a></p> <p><img src="https://github.com/mdlama/Data_Manipulation/blob/main/images/data-science-explore.png?raw=true" /></p> <p>Figure 1: The data life cycle. Image from <a href="https://r4ds.had.co.nz/explore-intro.html">&ldquo;R for Data Science&rdquo;</a></p> <p>A model of the data life cycle from the free online book <a href="http://r4ds.had.co.nz/explore-intro.html">&ldquo;R for Data Science&rdquo;</a> is shown in Figure 1. The whirlpool in the middle, besides making you dizzy I&rsquo;m sure, is one of the most rewarding parts of the process - data exploration! There are some important take home points from the &ldquo;Explore&rdquo; portion of the diagram:</p> <ol> <li>Data might require transformation before proper visualization.</li> <li>It is best to visualize your data before you do statistical analysis (also known as statistical modeling).</li> <li>Rarely if ever will you complete this cycle only once.</li> <li>Iterate towards perfection. In other words, don&rsquo;t worry about perfectly formatted publication quality graphs and results. Exploration should be full of fun and curiosity. Save the publication quality results for the &ldquo;Communicate&rdquo; step.</li> </ol> <p>In this tutorial, we will introduce you to the tidyverse and start with the <strong>Transform</strong> part of the life cycle, exploring the tidyverse data manipulation (also known as <em>data wrangling</em>) package <code>dplyr</code>.</p> <h4>Built with</h4> <p><a href="https://r-wasm.github.io/quarto-live/" rel="nofollow noopener noreferrer" target="_blank">Quarto Live</a>&nbsp;- WebAssembly powered code blocks and exercises for Quarto HTML documents. Quarto is the &ldquo;next generation&rdquo; of&nbsp;<a href="http://rmarkdown.rstudio.com/" rel="nofollow noopener noreferrer" target="_blank">R Markdown</a>. Quarto Live uses&nbsp;<a href="https://docs.r-wasm.org/webr/latest/" rel="nofollow noopener noreferrer" target="_blank">WebR</a>, which facilitates running R code directly in the browser with no need for a server.</p> <h4>Acknowledgements</h4> <p>This course is based on <em>R for Data Science: Data Transformation</em>.&nbsp;For the purposes of this license, appropriate credit requires including the phrase,<strong> &quot;R for Data Science from O&#39;Reilly Media, Inc. Copyright &copy; 2017 Garrett Grolemund, Hadley Wickham. Used with permission.&quot;</strong></p>
Institutions
- William & Mary (US)
Publication Details
- Journal
- QUBES
- Published
- 2025-11-11
- DOI
- https://doi.org/10.25334/h0v0-m514
- Primary Topic
- Data Analysis with R
- Type
- article
- Field-Weighted Citation Impact
- 0.00