From 64101e8cb92adebedae2d41b83a913f214eff45b Mon Sep 17 00:00:00 2001 From: "Luke W. Johnston" Date: Wed, 16 Oct 2024 13:47:14 -0400 Subject: [PATCH] docs(sessions): :memo: add learning objectives for intro Closes #19 --- sessions/introduction.qmd | 40 +++++++++++++++++++++++---------------- 1 file changed, 24 insertions(+), 16 deletions(-) diff --git a/sessions/introduction.qmd b/sessions/introduction.qmd index db68faf..17b3c9a 100644 --- a/sessions/introduction.qmd +++ b/sessions/introduction.qmd @@ -19,11 +19,21 @@ The slides contain speaking notes that you can view by pressing 'S' on the keyboard. ::: -Learning objectives: +## Learning objectives -- Why it can be very powerful and useful to create even a simple R package. +The overall **learning outcome** for this session is: -- Identify when and why to create an R package. +1. Explain in general terms why and how an R package can simplify your + work, as well as a high-level overview of the workflow in developing + an R package. + +Specific **objectives** are: + +1. Compare the differences in work and effort between creating simple + scripts to help with your and others' work and making a simple R package of + the same code. +2. Describe the benefits and challenges to creating an R package. +3. Outline some basic steps that are necessary to develop an R package. ## The Big Picture @@ -98,18 +108,17 @@ package isn't as difficult as it might first sound. But before making a package, there's a few things to think about. For instance, how do you determine if you should make an R package? Ask yourself these questions: -- Have you ever made a function, no matter how simple? -- Have you ever used that function more than once across more than one - project or file, either by copying and pasting it or by sourcing the file - that contains it? +- Have you ever made a function, no matter how simple? +- Have you ever used that function more than once across more than one + project or file, either by copying and pasting it or by sourcing the + file that contains it? -If you answered yes to these two questions, then you should -make an R package for that function. But you might wonder, why make a -package with only one function? Because it never stops with *just* one -function, you will very likely be making more in your work. Aside from -packaging up R functions, if you have small to medium sized datasets -that you use across multiple projects or files, you can even package up -the data too. +If you answered yes to these two questions, then you should make an R +package for that function. But you might wonder, why make a package with +only one function? Because it never stops with *just* one function, you +will very likely be making more in your work. Aside from packaging up R +functions, if you have small to medium sized datasets that you use +across multiple projects or files, you can even package up the data too. Aside from a "yes" to these questions, making an R package now is much easier than it was in the past. That's largely thanks to R packages like @@ -126,5 +135,4 @@ science components of research. That's because making an R package usually requires a higher level of rigor, testing, documentation, and inspection of the code, meaning you and others can have more trust in the results. And if its on GitHub, it's much easier to share your work -with others and have a bigger impact on research overall. - +with others and have a bigger impact on research overall. \ No newline at end of file