Skip to content

Commit 6b756d5

Browse files
committed
edits on chapter 9
1 parent fb56f1c commit 6b756d5

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

09-code-review.Rmd

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ ottrpal::set_knitr_image_path()
1111
ottrpal::include_slide("https://docs.google.com/presentation/d/1LMurysUhCjZb7DVF6KS9QmJ5NBjwWVjRn40MS9f2noE/edit#slide=id.gf8379bb805_0_6")
1212
```
1313

14-
We've previously discussed that the only way to know if your analysis is truly reproducible is to send it to someone else to reproduce! That sentiment is at the heart of code review. Although most wouldn't dare send out a manuscript for publishing without having our collaborators giving it a line-by-line review, people don't always feel the same way about code.
14+
We've previously discussed that the only way to know if your analysis is truly reproducible is to send it to someone else to reproduce! That sentiment is at the heart of code review. Although most wouldn't dare send out a manuscript for publishing without having collaborators giving it a line-by-line review, people don't always feel the same way about code.
1515

1616
@Parker2017 describes code review:
1717

@@ -34,7 +34,7 @@ Since reproducibility is all about someone else being able to run your code and
3434
```{r, fig.align='center', echo = FALSE, fig.alt= "Ruby the researcher and Avi the associate are so happy because Avi was able to reproduce Ruby’s results on his computer."}
3535
ottrpal::include_slide("https://docs.google.com/presentation/d/1LMurysUhCjZb7DVF6KS9QmJ5NBjwWVjRn40MS9f2noE/edit#slide=id.g1006ff8e7e9_48_33")
3636
```
37-
In the second part of this reproducibility course we will discuss how to conduct formal line-by-line code reviews, but for now, we will discuss how to prep your analysis for someone else look at your code and attempt to run it.
37+
In the second part of this reproducibility course we will discuss how to conduct formal line-by-line code reviews, but for now, we will discuss how to prep your analysis for someone else to look at your code and attempt to run it.
3838

3939
At this point, you should have a GitHub repository that contains the following:
4040

@@ -49,19 +49,19 @@ Before you send off your code to someone else, delete your output (the `results`
4949

5050
**2) Re-run the whole analysis**
5151

52-
**3) Interrogate and troubleshoot**
52+
**3) Interrogate and troubleshoot**
5353
If your code has any issues running, try your best to troubleshoot the problems. Read this handy guide for [tips on troubleshooting R](https://github.com/AlexsLemonade/training-modules/blob/master/intro-to-R-tidyverse/00b-debugging_resources.Rmd).
5454

5555
**4) Rinse and repeat**
56-
Repeat this as many times as needed until you reliably are able to re-run this code and get the same results without any [code smells](https://github.com/jennybc/code-smells-and-feels#code-smells-and-feels) popping up. Dig into bad code smells or bad results smells wherever you sense them. If you aren't sure why you feel this way about your code or results, hold on to this and it may be something your collaborator will be able to see something you don't.
56+
Repeat this as many times as needed until you reliably are able to re-run this code and get the same results without any [code smells](https://github.com/jennybc/code-smells-and-feels#code-smells-and-feels) popping up. Dig into bad code smells or bad results smells wherever you sense them. If you aren't sure why you feel this way about your code or results, hold on to this. It may be something your collaborator will be able to see that you missed.
5757

5858
**5) Let it simmer**
5959
Leave your analysis for a bit. Do you think it's perfect? Are you at your wits end with it? No matter how you feel about it, let it sit for a half a day or so then return to it with fresh eyes [@Savonen2021b].
6060

61-
**5) Re-review your documentation and code with fresh eyes**
61+
**6) Re-review your documentation and code with fresh eyes**
6262
Now with fresh eyes and doing your best to imagine you don't have the knowledge you have -- does your analysis and results make sense?
6363

64-
**6) Are you sure it's ready?**
64+
**7) Are you sure it's ready?**
6565
Ask yourself if you've polished this code and documentation as far as you can reasonably take it? Realizing that determining what qualifies `as far as you can reasonably take it` is also a skill you will build with time. Code review is the most efficient use of everyone's time when your code and documentation have reached this point.
6666

6767
**8) Draft your request**
@@ -79,7 +79,7 @@ _Code review requests should include:_
7979
- Lastly, thank them for helping review your code!
8080

8181
**9) Ready for review**
82-
Now you are ready to send your crafted message to your collaborator for review. But, for the purposes of this exercise, you may **not** want to ask your collaborator to spend their time carefully review this practice repository, but now that you understand and have done the steps involved _you are prepared to do this for your own analyses_!
82+
Now you are ready to send your crafted message to your collaborator for review. For the purposes of this exercise, you may **not** want to ask your collaborator to spend their time carefully reviewing a practice repository. However, now that you understand and have done the steps involved _you are prepared to do this for your own analyses_!
8383

8484
TL;DR for asking for a code review:
8585
```{r, fig.align='center', echo = FALSE, fig.alt= "This chapter will demonstrate how to: How code review is the best way to enhance the reproducibility of your analyses over time. Engage in basic code review for your analysis."}

0 commit comments

Comments
 (0)