From e5789309adc734d7ecc87500dee5f11e72788af7 Mon Sep 17 00:00:00 2001 From: Aleksandra Wilczynska Date: Thu, 26 Oct 2023 16:49:09 +0200 Subject: [PATCH 01/38] start translation of first episode to Carpentries Benchmark --- config.yaml | 15 +- episodes/01-intro-to-r.Rmd | 233 ++++++++++++++++++++ episodes/fig/rstudio_project_files.jpeg | Bin 0 -> 41926 bytes renv/activate.R | 25 +-- renv/profiles/lesson-requirements/renv.lock | 8 +- 5 files changed, 245 insertions(+), 36 deletions(-) create mode 100644 episodes/01-intro-to-r.Rmd create mode 100644 episodes/fig/rstudio_project_files.jpeg diff --git a/config.yaml b/config.yaml index f711a90d..02d81483 100644 --- a/config.yaml +++ b/config.yaml @@ -11,29 +11,29 @@ carpentry: 'incubator' # Overall title for pages. -title: 'Lesson Title' # FIXME +title: 'Lesson Title' # Date the lesson was created (YYYY-MM-DD, this is empty by default) -created: ~ # FIXME +created: # Comma-separated list of keywords for the lesson -keywords: 'software, data, lesson, The Carpentries' # FIXME +keywords: 'software, data, lesson, The Carpentries' # Life cycle stage of the lesson # possible values: pre-alpha, alpha, beta, stable -life_cycle: 'pre-alpha' # FIXME +life_cycle: 'pre-alpha' -# License of the lesson +# 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/carpentries/workbench-template-rmd' # FIXME +source: 'https://github.com/carpentries/workbench-template-rmd' # Default branch of your lesson branch: 'main' # Who to contact if there are any issues -contact: 'team@carpentries.org' # FIXME +contact: 'team@carpentries.org' # Navigation ------------------------------------------------ # @@ -60,6 +60,7 @@ contact: 'team@carpentries.org' # FIXME # Order of episodes in your lesson episodes: - introduction.Rmd +- 01-intro-to-r.Rmd # Information for Learners learners: diff --git a/episodes/01-intro-to-r.Rmd b/episodes/01-intro-to-r.Rmd new file mode 100644 index 00000000..678be877 --- /dev/null +++ b/episodes/01-intro-to-r.Rmd @@ -0,0 +1,233 @@ +--- +title: 'Introduction to R and RStudio' +teaching: 45 +exercises: 5 +--- + +```{r setup, include=FALSE} +knitr::opts_chunk$set( + echo = TRUE, + message = FALSE, + warning = FALSE, + eval = FALSE +) + +# Load libraries ---------------------------------------------------------- +# Package names +packages <- c("tidyverse", "here") + +# Install packages not yet installed +installed_packages <- packages %in% rownames(installed.packages()) +if (any(installed_packages == FALSE)) { + install.packages(packages[!installed_packages]) +} + +# Packages loading +invisible(lapply(packages, library, character.only = TRUE)) + +``` + +:::::::::::::::::::::::::::::::::::::: questions + +- How to find your way around RStudio? +- How to manage your environment? +- How to install packages? +- How to interact with R? +- How can I manage my projects in R? + +:::::::::::::::::::::::::::::::::::::::::::::::: + +::::::::::::::::::::::::::::::::::::: objectives + +- Describe the purpose and use of each pane in the RStudio IDE +- Locate buttons and options in the RStudio IDE +- Create self-contained projects in RStudio +- Define a variable +- Assign data to a variable +- Use mathematical and comparison operators +- Call functions +- Manage packages + +:::::::::::::::::::::::::::::::::::::::::::::::: + +## Project management in RStudio +RStudio is an integrated development environment (IDE), which means +it provides a (much prettier) interface for the R software. For R Studio to work, +you need to have R installed on your computer. But R is integrated into RStudio, +so you never actually have to open R software. + +R Studio provides a useful feature: creating projects - +self-contained working space (i.e. working directory), to which R will refer to, +when looking for and saving files. +You can create projects in existing directories (folders) or create a new one. + +### Creating RStudio Project +We’re going to create a project in RStudio in a new directory. +To create a project, go to: + +- `File` +- `New Project` +- `New directory` +- Place the project that you will easily find on your laptop and name the + project `data-carpentry` +-`Create project` + + +### Organising working directory + +Creating an RStudio project is a good first step towards good project management. +However, most of the time it is a good idea to organize working space further. +This is one suggestion of how your R project can look like. +Let's go ahead and create the other folders: + +- `data/` - should be where your raw data is. **READ ONLY** +- `data_output/` - should be where your data output is saved **READ AND WRITE** +- `document/s` - all the documentation associated with the project (e.g. cookbook) +- `fig_output/` - your figure outputs go here **WRITE ONLY** +- `scripts/` - all your code goes here **READ AND WRITE** + +![R project organization](fig/rstudio_project_files.jpeg){alt="R Studio +project logo with five lines, each leading from the logo towards +one of the five boxes with texts: 'data/', 'data_output/', 'documents/', +'fig_output/', 'scripts/'"} + + +You can create these folders as you would any other folders on your laptop, but +R and RStudio offer handy ways to do it directly in your RStudio session. + +You can use RStudio interface to create a folder in your project by going to +lower-bottom pane, files tab, and clicking on Folder icon. +A dialog box will appear, allowing you typing a name of a folder you want to create. + +An alternative solution is to create the folders using R command `dir.create()`. +In the console type + +```{r} +dir.create('data') +dir.create('data_output') +dir.create('documents') +dir.create('fig_output') +dir.create('scripts') + +``` + + +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: instructor + +In interest of time, focus on one way of creating the folders. You can showcase +an alternative method with just one example. + +Once you have finished, ask the participants if they have managed to create a +R Project and get the same folder structure. +To do this, use green and red stickers. + +This will become important, as we use relative paths together with `here` +package to read and write objects. + +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: + +### Two main ways to interact with R + +There are two main ways to interact with R through RStudio: + +- Test and play environment within the **interactive R console** +- Write and save an **R script (`.R` file)** + +Each of the modes o interactions has its advantages and drawbacks. + +| | Console | R script| +|--------|---------|---------| +|**Pros**|Immediate results|Work lost once you close RStudio | +|**Cons**|Complete record of your work |Messy if you just want to print things out| + +During the workshop we will mostly use an R Script to have a full documentation +of what has been written. + +### Running the code + +- In the console: `Enter` +- In the script: + - `Ctrl` + `Enter` (for MAC users: `Command` + `Enter`) + - `Run` button on right left - current line or selection + +### Creating a script +We're going to work with a script. Let's create one now and save it in the `scripts` directory. + +- `File` +- `New File` +- `R Script` +- A new `Untitled` script will appear in the source pane. Save it using floppy disc icon. +- Name it `intro-to-r.R` + + + + + + + + + + + + + + + + + + + +::::::::::::::::::::::::::::::::::::: challenge + +## Challenge 1: Can you do it? + +What is the output of this command? + +```r +paste("This", "new", "lesson", "looks", "good") +``` + +:::::::::::::::::::::::: solution + +## Output + +```output +[1] "This new lesson looks good" +``` + +::::::::::::::::::::::::::::::::: + + +## Challenge 2: how do you nest solutions within challenge blocks? + +:::::::::::::::::::::::: solution + +You can add a line with at least three colons and a `solution` tag. + +::::::::::::::::::::::::::::::::: +:::::::::::::::::::::::::::::::::::::::::::::::: + +## Figures + +You can include figures generated from R Markdown: + +```{r pyramid, fig.alt = "pie chart illusion of a pyramid", fig.cap = "Sun arise each and every morning"} +pie( + c(Sky = 78, "Sunny side of pyramid" = 17, "Shady side of pyramid" = 5), + init.angle = 315, + col = c("deepskyblue", "yellow", "yellow3"), + border = FALSE +) +``` + + + +::::::::::::::::::::::::::::::::::::: keypoints + +- Use `.md` files for episodes when you want static content +- Use `.Rmd` files for episodes when you need to generate output +- Run `sandpaper::check_lesson()` to identify any issues with your lesson +- Run `sandpaper::build_lesson()` to preview your lesson locally + +:::::::::::::::::::::::::::::::::::::::::::::::: + diff --git a/episodes/fig/rstudio_project_files.jpeg b/episodes/fig/rstudio_project_files.jpeg new file mode 100644 index 0000000000000000000000000000000000000000..e6a62544543897605c5efb284dbe75cb6c7be7ff GIT binary patch literal 41926 zcmeFZ2UJtfx;MNLq(eaIEhs8YM3g2iDAGkxq&ESPCQVv^KoBWP6%h~=Lhld|0!WpP zBGQYXKmer)B+>$ew;|WRgAEd*<0QPyIbZo+Qr!EIJz6 z8UO_a0BC_PfQ$u9)#1+f0YFa=5CZ^!7C1(60-ywI6yOVpat5gWR0n`_;3oi3W>Nh0 zY}T6uf-lA|QWFTaW73)xhIV^|ODfvW)V_ zeog@1P_2a0z5GGA7D9dpu+ma|q|%_II1L#ut&!!{&f85Z{QonF-ofA z)HJko^bBAF3=7zGO3GtYl*f<%x(!7zcpji)J$~Yp)K%(}w`^%nd$C=5l$cE`bgin5 z{q_*<%w@ZWVRZByoLt;IXU_?Xh>A(e$jZrIQBb?CuA!-=tz&q{$k@cx%-sH-!+l35 zXBTfDUq63%K;Yx>h{&iXPotkFy+}?;eVLY?lbe@cP*_x4@}{~5Q(IU6wxPYFv#YzO z_x*?AkUQGS*ebnlA=Cw^%jk-*U8hD9?`O0OU$lnqZ7J(8^><FH?c=;#?C zjP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PB8!w1;ZmKfk}xYuf{PCl(wX=Af|mYQ&IeY_iQg4q zC-;sS#y4x=v@&Pl*WI{W6{vN^l+G0YM{4_T;(q^UB6NSh)czB%$y<-pWh2serD&UE zhVvkHy#ZfxXp^Gmue9NL%5Rx#3F#DS3XqLAPC>M3Q29cM#3cNNHeold^49YF!PJ+! zMx9np2BiasV3{VNunK}v>k{qg(gM_^pYx`#ia&Tja8t`?qG>zXAK<5<<_A}}fLhg0 zkzGD@T|rxRRGuiO13lgm{03lXG6B5R!i``aCEJ?d>zht@4B1ppDnwq)41j%`haIl! ztpN2X3OJzrBmxA~(>?FaqOu6MN%Te$&y9SQ)2NM8txt4hr`7;VZ%j=Z{H?J_7DT5; zZRqeuunbU|qR9HZ(~2Cw5Wc;VxQx3wQs&CzV*z%`HM~sriJ~S8-6RhFxTUubtn@<& zpo}F)EemqAmqa>X2H~^sgYr#2NE_Z8uEL6qgmBAtiRmh z5zN8eIFsXnz^RX8qgVtsAyB&dE#OQuaQKs8R+5_1EO`$7jE5bjv?3Z&`76a>nAY#FgMrzR`d2xfF8d!`G4+r)wio z_S`*M(@}hDYgTT^Lutg7hnj28jc2@`1gTr|?N62gEb1Zv?bJYlFQKpsTnJ3;UVUV@ z_?q>O>;`Oa5@7hU8U=Px^+#8)Jo^DsF0TeEJdnGFKb!pQm!E^-zh#nqI(}Jme>w#% z+l}%O1|}pA%JCOH_Z-)vS+ne7C bUH<(H{v(v~zqqpeGghbn*PcP~WBT6!hXs|9 literal 0 HcmV?d00001 diff --git a/renv/activate.R b/renv/activate.R index 2969c732..ae7b01d3 100644 --- a/renv/activate.R +++ b/renv/activate.R @@ -1034,19 +1034,6 @@ local({ } - - renv_bootstrap_in_rstudio <- function() { - commandArgs()[[1]] == "RStudio" - } - - # Used to work around buglet in RStudio if hook uses readline - renv_bootstrap_flush_console <- function() { - tryCatch({ - tools <- as.environment("tools:rstudio") - tools$.rs.api.sendToConsole("", echo = FALSE, focus = FALSE) - }, error = function(cnd) {}) - } - renv_json_read <- function(file = NULL, text = NULL) { jlerr <- NULL @@ -1185,16 +1172,8 @@ local({ # construct full libpath libpath <- file.path(root, prefix) - if (renv_bootstrap_in_rstudio()) { - # RStudio only updates console once .Rprofile is finished, so - # instead run code on sessionInit - setHook("rstudio.sessionInit", function(...) { - renv_bootstrap_exec(project, libpath, version) - renv_bootstrap_flush_console() - }) - } else { - renv_bootstrap_exec(project, libpath, version) - } + # run bootstrap code + renv_bootstrap_exec(project, libpath, version) invisible() diff --git a/renv/profiles/lesson-requirements/renv.lock b/renv/profiles/lesson-requirements/renv.lock index 03db7225..f6cf4047 100644 --- a/renv/profiles/lesson-requirements/renv.lock +++ b/renv/profiles/lesson-requirements/renv.lock @@ -334,18 +334,14 @@ "Package": "stringi", "Version": "1.7.12", "Source": "Repository", - "Repository": "RSPM", - "RemoteType": "repository", - "RemoteUrl": "https://github.com/gagolews/stringi", - "RemoteRef": "v1.7.12", - "RemoteSha": "e4cf3176bc3943e6c477885be3445cbbd7d4bab6", + "Repository": "CRAN", "Requirements": [ "R", "stats", "tools", "utils" ], - "Hash": "832ef2a01603f8f5b4f2af024080d5d9" + "Hash": "ca8bd84263c77310739d2cf64d84d7c9" }, "stringr": { "Package": "stringr", From 25d953709416f5dcfdd1b5594b6669ae01a1e83d Mon Sep 17 00:00:00 2001 From: Aleksandra Wilczynska Date: Fri, 27 Oct 2023 17:16:44 +0200 Subject: [PATCH 02/38] finalise first episode --- episodes/01-intro-to-r.Rmd | 269 +++- episodes/fig/relative_root.png | Bin 0 -> 22755 bytes renv/profiles/lesson-requirements/renv.lock | 1240 ++++++++++++++++++- 3 files changed, 1388 insertions(+), 121 deletions(-) create mode 100644 episodes/fig/relative_root.png diff --git a/episodes/01-intro-to-r.Rmd b/episodes/01-intro-to-r.Rmd index 678be877..d027a394 100644 --- a/episodes/01-intro-to-r.Rmd +++ b/episodes/01-intro-to-r.Rmd @@ -30,50 +30,49 @@ invisible(lapply(packages, library, character.only = TRUE)) :::::::::::::::::::::::::::::::::::::: questions - How to find your way around RStudio? -- How to manage your environment? +- How to manage projects in R? - How to install packages? - How to interact with R? -- How can I manage my projects in R? :::::::::::::::::::::::::::::::::::::::::::::::: ::::::::::::::::::::::::::::::::::::: objectives -- Describe the purpose and use of each pane in the RStudio IDE -- Locate buttons and options in the RStudio IDE - Create self-contained projects in RStudio +- Install additional packages using R code. +- Manage packages - Define a variable - Assign data to a variable -- Use mathematical and comparison operators - Call functions -- Manage packages + :::::::::::::::::::::::::::::::::::::::::::::::: -## Project management in RStudio +# Project management in RStudio + RStudio is an integrated development environment (IDE), which means -it provides a (much prettier) interface for the R software. For R Studio to work, +it provides a (much prettier) interface for the R software. For RStudio to work, you need to have R installed on your computer. But R is integrated into RStudio, so you never actually have to open R software. -R Studio provides a useful feature: creating projects - +RStudio provides a useful feature: creating projects - self-contained working space (i.e. working directory), to which R will refer to, when looking for and saving files. You can create projects in existing directories (folders) or create a new one. -### Creating RStudio Project +## Creating RStudio Project + We’re going to create a project in RStudio in a new directory. To create a project, go to: - `File` - `New Project` - `New directory` -- Place the project that you will easily find on your laptop and name the - project `data-carpentry` --`Create project` +- Place the project that you will easily find on your laptop and name the project `data-carpentry` +- `Create project` -### Organising working directory +## Organising working directory Creating an RStudio project is a good first step towards good project management. However, most of the time it is a good idea to organize working space further. @@ -82,11 +81,11 @@ Let's go ahead and create the other folders: - `data/` - should be where your raw data is. **READ ONLY** - `data_output/` - should be where your data output is saved **READ AND WRITE** -- `document/s` - all the documentation associated with the project (e.g. cookbook) +- `documents/` - all the documentation associated with the project (e.g. cookbook) - `fig_output/` - your figure outputs go here **WRITE ONLY** - `scripts/` - all your code goes here **READ AND WRITE** -![R project organization](fig/rstudio_project_files.jpeg){alt="R Studio +![R project organization](fig/rstudio_project_files.jpeg){alt="RStudio project logo with five lines, each leading from the logo towards one of the five boxes with texts: 'data/', 'data_output/', 'documents/', 'fig_output/', 'scripts/'"} @@ -97,12 +96,13 @@ R and RStudio offer handy ways to do it directly in your RStudio session. You can use RStudio interface to create a folder in your project by going to lower-bottom pane, files tab, and clicking on Folder icon. -A dialog box will appear, allowing you typing a name of a folder you want to create. +A dialog box will appear, +allowing you typing a name of a folder you want to create. An alternative solution is to create the folders using R command `dir.create()`. -In the console type +In the console type: -```{r} +```{r create-directories} dir.create('data') dir.create('data_output') dir.create('documents') @@ -111,7 +111,6 @@ dir.create('scripts') ``` - :::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: instructor In interest of time, focus on one way of creating the folders. You can showcase @@ -126,12 +125,22 @@ package to read and write objects. :::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: -### Two main ways to interact with R +## Two main ways to interact with R + +There are two main ways to interact with R through RStudio: -There are two main ways to interact with R through RStudio: +- test and play environment within the interactive **R console** +- write and save an **R script (`.R` file)** + +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: callout + +When you open the RStudio or create the Rstudio project, you will see Console +window on the left by default. Once you create an R script, +it is placed in the upper left pane. +The Console is moved to the bottom left pane. + +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: -- Test and play environment within the **interactive R console** -- Write and save an **R script (`.R` file)** Each of the modes o interactions has its advantages and drawbacks. @@ -140,94 +149,220 @@ Each of the modes o interactions has its advantages and drawbacks. |**Pros**|Immediate results|Work lost once you close RStudio | |**Cons**|Complete record of your work |Messy if you just want to print things out| -During the workshop we will mostly use an R Script to have a full documentation -of what has been written. -### Running the code -- In the console: `Enter` -- In the script: - - `Ctrl` + `Enter` (for MAC users: `Command` + `Enter`) - - `Run` button on right left - current line or selection +## Creating a script -### Creating a script -We're going to work with a script. Let's create one now and save it in the `scripts` directory. +During the workshop we will mostly use an `.R` script to have a full documentation +of what has been written. This way we will also be able to reproduce the results. +Let's create one now and save it in the `scripts` directory. - `File` - `New File` - `R Script` -- A new `Untitled` script will appear in the source pane. Save it using floppy disc icon. -- Name it `intro-to-r.R` +- A new `Untitled` script will appear in the source pane. +- Save it using floppy disc icon. +- Select the `scripts/` folder as the file location +- Name the script `intro-to-r.R` - - +## Running the code - +Note that all code written in the script can be also executed at a spot in the +interactive console. +We will now learn how to run the code both in the console and the script. +- In the Console you run the code by hitting Enter + at the end of the line +- In the R script there are two way to execute the code: + + You can use the `Run` button on the top right of the script window. + + Alternatively, you can use a keyboard shortcut: Ctrl + + Enter or Command + Return for MAC users. + +In both cases, the active line (the line where your cursor is placed) or a +highlighted snippet of code will be executed. +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: callout +### Escaping +The console shows it's ready to get new commands with `>` sign. +It will show `+` sign if it still requires input for the command to be executed. +Sometimes you don't know what is missing/ you change your mind and +want to run something else, or your code is running much too long +and you just want it to stop. +The way to do it is to hit Esc. +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: +## Packages +A great power of R lays in **packages: add-on sets of functions** that are build +by the community and once they go through a quality process they are available to +download from a repository called `CRAN`. They need to be explicitly activated. +Now, we will be using `tidyverse` package, +which is actually a collection of useful packages. +Another package that we will use is `here`. +You were asked to install `tidyverse` package in the preparation for the workshop. +You need to install a package only once, so you won't have to do it again. +We will however need to install the `here` package. To do so, please go to your +script and type: +```{r install-here-package, eval=FALSE} +install.packages('here') +``` +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: callout +If you are not sure if you have `tidyverse` packaged installed, you can check it +in the `Packages` tab in the bottom right pane. +In the search box start typing '`tidyverse`' and see if it appears in the list +of installed packages. If not, you will need to install it by writing in +the script: -::::::::::::::::::::::::::::::::::::: challenge +```{r install-tidyverse-package, eval=FALSE} +install.packages('tidyverse') +``` -## Challenge 1: Can you do it? +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: -What is the output of this command? -```r -paste("This", "new", "lesson", "looks", "good") -``` +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: callout + +### Commenting your code + +Now we have a bit of an issue with our script. As mentioned, the packages need to +be installed only once, but now, they will be installed each time we run the script, +which can take a lot of time if we're installing a large package like `tidyverse`. -:::::::::::::::::::::::: solution +To keep a trace of you installing the packages, without executing it, you can use +a comment. In `R`, anything that is written after a has sign `#`, is ignored in +execution. Thanks to this feature, you can annotate your code. +Let's adapt our script by changing the first lines into comments: -## Output +```{r comment} +# install.packages('here') +# install.packages('tidyverse') -```output -[1] "This new lesson looks good" ``` -::::::::::::::::::::::::::::::::: +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: -## Challenge 2: how do you nest solutions within challenge blocks? +Installing packages is not sufficient to work with them. You will need to load +them each time you want to use them. To do that you use `library()` command: -:::::::::::::::::::::::: solution +```{r load-package} +# Load packages +library(tidyverse) +library(here) -You can add a line with at least three colons and a `solution` tag. +``` -::::::::::::::::::::::::::::::::: -:::::::::::::::::::::::::::::::::::::::::::::::: +## Handling paths -## Figures +You have created a project which is your working directory, +and a few sub-folders, that will help you organise your project better. +But now, each time you will save or retrieve a file from those folders, +you will need to specify the path from the folder you are in +(most likely the `scripts/` folder) to those files. -You can include figures generated from R Markdown: +That can become complicated and might cause a reproducibility problem, +if the person using your code (e.g. future you) +is working in a different sub-folder. -```{r pyramid, fig.alt = "pie chart illusion of a pyramid", fig.cap = "Sun arise each and every morning"} -pie( - c(Sky = 78, "Sunny side of pyramid" = 17, "Shady side of pyramid" = 5), - init.angle = 315, - col = c("deepskyblue", "yellow", "yellow3"), - border = FALSE -) + +We will use `here()` package to tackle this issue! This package converts relative +paths from the root (main folder) of your project to absolute paths (the exact +location on your computer). + +It might be confusing, so let's see how it works. We will use the `here` function +from the `here` package. In the console, please write: + +```{r here} +here() +here('data') ``` +You all probably have something different printed out. And this is fine, because +`here` adapts to your computer's specific situation. + + +## Download files + +We still need to download data for the first part of the workshop. +You can do it with the function `download.file()`. +We will save it in the `data/` folder, where the **raw** data should go. +In the script, we will write: + +```{r download-files} +# Download the data +download.file('https://bit.ly/geospatial_data', + here('data','gapminder_data.csv'), mode = 'wb') + +``` + + +# Introduction to R + +You can use R as calculator, you can for example write: + +```{r calculator} +1+100 +1*100 +1/100 + +``` + + +## Variables and assignment + +However, what's more useful is the that in R we can store values and +use them whenever we need to. +We using the assignment operator `<-`, like this: + +```{r asignment-operator} +x <- 1/40 +``` + +Notice that assignment does not print a value. Instead, we've stored it for later +in something called a variable. `x` variable now contains the value `0.025`: +```{r asignment-operator2} +x +``` + +Look for the `Environment` tab in the upper right pane of RStudio. +You will see that `x` and its value have appeared in the list of Values. +Our variable `x` can be used in place of a number in any calculation that expects +a number, e.g. when calculating a square root: + +```{r use-variable} +sqrt(x) +``` + +Variables can be also reassigned. This means that we can assign a new value to +variable `x`: +```{r reassign} +x <- 100 +x +``` + +You can use one variable to create a new one: +```{r reassign2} +y <- sqrt(x) # you can use value stored in object x to create y +y +``` + + ::::::::::::::::::::::::::::::::::::: keypoints -- Use `.md` files for episodes when you want static content -- Use `.Rmd` files for episodes when you need to generate output -- Run `sandpaper::check_lesson()` to identify any issues with your lesson -- Run `sandpaper::build_lesson()` to preview your lesson locally +- Use RStudio to write and run R programs. +- Use `install.packages()` to install packages. +- Use `library()` to load packages. :::::::::::::::::::::::::::::::::::::::::::::::: diff --git a/episodes/fig/relative_root.png b/episodes/fig/relative_root.png new file mode 100644 index 0000000000000000000000000000000000000000..c4abaf517dc5ceb5701f50fe5ce1f695fbd08fa4 GIT binary patch literal 22755 zcmd43c|4Tu+dtlN-)SL5k!(dsBSKlSOuIt3Q^VM%FjRIWgFzdbN)lr!OYTBtERF2T z+}UErQYwyT z$;3#HZ~gZ5D^{%FJ9YBdnH4Kmd&0lnYgfT9zdt=Lw_=6)t5e4gpCx?#(H>|>^s{|G z?>Fj+%Guvol7Fv=a?ko}vSs6$d)BWg$#=tbZ4LIO|F~Pzy!V`~$;-Ej7E~s`?Y>@q zwF};_-;z_bEp27xbsM9$3tZm!c8lf0q25y-_rgz;;3~zdr4uHPYFKIQq?mBxU>UBmH{d3 zlc~QwBwwcxqwq6ki-S1sT@T500qB-`2D_?S{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Wub|9=gl7N% literal 0 HcmV?d00001 diff --git a/renv/profiles/lesson-requirements/renv.lock b/renv/profiles/lesson-requirements/renv.lock index f6cf4047..6fad801f 100644 --- a/renv/profiles/lesson-requirements/renv.lock +++ b/renv/profiles/lesson-requirements/renv.lock @@ -17,6 +17,49 @@ ] }, "Packages": { + "DBI": { + "Package": "DBI", + "Version": "1.1.3", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "methods" + ], + "Hash": "b2866e62bab9378c3cc9476a1954226b" + }, + "MASS": { + "Package": "MASS", + "Version": "7.3-60", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "grDevices", + "graphics", + "methods", + "stats", + "utils" + ], + "Hash": "a56a6365b3fa73293ea8d084be0d9bb0" + }, + "Matrix": { + "Package": "Matrix", + "Version": "1.6-1.1", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "grDevices", + "graphics", + "grid", + "lattice", + "methods", + "stats", + "utils" + ], + "Hash": "1a00d4828f33a9d690806e98bd17150c" + }, "R6": { "Package": "R6", "Version": "2.5.1", @@ -27,6 +70,36 @@ ], "Hash": "470851b6d5d0ac559e9d01bb352b4021" }, + "RColorBrewer": { + "Package": "RColorBrewer", + "Version": "1.1-3", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R" + ], + "Hash": "45f0398006e83a5b10b72a90663d8d8c" + }, + "askpass": { + "Package": "askpass", + "Version": "1.2.0", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "sys" + ], + "Hash": "cad6cf7f1d5f6e906700b9d3e718c796" + }, + "backports": { + "Package": "backports", + "Version": "1.4.1", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R" + ], + "Hash": "c39fbec8a30d23e721980b8afb31984c" + }, "base64enc": { "Package": "base64enc", "Version": "0.1-3", @@ -37,6 +110,63 @@ ], "Hash": "543776ae6848fde2f48ff3816d0628bc" }, + "bit": { + "Package": "bit", + "Version": "4.0.5", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R" + ], + "Hash": "d242abec29412ce988848d0294b208fd" + }, + "bit64": { + "Package": "bit64", + "Version": "4.0.5", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "bit", + "methods", + "stats", + "utils" + ], + "Hash": "9fe98599ca456d6552421db0d6772d8f" + }, + "blob": { + "Package": "blob", + "Version": "1.2.4", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "methods", + "rlang", + "vctrs" + ], + "Hash": "40415719b5a479b87949f3aa0aee737c" + }, + "broom": { + "Package": "broom", + "Version": "1.0.5", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "backports", + "dplyr", + "ellipsis", + "generics", + "glue", + "lifecycle", + "purrr", + "rlang", + "stringr", + "tibble", + "tidyr" + ], + "Hash": "fd25391c3c4f6ecf0fa95f1e6d15378c" + }, "bslib": { "Package": "bslib", "Version": "0.5.1", @@ -68,6 +198,31 @@ ], "Hash": "c35768291560ce302c0a6589f92e837d" }, + "callr": { + "Package": "callr", + "Version": "3.7.3", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "R6", + "processx", + "utils" + ], + "Hash": "9b2191ede20fa29828139b9900922e51" + }, + "cellranger": { + "Package": "cellranger", + "Version": "1.1.0", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "rematch", + "tibble" + ], + "Hash": "f61dbaec772ccd2e17705c1e872e9e7c" + }, "cli": { "Package": "cli", "Version": "3.6.1", @@ -79,6 +234,114 @@ ], "Hash": "89e6d8219950eac806ae0c489052048a" }, + "clipr": { + "Package": "clipr", + "Version": "0.8.0", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "utils" + ], + "Hash": "3f038e5ac7f41d4ac41ce658c85e3042" + }, + "colorspace": { + "Package": "colorspace", + "Version": "2.1-0", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "grDevices", + "graphics", + "methods", + "stats" + ], + "Hash": "f20c47fd52fae58b4e377c37bb8c335b" + }, + "conflicted": { + "Package": "conflicted", + "Version": "1.2.0", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "cli", + "memoise", + "rlang" + ], + "Hash": "bb097fccb22d156624fd07cd2894ddb6" + }, + "cpp11": { + "Package": "cpp11", + "Version": "0.4.6", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R" + ], + "Hash": "707fae4bbf73697ec8d85f9d7076c061" + }, + "crayon": { + "Package": "crayon", + "Version": "1.5.2", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "grDevices", + "methods", + "utils" + ], + "Hash": "e8a1e41acf02548751f45c718d55aa6a" + }, + "curl": { + "Package": "curl", + "Version": "5.0.2", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R" + ], + "Hash": "511bacbfa153a15251166b463b4da4f9" + }, + "data.table": { + "Package": "data.table", + "Version": "1.14.8", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "methods" + ], + "Hash": "b4c06e554f33344e044ccd7fdca750a9" + }, + "dbplyr": { + "Package": "dbplyr", + "Version": "2.3.4", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "DBI", + "R", + "R6", + "blob", + "cli", + "dplyr", + "glue", + "lifecycle", + "magrittr", + "methods", + "pillar", + "purrr", + "rlang", + "tibble", + "tidyr", + "tidyselect", + "utils", + "vctrs", + "withr" + ], + "Hash": "63534894354af6b2587b7aa518a5193a" + }, "digest": { "Package": "digest", "Version": "0.6.33", @@ -90,6 +353,48 @@ ], "Hash": "b18a9cf3c003977b0cc49d5e76ebe48d" }, + "dplyr": { + "Package": "dplyr", + "Version": "1.1.3", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "R6", + "cli", + "generics", + "glue", + "lifecycle", + "magrittr", + "methods", + "pillar", + "rlang", + "tibble", + "tidyselect", + "utils", + "vctrs" + ], + "Hash": "e85ffbebaad5f70e1a2e2ef4302b4949" + }, + "dtplyr": { + "Package": "dtplyr", + "Version": "1.3.1", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "cli", + "data.table", + "dplyr", + "glue", + "lifecycle", + "rlang", + "tibble", + "tidyselect", + "vctrs" + ], + "Hash": "54ed3ea01b11e81a86544faaecfef8e2" + }, "ellipsis": { "Package": "ellipsis", "Version": "0.3.2", @@ -112,6 +417,25 @@ ], "Hash": "d59f3b464e8da1aef82dc04b588b8dfb" }, + "fansi": { + "Package": "fansi", + "Version": "1.0.4", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "grDevices", + "utils" + ], + "Hash": "1d9e7ad3c8312a192dea7d3db0274fde" + }, + "farver": { + "Package": "farver", + "Version": "2.1.1", + "Source": "Repository", + "Repository": "CRAN", + "Hash": "8106d78941f34855c440ddb946b8f7a5" + }, "fastmap": { "Package": "fastmap", "Version": "1.1.1", @@ -131,6 +455,22 @@ ], "Hash": "c2efdd5f0bcd1ea861c2d4e2a883a67d" }, + "forcats": { + "Package": "forcats", + "Version": "1.0.0", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "cli", + "glue", + "lifecycle", + "magrittr", + "rlang", + "tibble" + ], + "Hash": "1a0a9a3d5083d0d573c4214576f1e690" + }, "fs": { "Package": "fs", "Version": "1.6.3", @@ -142,6 +482,64 @@ ], "Hash": "47b5f30c720c23999b913a1a635cf0bb" }, + "gargle": { + "Package": "gargle", + "Version": "1.5.2", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "cli", + "fs", + "glue", + "httr", + "jsonlite", + "lifecycle", + "openssl", + "rappdirs", + "rlang", + "stats", + "utils", + "withr" + ], + "Hash": "fc0b272e5847c58cd5da9b20eedbd026" + }, + "generics": { + "Package": "generics", + "Version": "0.1.3", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "methods" + ], + "Hash": "15e9634c0fcd294799e9b2e929ed1b86" + }, + "ggplot2": { + "Package": "ggplot2", + "Version": "3.4.3", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "MASS", + "R", + "cli", + "glue", + "grDevices", + "grid", + "gtable", + "isoband", + "lifecycle", + "mgcv", + "rlang", + "scales", + "stats", + "tibble", + "vctrs", + "withr" + ], + "Hash": "85846544c596e71f8f46483ab165da33" + }, "glue": { "Package": "glue", "Version": "1.6.2", @@ -153,6 +551,105 @@ ], "Hash": "4f2596dfb05dac67b9dc558e5c6fba2e" }, + "googledrive": { + "Package": "googledrive", + "Version": "2.1.1", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "cli", + "gargle", + "glue", + "httr", + "jsonlite", + "lifecycle", + "magrittr", + "pillar", + "purrr", + "rlang", + "tibble", + "utils", + "uuid", + "vctrs", + "withr" + ], + "Hash": "e99641edef03e2a5e87f0a0b1fcc97f4" + }, + "googlesheets4": { + "Package": "googlesheets4", + "Version": "1.1.1", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "cellranger", + "cli", + "curl", + "gargle", + "glue", + "googledrive", + "httr", + "ids", + "lifecycle", + "magrittr", + "methods", + "purrr", + "rematch2", + "rlang", + "tibble", + "utils", + "vctrs", + "withr" + ], + "Hash": "d6db1667059d027da730decdc214b959" + }, + "gtable": { + "Package": "gtable", + "Version": "0.3.4", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "cli", + "glue", + "grid", + "lifecycle", + "rlang" + ], + "Hash": "b29cf3031f49b04ab9c852c912547eef" + }, + "haven": { + "Package": "haven", + "Version": "2.5.3", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "cli", + "cpp11", + "forcats", + "hms", + "lifecycle", + "methods", + "readr", + "rlang", + "tibble", + "tidyselect", + "vctrs" + ], + "Hash": "9b302fe352f9cfc5dcf0a4139af3a565" + }, + "here": { + "Package": "here", + "Version": "1.0.1", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "rprojroot" + ], + "Hash": "24b224366f9c2e7534d2344d10d59211" + }, "highr": { "Package": "highr", "Version": "0.10", @@ -164,6 +661,20 @@ ], "Hash": "06230136b2d2b9ba5805e1963fa6e890" }, + "hms": { + "Package": "hms", + "Version": "1.1.3", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "lifecycle", + "methods", + "pkgconfig", + "rlang", + "vctrs" + ], + "Hash": "b59377caa7ed00fa41808342002138f9" + }, "htmltools": { "Package": "htmltools", "Version": "0.5.6", @@ -179,97 +690,398 @@ "rlang", "utils" ], - "Hash": "a2326a66919a3311f7fbb1e3bf568283" + "Hash": "a2326a66919a3311f7fbb1e3bf568283" + }, + "httr": { + "Package": "httr", + "Version": "1.4.7", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "R6", + "curl", + "jsonlite", + "mime", + "openssl" + ], + "Hash": "ac107251d9d9fd72f0ca8049988f1d7f" + }, + "ids": { + "Package": "ids", + "Version": "1.0.1", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "openssl", + "uuid" + ], + "Hash": "99df65cfef20e525ed38c3d2577f7190" + }, + "isoband": { + "Package": "isoband", + "Version": "0.2.7", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "grid", + "utils" + ], + "Hash": "0080607b4a1a7b28979aecef976d8bc2" + }, + "jquerylib": { + "Package": "jquerylib", + "Version": "0.1.4", + "Source": "Repository", + "Repository": "RSPM", + "Requirements": [ + "htmltools" + ], + "Hash": "5aab57a3bd297eee1c1d862735972182" + }, + "jsonlite": { + "Package": "jsonlite", + "Version": "1.8.7", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "methods" + ], + "Hash": "266a20443ca13c65688b2116d5220f76" + }, + "knitr": { + "Package": "knitr", + "Version": "1.43", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "evaluate", + "highr", + "methods", + "tools", + "xfun", + "yaml" + ], + "Hash": "9775eb076713f627c07ce41d8199d8f6" + }, + "labeling": { + "Package": "labeling", + "Version": "0.4.3", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "graphics", + "stats" + ], + "Hash": "b64ec208ac5bc1852b285f665d6368b3" + }, + "lattice": { + "Package": "lattice", + "Version": "0.21-8", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "grDevices", + "graphics", + "grid", + "stats", + "utils" + ], + "Hash": "0b8a6d63c8770f02a8b5635f3c431e6b" + }, + "lifecycle": { + "Package": "lifecycle", + "Version": "1.0.3", + "Source": "Repository", + "Repository": "RSPM", + "Requirements": [ + "R", + "cli", + "glue", + "rlang" + ], + "Hash": "001cecbeac1cff9301bdc3775ee46a86" + }, + "lubridate": { + "Package": "lubridate", + "Version": "1.9.3", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "generics", + "methods", + "timechange" + ], + "Hash": "680ad542fbcf801442c83a6ac5a2126c" + }, + "magrittr": { + "Package": "magrittr", + "Version": "2.0.3", + "Source": "Repository", + "Repository": "RSPM", + "Requirements": [ + "R" + ], + "Hash": "7ce2733a9826b3aeb1775d56fd305472" + }, + "memoise": { + "Package": "memoise", + "Version": "2.0.1", + "Source": "Repository", + "Repository": "RSPM", + "Requirements": [ + "cachem", + "rlang" + ], + "Hash": "e2817ccf4a065c5d9d7f2cfbe7c1d78c" + }, + "mgcv": { + "Package": "mgcv", + "Version": "1.8-42", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "Matrix", + "R", + "graphics", + "methods", + "nlme", + "splines", + "stats", + "utils" + ], + "Hash": "3460beba7ccc8946249ba35327ba902a" + }, + "mime": { + "Package": "mime", + "Version": "0.12", + "Source": "Repository", + "Repository": "RSPM", + "Requirements": [ + "tools" + ], + "Hash": "18e9c28c1d3ca1560ce30658b22ce104" + }, + "modelr": { + "Package": "modelr", + "Version": "0.1.11", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "broom", + "magrittr", + "purrr", + "rlang", + "tibble", + "tidyr", + "tidyselect", + "vctrs" + ], + "Hash": "4f50122dc256b1b6996a4703fecea821" + }, + "munsell": { + "Package": "munsell", + "Version": "0.5.0", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "colorspace", + "methods" + ], + "Hash": "6dfe8bf774944bd5595785e3229d8771" + }, + "nlme": { + "Package": "nlme", + "Version": "3.1-162", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "graphics", + "lattice", + "stats", + "utils" + ], + "Hash": "0984ce8da8da9ead8643c5cbbb60f83e" + }, + "openssl": { + "Package": "openssl", + "Version": "2.1.1", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "askpass" + ], + "Hash": "2a0dc8c6adfb6f032e4d4af82d258ab5" + }, + "pillar": { + "Package": "pillar", + "Version": "1.9.0", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "cli", + "fansi", + "glue", + "lifecycle", + "rlang", + "utf8", + "utils", + "vctrs" + ], + "Hash": "15da5a8412f317beeee6175fbc76f4bb" + }, + "pkgconfig": { + "Package": "pkgconfig", + "Version": "2.0.3", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "utils" + ], + "Hash": "01f28d4278f15c76cddbea05899c5d6f" + }, + "prettyunits": { + "Package": "prettyunits", + "Version": "1.2.0", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R" + ], + "Hash": "6b01fc98b1e86c4f705ce9dcfd2f57c7" + }, + "processx": { + "Package": "processx", + "Version": "3.8.2", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "R6", + "ps", + "utils" + ], + "Hash": "3efbd8ac1be0296a46c55387aeace0f3" }, - "jquerylib": { - "Package": "jquerylib", - "Version": "0.1.4", + "progress": { + "Package": "progress", + "Version": "1.2.2", "Source": "Repository", - "Repository": "RSPM", + "Repository": "CRAN", "Requirements": [ - "htmltools" + "R6", + "crayon", + "hms", + "prettyunits" ], - "Hash": "5aab57a3bd297eee1c1d862735972182" + "Hash": "14dc9f7a3c91ebb14ec5bb9208a07061" }, - "jsonlite": { - "Package": "jsonlite", - "Version": "1.8.7", + "ps": { + "Package": "ps", + "Version": "1.7.5", "Source": "Repository", "Repository": "CRAN", "Requirements": [ - "methods" + "R", + "utils" ], - "Hash": "266a20443ca13c65688b2116d5220f76" + "Hash": "709d852d33178db54b17c722e5b1e594" }, - "knitr": { - "Package": "knitr", - "Version": "1.43", + "purrr": { + "Package": "purrr", + "Version": "1.0.2", "Source": "Repository", "Repository": "CRAN", "Requirements": [ "R", - "evaluate", - "highr", - "methods", - "tools", - "xfun", - "yaml" + "cli", + "lifecycle", + "magrittr", + "rlang", + "vctrs" ], - "Hash": "9775eb076713f627c07ce41d8199d8f6" + "Hash": "1cba04a4e9414bdefc9dcaa99649a8dc" }, - "lifecycle": { - "Package": "lifecycle", - "Version": "1.0.3", + "ragg": { + "Package": "ragg", + "Version": "1.2.5", "Source": "Repository", - "Repository": "RSPM", + "Repository": "CRAN", "Requirements": [ - "R", - "cli", - "glue", - "rlang" + "systemfonts", + "textshaping" ], - "Hash": "001cecbeac1cff9301bdc3775ee46a86" + "Hash": "690bc058ea2b1b8a407d3cfe3dce3ef9" }, - "magrittr": { - "Package": "magrittr", - "Version": "2.0.3", + "rappdirs": { + "Package": "rappdirs", + "Version": "0.3.3", "Source": "Repository", "Repository": "RSPM", "Requirements": [ "R" ], - "Hash": "7ce2733a9826b3aeb1775d56fd305472" + "Hash": "5e3c5dc0b071b21fa128676560dbe94d" }, - "memoise": { - "Package": "memoise", - "Version": "2.0.1", + "readr": { + "Package": "readr", + "Version": "2.1.4", "Source": "Repository", - "Repository": "RSPM", + "Repository": "CRAN", "Requirements": [ - "cachem", - "rlang" + "R", + "R6", + "cli", + "clipr", + "cpp11", + "crayon", + "hms", + "lifecycle", + "methods", + "rlang", + "tibble", + "tzdb", + "utils", + "vroom" ], - "Hash": "e2817ccf4a065c5d9d7f2cfbe7c1d78c" + "Hash": "b5047343b3825f37ad9d3b5d89aa1078" }, - "mime": { - "Package": "mime", - "Version": "0.12", + "readxl": { + "Package": "readxl", + "Version": "1.4.3", "Source": "Repository", - "Repository": "RSPM", + "Repository": "CRAN", "Requirements": [ - "tools" + "R", + "cellranger", + "cpp11", + "progress", + "tibble", + "utils" ], - "Hash": "18e9c28c1d3ca1560ce30658b22ce104" + "Hash": "8cf9c239b96df1bbb133b74aef77ad0a" }, - "rappdirs": { - "Package": "rappdirs", - "Version": "0.3.3", + "rematch": { + "Package": "rematch", + "Version": "2.0.0", "Source": "Repository", - "Repository": "RSPM", + "Repository": "CRAN", + "Hash": "cbff1b666c6fa6d21202f07e2318d4f1" + }, + "rematch2": { + "Package": "rematch2", + "Version": "2.1.2", + "Source": "Repository", + "Repository": "CRAN", "Requirements": [ - "R" + "tibble" ], - "Hash": "5e3c5dc0b071b21fa128676560dbe94d" + "Hash": "76c9e04c712a05848ae7a23d2f170a40" }, "renv": { "Package": "renv", @@ -281,6 +1093,28 @@ ], "Hash": "4b22ac016fe54028b88d0c68badbd061" }, + "reprex": { + "Package": "reprex", + "Version": "2.0.2", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "callr", + "cli", + "clipr", + "fs", + "glue", + "knitr", + "lifecycle", + "rlang", + "rmarkdown", + "rstudioapi", + "utils", + "withr" + ], + "Hash": "d66fe009d4c20b7ab1927eb405db9ee2" + }, "rlang": { "Package": "rlang", "Version": "1.1.1", @@ -316,6 +1150,43 @@ ], "Hash": "3854c37590717c08c32ec8542a2e0a35" }, + "rprojroot": { + "Package": "rprojroot", + "Version": "2.0.3", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R" + ], + "Hash": "1de7ab598047a87bba48434ba35d497d" + }, + "rstudioapi": { + "Package": "rstudioapi", + "Version": "0.15.0", + "Source": "Repository", + "Repository": "CRAN", + "Hash": "5564500e25cffad9e22244ced1379887" + }, + "rvest": { + "Package": "rvest", + "Version": "1.0.3", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "cli", + "glue", + "httr", + "lifecycle", + "magrittr", + "rlang", + "selectr", + "tibble", + "withr", + "xml2" + ], + "Hash": "a4a5ac819a467808c60e36e92ddf195e" + }, "sass": { "Package": "sass", "Version": "0.4.7", @@ -330,6 +1201,37 @@ ], "Hash": "6bd4d33b50ff927191ec9acbf52fd056" }, + "scales": { + "Package": "scales", + "Version": "1.2.1", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "R6", + "RColorBrewer", + "farver", + "labeling", + "lifecycle", + "munsell", + "rlang", + "viridisLite" + ], + "Hash": "906cb23d2f1c5680b8ce439b44c6fa63" + }, + "selectr": { + "Package": "selectr", + "Version": "0.4-2", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "R6", + "methods", + "stringr" + ], + "Hash": "3838071b66e0c566d55cc26bd6e27bf4" + }, "stringi": { "Package": "stringi", "Version": "1.7.12", @@ -360,6 +1262,145 @@ ], "Hash": "671a4d384ae9d32fc47a14e98bfa3dc8" }, + "sys": { + "Package": "sys", + "Version": "3.4.2", + "Source": "Repository", + "Repository": "CRAN", + "Hash": "3a1be13d68d47a8cd0bfd74739ca1555" + }, + "systemfonts": { + "Package": "systemfonts", + "Version": "1.0.4", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "cpp11" + ], + "Hash": "90b28393209827327de889f49935140a" + }, + "textshaping": { + "Package": "textshaping", + "Version": "0.3.6", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "cpp11", + "systemfonts" + ], + "Hash": "1ab6223d3670fac7143202cb6a2d43d5" + }, + "tibble": { + "Package": "tibble", + "Version": "3.2.1", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "fansi", + "lifecycle", + "magrittr", + "methods", + "pillar", + "pkgconfig", + "rlang", + "utils", + "vctrs" + ], + "Hash": "a84e2cc86d07289b3b6f5069df7a004c" + }, + "tidyr": { + "Package": "tidyr", + "Version": "1.3.0", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "cli", + "cpp11", + "dplyr", + "glue", + "lifecycle", + "magrittr", + "purrr", + "rlang", + "stringr", + "tibble", + "tidyselect", + "utils", + "vctrs" + ], + "Hash": "e47debdc7ce599b070c8e78e8ac0cfcf" + }, + "tidyselect": { + "Package": "tidyselect", + "Version": "1.2.0", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "cli", + "glue", + "lifecycle", + "rlang", + "vctrs", + "withr" + ], + "Hash": "79540e5fcd9e0435af547d885f184fd5" + }, + "tidyverse": { + "Package": "tidyverse", + "Version": "2.0.0", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "broom", + "cli", + "conflicted", + "dbplyr", + "dplyr", + "dtplyr", + "forcats", + "ggplot2", + "googledrive", + "googlesheets4", + "haven", + "hms", + "httr", + "jsonlite", + "lubridate", + "magrittr", + "modelr", + "pillar", + "purrr", + "ragg", + "readr", + "readxl", + "reprex", + "rlang", + "rstudioapi", + "rvest", + "stringr", + "tibble", + "tidyr", + "xml2" + ], + "Hash": "c328568cd14ea89a83bd4ca7f54ae07e" + }, + "timechange": { + "Package": "timechange", + "Version": "0.2.0", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "cpp11" + ], + "Hash": "8548b44f79a35ba1791308b61e6012d7" + }, "tinytex": { "Package": "tinytex", "Version": "0.46", @@ -370,6 +1411,37 @@ ], "Hash": "0c41a73214d982f539c56a7773c7afa5" }, + "tzdb": { + "Package": "tzdb", + "Version": "0.4.0", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "cpp11" + ], + "Hash": "f561504ec2897f4d46f0c7657e488ae1" + }, + "utf8": { + "Package": "utf8", + "Version": "1.2.3", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R" + ], + "Hash": "1fe17157424bb09c48a8b3b550c753bc" + }, + "uuid": { + "Package": "uuid", + "Version": "1.1-1", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R" + ], + "Hash": "3d78edfb977a69fc7a0341bee25e163f" + }, "vctrs": { "Package": "vctrs", "Version": "0.6.3", @@ -384,6 +1456,55 @@ ], "Hash": "d0ef2856b83dc33ea6e255caf6229ee2" }, + "viridisLite": { + "Package": "viridisLite", + "Version": "0.4.2", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R" + ], + "Hash": "c826c7c4241b6fc89ff55aaea3fa7491" + }, + "vroom": { + "Package": "vroom", + "Version": "1.6.3", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "bit64", + "cli", + "cpp11", + "crayon", + "glue", + "hms", + "lifecycle", + "methods", + "progress", + "rlang", + "stats", + "tibble", + "tidyselect", + "tzdb", + "vctrs", + "withr" + ], + "Hash": "8318e64ffb3a70e652494017ec455561" + }, + "withr": { + "Package": "withr", + "Version": "2.5.1", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "grDevices", + "graphics", + "stats" + ], + "Hash": "d77c6f74be05c33164e33fbc85540cae" + }, "xfun": { "Package": "xfun", "Version": "0.40", @@ -395,6 +1516,17 @@ ], "Hash": "be07d23211245fc7d4209f54c4e4ffc8" }, + "xml2": { + "Package": "xml2", + "Version": "1.3.5", + "Source": "Repository", + "Repository": "CRAN", + "Requirements": [ + "R", + "methods" + ], + "Hash": "6c40e5cfcc6aefd88110666e18c31f40" + }, "yaml": { "Package": "yaml", "Version": "2.3.7", From 6236b8e4efdf4e392b76f82af2b23f40a5e7c286 Mon Sep 17 00:00:00 2001 From: Aleksandra Wilczynska Date: Tue, 31 Oct 2023 16:24:49 +0100 Subject: [PATCH 03/38] create episode 2 - data structures --- config.yaml | 2 + episodes/01-intro-to-r.Rmd | 1 - episodes/02-data-structures.Rmd | 216 +++++++++++++++++++++ episodes/03-explore-data.Rmd | 327 ++++++++++++++++++++++++++++++++ 4 files changed, 545 insertions(+), 1 deletion(-) create mode 100644 episodes/02-data-structures.Rmd create mode 100644 episodes/03-explore-data.Rmd diff --git a/config.yaml b/config.yaml index 02d81483..08ad0d8a 100644 --- a/config.yaml +++ b/config.yaml @@ -61,6 +61,8 @@ contact: 'team@carpentries.org' episodes: - introduction.Rmd - 01-intro-to-r.Rmd +- 02-data-structures.Rmd +- 03-explore-data.Rmd # Information for Learners learners: diff --git a/episodes/01-intro-to-r.Rmd b/episodes/01-intro-to-r.Rmd index d027a394..e7e85201 100644 --- a/episodes/01-intro-to-r.Rmd +++ b/episodes/01-intro-to-r.Rmd @@ -357,7 +357,6 @@ y - ::::::::::::::::::::::::::::::::::::: keypoints - Use RStudio to write and run R programs. diff --git a/episodes/02-data-structures.Rmd b/episodes/02-data-structures.Rmd new file mode 100644 index 00000000..f9fef7e6 --- /dev/null +++ b/episodes/02-data-structures.Rmd @@ -0,0 +1,216 @@ +--- +title: 'Data Structures' +teaching: 10 +exercises: 2 +--- + +:::::::::::::::::::::::::::::::::::::: questions + +- What are the basic data types in R? +- How do I represent categorical information in R? + +:::::::::::::::::::::::::::::::::::::::::::::::: + +::::::::::::::::::::::::::::::::::::: objectives + +- To be aware of the different types of data. +- To begin exploring data frames, and understand how they are related to vectors, factors and lists. +- To be able to ask questions from R about the type, class, and structure of an object. + +:::::::::::::::::::::::::::::::::::::::::::::::: + +## Vectors +So far we've looked on individual values. Now we will move to a data structure +called vectors. Vectors are arrays of values of a same data type. + +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: callout + +### Data types + +Data type refers to a type of information that is stored by a value. +It can be: + +- `numerical` (a number) +- `integer` (a number without information about decimal points) +- `logical` (a boolean - are values TRUE or FALSE?) +- `character` (a text/ string of characters) +- `complex` (a complex number) +- `raw` (raw bytes) + +We won't discuss `complex` or `raw` data type in the workshop. + +::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: + +You can create a vector with a `c()` function. + +```{r vectors} + +numeric_vector <- c(2, 6, 3) # vector of numbers - numeric data type. +numeric_vector + +character_vector <- c('banana', 'apple', 'orange') # vector of words - or strings of characters- character data type +character_vector + +logical_vector <- c(TRUE, FALSE, TRUE) # vector of logical values (is something true or false?)- logical data type. +logical_vector + +``` + +### Combining vectors + +The combine function, `c()`, will also append things to an existing vector: + +```{r combine-vectors} + +ab_vector <- c('a', 'b') +ab_vector + +abcd_vector <- c(ab_vector, 'c', 'd') +abcd_vector + +``` + +### Missing values + +A common operation you want to perform is to remove all the missing values +(in R denoted as `NA`). Let's have a look how to do it: + +```{r remove-na} +with_na <- c(1, 2, 1, 1, NA, 3, NA ) # vector including missing value +``` + +First, let's try to calculate mean for the values in this vector +```{r remove-na1} +mean(with_na) # mean() function cannot interpret the missing values + +mean(with_na, na.rm = T) # You can add the argument na.rm=TRUE to calculate the result while ignoring the missing values. +``` + +However, sometimes, you would like to have the `NA` +permanently removed from your vector. +For this you need to identify which elements of the vector hold missing values +with `is.na()` function. + +```{r remove-na2} +is.na(with_na) # This will produce a vector of logical values, stating if a statement 'This element of the vector is a missing value' is true or not + +!is.na(with_na) # # The ! operator means negation ,i.e. not is.na(with_na) + +``` + +We know which elements in the vectors are `NA`. +Now we need to retrieve the subset of the `with_na` vector that is not `NA`. +Sub-setting in `R` is done with square brackets`[ ]`. + +```{r remove-na3} + +without_na <- with_na[ !is.na(with_na) ] # this notation will return only the elements that have TRUE on their respective positions + +without_na + +``` + + +## Factors + +Another important data structure is called a **factor**. +Factors look like character data, but are used to represent categorical information. + +Factors create a structured relation between the different levels (values) of a +categorical variable, such as days of the week or responses to a question in a +survey. While factors look (and often behave) like character vectors, they are +actually treated as numbers by `R`. +So you need to be very careful when treating them as strings. + +### Create factors +Once created, factors can only contain a pre-defined set of values, +known as levels. + +```{r factor-create} + +nordic_str <- c('Norway', 'Sweden', 'Norway', 'Denmark', 'Sweden') +nordic_str # regular character vectors printed out + +nordic_cat <- factor(nordic_str) # factor() function converts a vector to factor data type +nordic_cat # With factors, R prints out additional information - 'Levels' + +``` + +### Inspect factors +R will treat each unique value from a factor vector as a **level** and (silently) +assign numerical values to it. +This can come in handy when performing statistical analysis. +You can inspect and adapt levels of the factor. + +```{r factor-inspect} +levels(nordic_cat) # returns all levels of a factor vector. + +nlevels(nordic_cat) # returns number of levels in a vector +``` + +### Reorder levels +Note that `R` sorts the levels in the alphabetic order, +not in the order of occurrence in the vector. `R` assigns value of: + +- 1 to level 'Denmark', +- 2 to 'Norway' +- 3 to 'Sweden'. + +This is important as it can affect e.g. the order in which categories are +displayed in a plot or which category is taken as a baseline in a statistical model. + +You can reorder the categories using `factor()` function. + +```{r factor-reorder} +nordic_cat <- factor(nordic_cat, levels = c('Norway' , 'Denmark', 'Sweden')) # now Norway should be the first category, Denmark second and Sweden third + +nordic_cat +``` + + +:::::::::::::::::::::::::::::::::::::::::::::::::::::: callout +There is more than one way to reorder factors. Later in the lesson, +we will use `fct_relevel()` function from `forcats` package to do the reordering. + +```{r factor-reorder} +# nordic_cat <- fct_relevel(nordic_cat, 'Norway' , 'Denmark', 'Sweden') # now Norway should be the first category, Denmark second and Sweden third + +nordic_cat +``` +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: + + +You can also inspect vectors with `str()` function. In factor vectors, +it shows the underlying values of each category. +You can also see the structure in the environment tab of RStudio. + +```{r factor-reorder} +str(nordic_cat) +``` + +:::::::::::::::::::::::::::::::::::::::::::::::::::: callout + +### Note of caution + +Remember that once created, factors can only contain a pre-defined set of values, +known as levels. It means that whenever you try to add something to the factor +outside of this set, it will become an unknown/missing value detonated by +`R` as `NA`. + + +```{r factor-missing-level} +nordic_str +nordic_cat2 <- factor(nordic_str, levels = c('Norway', 'Denmark')) +nordic_cat2 # since we have not included Sweden in the list of factor levels, it has become NA. +``` +:::::::::::::::::::::::::::::::::::::::::::::::::::: + + + +::::::::::::::::::::::::::::::::::::: keypoints + +- The mostly used basic data types in R are `numeric`, `integer`, `logical`, and `character` +- Use factors to represent categories in R. + +:::::::::::::::::::::::::::::::::::::::::::::::: + diff --git a/episodes/03-explore-data.Rmd b/episodes/03-explore-data.Rmd new file mode 100644 index 00000000..643fb750 --- /dev/null +++ b/episodes/03-explore-data.Rmd @@ -0,0 +1,327 @@ +--- +title: 'Exploring Data Frames & Data frame Manipulation with dplyr ' +teaching: 10 +exercises: 2 +--- + +:::::::::::::::::::::::::::::::::::::: questions + +- What is a data frame? +- How can I read data in R? +- How can I get basic summary information about my data set? +- How can I select specific rows and/or columns from a data frame? +- How can I combine multiple commands into a single command? +- How can I create new columns or remove existing columns from a data frame? + +:::::::::::::::::::::::::::::::::::::::::::::::: + +::::::::::::::::::::::::::::::::::::: objectives + +- Describe what a data frame is. +- Load external data from a .csv file into a data frame. +- Summarize the contents of a data frame. +- Select certain columns in a data frame with the dplyr function select. +- Select certain rows in a data frame according to filtering conditions with the dplyr function filter. +- Link the output of one dplyr function to the input of another function with the ‘pipe’ operator %>%. +- Add new columns to a data frame that are functions of existing columns with mutate. +- Use the split-apply-combine concept for data analysis. +- Use summarize, group_by, and count to split a data frame into groups of observations, apply a summary statistics for each group, and then combine the results. + +:::::::::::::::::::::::::::::::::::::::::::::::: + + +# [Exploring Data frames](https://datacarpentry.org/r-intro-geospatial/04-data-structures-part2/index.html) + +Now we turn to the bread-and-butter of working with `R`: working with tabular data. In `R` data are stored in a data structure called **data frames**. + +A data frame is a representation of data in the format of a **table** where the columns are **vectors** that all have the **same length**. + + +Because columns are vectors, each column must contain a **single type of data** (e.g., characters, numeric, factors). +For example, here is a figure depicting a data frame comprising a numeric, a character, and a logical vector. + +![](assets/img/data-frame.svg) +*Source*:[Data Carpentry R for Social Scientists ](https://datacarpentry.org/r-socialsci/02-starting-with-data/index.html#what-are-data-frames-and-tibbles) + + +## Reading data + +`read.csv()` is a function used to read coma separated data files (`.csv` format)). There are other functions for files separated with other delimiters. +We're gonna read in the `gapminder` data set with information about countries' size, GDP and average life expectancy in different years. + +```{r reading-data} +gapminder <- read.csv(here('data','gapminder_data.csv') ) + +``` + +## Exploring dataset +Let’s investigate the `gapminder` data frame a bit; the first thing we should always do is check out what the data looks like. + +It is important to see if all the variables (columns) have the data type that we require. Otherwise we can run into trouble. + +```{r inspecting-data-str} +str(gapminder) + +``` + +We can see that the `gapminder` object is a data.frame with `r nrow(gapminder)` observations/ rows and `r ncol(gapminder)` variables/columns. +In each line after a `$` sign, we see the name of each column, its type and first few values. + + +### First look at the dataset +There are multiple ways to explore a data set. Here are just a few examples: + + +```{r} +head(gapminder) # see first 5 rows of the data set + +summary(gapminder) # gives basic statistical information about each column. Information format differes by data type. + +nrow(gapminder) # returns number of rows in a dataset + +ncol(gapminder) # returns number of columns in a dataset + +``` + +### Dollar sign ($) + +When you're analyzing a data set, you often need to access its specific columns. + +One handy way to access a column is using it's name and a dollar sign `$`: +```{r subset-dollar-sign} +country_vec <- gapminder$country # Notation means: From dataset gapminder, give me column country. You can see that the column accessed in this way is just a vector of characters. + +head(country_vec) + +``` +Note that the calling a column with a `$` sign will return a *vector*, it's not a data frame anymore. + + +# [Data frame Manipulation with dplyr](https://datacarpentry.org/r-intro-geospatial/06-dplyr/index.html) + +## Select +Let's start manipulating the data. + +First, we will adapt our data set, by keeping only the columns we're interested in, using the `select()` function from the `dplyr` package: + +```{r dplyr-select} +year_country_gdp <- select(gapminder, year, country, gdpPercap) + +head(year_country_gdp) + +``` + +## Pipe +Now, this is not the most common notation when working with `dplyr` package. `dplyr` offers an operator `%>%` called a pipe, which allows you build up very complicated commands in a readable way. + + +In newer installation of `R` you can also find a notation `|>` . This pipe works in a similar way. The main difference is that you don't need to load any packages to have it available. + + +The `select()` statement with pipe would look like that: + +```{r dplyr-pipe} + +year_country_gdp <- gapminder %>% + select(year,country,gdpPercap) + +head(year_country_gdp) + +``` + +First we define data set, then - with the use of pipe we pass it on to the `select()` function. This way we can chain multiple functions together, which we will be doing now. + +## Filter + +We already now how to select only the needed columns. But now, we also want to filter the data set via certain condition with `filter()` function. Instead doing it in separate steps, we can do it all together. + +In the `gapminder` data set, we want to see the results from outside of Europe for the 21st century. +```{r} +year_country_gdp_euro <- gapminder %>% + filter(continent != "Europe" & year > 2000) %>% # & operator (AND) - both conditions must be met + select(year, country, gdpPercap) + +head(year_country_gdp_euro) +``` +Let's now find all the observations from Eurasia: + +```{r} +year_country_gdp_eurasia <- gapminder %>% + filter(continent == "Europe" | continent == "Asia") %>% # I operator (OR) - one of the conditions must be met + select(year, country, gdpPercap) + +head(year_country_gdp_eurasia) +``` + +### Exercise 1 + +
+Challenge +Write a single command (which can span multiple lines and includes pipes) that will produce a dataframe that has the African values for life expectancy, country and year, but not for other Continents. How many rows does your data frame have and why? + + +Solution + +
+ + +```{r ex5, class.source="bg-info"} +year_country_lifeExp_Africa <- gapminder %>% + filter(continent=="Africa" ) %>% + select(year,country,lifeExp) + + +nrow(year_country_lifeExp_Africa) +``` + + + +## Group and summarize +So far, we have created a data frame for one of the continents represented in the `gapminder` data set. But often instead of doing that, we would like to know statistics about all of the continents, presented by group. + +```{r dplyr-group} +gapminder %>% # select the dataset + group_by(continent) %>% # group by continent + summarize(avg_gdpPercap = mean(gdpPercap)) # summarize function creates statistics for the data set + +``` + +### Exercise 2 +
+Challenge +Calculate the average life expectancy per country. Which country has the longest average life expectancy and which has the shortest average life expectancy? + +Hint Use `max()` and `min()` functions to find minimum and maximum. + +Solution + +
+ + +```{r ex6 , class.source="bg-info"} +lifeExp_bycountry <- gapminder %>% + group_by(country) %>% + summarize(avg_lifeExp=mean(lifeExp)) + + +lifeExp_bycountry %>% + filter(avg_lifeExp == min(avg_lifeExp) | avg_lifeExp == max(avg_lifeExp)) +``` + +### Multiple groups and summary variables +You can also group by multiple columns: + +```{r dplyr-group-multi} + +gapminder %>% + group_by(continent, year) %>% + summarize(avg_gdpPercap = mean(gdpPercap)) + +``` + +On top of this, you can also make multiple summaries of those groups: +```{r dplyr-summ} +gdp_pop_bycontinents_byyear <- gapminder %>% + group_by(continent,year) %>% + summarize( + avg_gdpPercap = mean(gdpPercap), + sd_gdpPercap = sd(gdpPercap), + avg_pop = mean(pop), + sd_pop = sd(pop), + n_obs = n() + ) + +``` + +## Frequencies + +If you need only a number of observations per group, you can use the `count()` function +```{r dplyr-count} + +gapminder %>% + group_by(continent) %>% + count() +``` + + +## Mutate + +Frequently you’ll want to create new columns based on the values in existing columns, for example to do unit conversions, or to find the ratio of values in two columns. For this we’ll use `mutate()`. + +```{r dplyr-mutate} +gapminder_gdp <- gapminder %>% + mutate(gdpBillion = gdpPercap*pop/10^9) + +head(gapminder_gdp) + +``` + + + +::::::::::::::::::::::::::::::::::::: challenge + +## Challenge 1: Can you do it? + +What is the output of this command? + +```r +paste("This", "new", "lesson", "looks", "good") +``` + +:::::::::::::::::::::::: solution + +## Output + +```output +[1] "This new lesson looks good" +``` + +::::::::::::::::::::::::::::::::: + + +## Challenge 2: how do you nest solutions within challenge blocks? + +:::::::::::::::::::::::: solution + +You can add a line with at least three colons and a `solution` tag. + +::::::::::::::::::::::::::::::::: +:::::::::::::::::::::::::::::::::::::::::::::::: + +## Figures + +You can include figures generated from R Markdown: + +```{r pyramid, fig.alt = "pie chart illusion of a pyramid", fig.cap = "Sun arise each and every morning"} +pie( + c(Sky = 78, "Sunny side of pyramid" = 17, "Shady side of pyramid" = 5), + init.angle = 315, + col = c("deepskyblue", "yellow", "yellow3"), + border = FALSE +) +``` +Or you can use pandoc markdown for static figures with the following syntax: + +`![optional caption that appears below the figure](figure url){alt='alt text for +accessibility purposes'}` + +![You belong in The Carpentries!](https://raw.githubusercontent.com/carpentries/logo/master/Badge_Carpentries.svg){alt='Blue Carpentries hex person logo with no text.'} + +## Math + +One of our episodes contains $\LaTeX$ equations when describing how to create +dynamic reports with {knitr}, so we now use mathjax to describe this: + +`$\alpha = \dfrac{1}{(1 - \beta)^2}$` becomes: $\alpha = \dfrac{1}{(1 - \beta)^2}$ + +Cool, right? + +::::::::::::::::::::::::::::::::::::: keypoints + +- Use `.md` files for episodes when you want static content +- Use `.Rmd` files for episodes when you need to generate output +- Run `sandpaper::check_lesson()` to identify any issues with your lesson +- Run `sandpaper::build_lesson()` to preview your lesson locally + +:::::::::::::::::::::::::::::::::::::::::::::::: + From 4678d52ba79f19395a3caae1277721e38a97cea4 Mon Sep 17 00:00:00 2001 From: Clementine Cottineau Date: Fri, 12 Jan 2024 14:28:04 +0100 Subject: [PATCH 04/38] Update 01-intro-to-r.Rmd --- episodes/01-intro-to-r.Rmd | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/episodes/01-intro-to-r.Rmd b/episodes/01-intro-to-r.Rmd index e7e85201..73e2aa60 100644 --- a/episodes/01-intro-to-r.Rmd +++ b/episodes/01-intro-to-r.Rmd @@ -319,7 +319,7 @@ You can use R as calculator, you can for example write: ## Variables and assignment -However, what's more useful is the that in R we can store values and +However, what's more useful is that in R we can store values and use them whenever we need to. We using the assignment operator `<-`, like this: From af98430ff7bf47f3dd7c4c5b715f571e04d731c8 Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci Date: Fri, 12 Jan 2024 16:45:07 +0100 Subject: [PATCH 05/38] Add episode 4 --- .DS_Store | Bin 0 -> 6148 bytes config.yaml | 1 + episodes/04-intro-to-visualisation.Rmd | 208 +++++++++++++++++++++++++ 3 files changed, 209 insertions(+) create mode 100644 .DS_Store create mode 100644 episodes/04-intro-to-visualisation.Rmd diff --git a/.DS_Store b/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..cb794769ec8451d8cfaa950bcafcfe1de26c7dc5 GIT binary patch literal 6148 zcmeHK%}T>S5Z-O8-BN@c6nYGJEm+%95HBIt7cim+m70*C!I&*gY7V84v%Zi|;`2DO zy8(+icoMNQu=!@^XLsj=>g$$H%p2Zu+e7qh42IhC)POb)y&*)v$d8z|rEdhr%%BGU)(Re4oBAu&J< z5Cg=(_Ap@10MXr^lBrT+fEf581Gqof&=4JirAD=Nzz46-=x-sSfR1koMBAWau+#`1 z5Ux`Jbt*Sc46f6`ZkssAV5w23Gp=Taam>usyHR32}SLuLs5m1EChZy(;20j6DRZR^5 literal 0 HcmV?d00001 diff --git a/config.yaml b/config.yaml index 08ad0d8a..b76356bc 100644 --- a/config.yaml +++ b/config.yaml @@ -63,6 +63,7 @@ episodes: - 01-intro-to-r.Rmd - 02-data-structures.Rmd - 03-explore-data.Rmd +- 04-intro-to-visualisation.Rmd # Information for Learners learners: diff --git a/episodes/04-intro-to-visualisation.Rmd b/episodes/04-intro-to-visualisation.Rmd new file mode 100644 index 00000000..03b4b64f --- /dev/null +++ b/episodes/04-intro-to-visualisation.Rmd @@ -0,0 +1,208 @@ +--- +title: "Introduction to visualisation" + +--- + +:::::::::::::::::::::::::::::::::::::: questions + +- How can I create a basic plot in R? +- How can I add features to a plot? +- How can I get basic summary information about my data set? +- How can I include addition information via a colours palette. +- How can I find more information about a function and its arguments? +- How can I create new columns or remove existing columns from a data frame? + +:::::::::::::::::::::::::::::::::::::::::::::::: + +::::::::::::::::::::::::::::::::::::: objectives + +- Generate plots to visualise data with ggplot. +- Add plot layers to incrementally build a more complex plot. +- Use the 'fill' argument for coloring surfaces, and modify colours with the viridis or scale_manual packages. +- Explore the help documentation. +- Save and format your plot via the ggsave function. + +:::::::::::::::::::::::::::::::::::::::::::::::: + +# [Introduction to Visualisation](https://datacarpentry.org/r-intro-geospatial/07-plot-ggplot2/index.html) + +Package `ggplot2` is a powerful plotting system. I will introduce key +features of `ggplot`. In the following parts of this workshop, you will +use this package to visualize geo-spatial data. `gg` stands for grammar +of graphics, the idea that three components needed to create a graph +are: - data - aesthetics - coordinate system on which we map the data +(what is represented on x axis, what on y axis) - geometries - visual +representation of the data (points, bars, etc.) + +Fun part about `ggplot` is that you can then add additional layers to +the plot providing more information and make it more beautiful. + +First, lets plot distribution of life expectancy in the `gapminder` data +set. + +```{r ggplot} + ggplot(data = gapminder, aes(x = lifeExp) ) + # aesthetics layer + geom_histogram() # geometry layer + +``` + +You can see that in `ggplot` you use `+` as a pipe, to add layers. +Within `ggplot` call, it is the only pipe that will work. But, it is +possible to chain operations on a data set with a pipe that we have +already learned: `%>%` ( or `|>`) and follow them by ggplot grammar. + +Let's create another plot, this time only on a subset of observations: + +```{r ggplot-col} +gapminder %>% # we select a data set + filter(year == 2007 & + continent == 'Americas') %>% # and filter it to keep only one year and one continent + ggplot(aes(x = country, y = gdpPercap)) + # we create aesthetics, both x and y axis represent values of columns + geom_col() # we select a column graph as a geometry +``` + +Now, you can iteratively improve how the plot looks like. For example, +you might want to flip it, to better display the labels. + +```{r ggplot-coord-flip} +gapminder %>% + filter(year == 2007, + continent == 'Americas') %>% + ggplot(aes(x = country, y = gdpPercap)) + + geom_col()+ + coord_flip() +``` + +One thing you might want to change here is the order in which countries +are displayed. It would be easier to compare GDP per capita, if they +were showed in order. To do that, we need to reorder factor levels (you +remember, we've already done this before). + +Now the order of the levels will depend on another variable - GDP per +capita. + +```{r ggplot-color} +gapminder %>% + filter(year == 2007, + continent == 'Americas') %>% + mutate(country = fct_reorder(country, gdpPercap )) %>% + ggplot(aes(x = country , y = gdpPercap)) + + geom_col() + + coord_flip() + +``` + +Let's make things more colorful - let's represent the average life +expectancy of a country by color + +```{r ggplot-colors} +gapminder %>% + filter(year == 2007, + continent == 'Americas') %>% + mutate(country = fct_reorder(country, gdpPercap )) %>% + ggplot(aes(x = country, y = gdpPercap, fill = lifeExp )) + # fill argument for coloring surfaces, color for points and lines + geom_col()+ + coord_flip() + + +``` + +We can also adapt the color scale. Common choice that is used for its +readibility and colorblind-proofness are the pallettes available in the +`viridis` package. + +```{r ggplot-colors-adapt} +gapminder %>% + filter(year == 2007, + continent == 'Americas') %>% + mutate(country = fct_reorder(country, gdpPercap )) %>% + ggplot(aes(x = country, y = gdpPercap, fill = lifeExp )) + + geom_col()+ + coord_flip()+ + scale_fill_viridis_c() # _c stands for continuous scale + +``` + +Maybe we don't need that much information about the life expectancy. We +only want to know if it's below or above average. + +```{r ggplot-colors-discrete} +plot_d <- # this time let's save the plot in the object. + gapminder %>% + filter(year == 2007 & + continent == 'Americas') %>% + mutate(country = fct_reorder(country, gdpPercap ), + lifeExpCat = if_else(lifeExp >= mean(lifeExp), 'high', 'low' ) + ) %>% + ggplot(aes(x = country, y = gdpPercap, fill = lifeExpCat)) + + geom_col()+ + coord_flip()+ + scale_fill_manual(values = c('light blue', 'orange')) + +``` + +Since we saved a plot as an object, nothing has been printed out. Just +like with any other object in `R`, if you want to see it, you need to +call it. + +```{r ggplot-call} +plot_d + +``` + +Now we can make use of the saved object and add things to it. + +Let's also give it a title and name the axes: + +```{r ggplot-titles} +plot_d <- + plot_d + + ggtitle('GDP per capita in Americas', subtitle = 'Year 2007') + + xlab('Country')+ + ylab('GDP per capita') + +plot_d +``` + +# [Writing data](https://datacarpentry.org/r-intro-geospatial/08-writing-data/index.html) + +## Saving the plot + +Once we are happy with our plot we can save it in a format of our +choice. Remember to save it in the dedicated folder. + +```{r save-plot} +ggsave(plot = plot_d, + filename = here('fig_output','plot_americas_2007.pdf') ) # By default, ggsave() saves the last displayed plot, but you can also explicitly name the plot you want to save + +``` + +### Using help documentation + +My saved plot is not very readable. We can see why it happened by +exploring the help documentation. We can do it by writing directly in +the Console: + +```{r help, eval=FALSE} +?ggsave +``` + +We can read that it uses the "size of the current graphics device". That +would explain why our saved plots look slightly different. Feel free to +explore the documentation to see how to adapt the size e.g. by adapting +`width`, `height` and `units` parameter. + +## Saving the data + +Another output of your work you want to save is a cleaned data set. In +your analysis, you can then load directly that data set. Say we want to +save the data only for Australia: + +```{r writing-data} +gapminder_amr_2007 <- gapminder %>% + filter(year == 2007 & continent == 'Americas') %>% + mutate(country_reordered = fct_reorder(country, gdpPercap ), + lifeExpCat = if_else(lifeExp >= mean(lifeExp), 'high', 'low')) + +write.csv(gapminder_amr_2007, here('data_output', 'gapminder_americas_2007.csv'), row.names=FALSE) +``` From a2d26a071e97ef342af8d8d640d9fd9342e23a68 Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci Date: Mon, 15 Jan 2024 11:42:34 +0100 Subject: [PATCH 06/38] Make text revisions --- episodes/04-intro-to-visualisation.Rmd | 65 +++++++++++++------------- 1 file changed, 32 insertions(+), 33 deletions(-) diff --git a/episodes/04-intro-to-visualisation.Rmd b/episodes/04-intro-to-visualisation.Rmd index 03b4b64f..1ee412bf 100644 --- a/episodes/04-intro-to-visualisation.Rmd +++ b/episodes/04-intro-to-visualisation.Rmd @@ -1,6 +1,7 @@ --- title: "Introduction to visualisation" - +teaching: 10 # to be updated by Jerome & Kyri +exercises: 2 # to be updated by Jerome & Kyri --- :::::::::::::::::::::::::::::::::::::: questions @@ -16,29 +17,28 @@ title: "Introduction to visualisation" ::::::::::::::::::::::::::::::::::::: objectives -- Generate plots to visualise data with ggplot. +- Generate plots to visualise data with `ggplot2`. - Add plot layers to incrementally build a more complex plot. -- Use the 'fill' argument for coloring surfaces, and modify colours with the viridis or scale_manual packages. +- Use the `fill` argument for colouring surfaces, and modify colours with the viridis or scale_manual packages. - Explore the help documentation. -- Save and format your plot via the ggsave function. +- Save and format your plot via the `ggsave()` function. :::::::::::::::::::::::::::::::::::::::::::::::: # [Introduction to Visualisation](https://datacarpentry.org/r-intro-geospatial/07-plot-ggplot2/index.html) -Package `ggplot2` is a powerful plotting system. I will introduce key -features of `ggplot`. In the following parts of this workshop, you will -use this package to visualize geo-spatial data. `gg` stands for grammar +The package `ggplot2` is a powerful plotting system. We will start with an introduction of key +features of `ggplot2`. In the following parts of this workshop, you will +use this package to visualize geospatial data. `gg` stands for grammar of graphics, the idea that three components needed to create a graph are: - data - aesthetics - coordinate system on which we map the data (what is represented on x axis, what on y axis) - geometries - visual representation of the data (points, bars, etc.) -Fun part about `ggplot` is that you can then add additional layers to -the plot providing more information and make it more beautiful. +Fun part about `ggplot2` is that you can add layers to +the plot to provide more information and to make it more beautiful. -First, lets plot distribution of life expectancy in the `gapminder` data -set. +First, lets plot the distribution of life expectancy in the `gapminder` dataset: ```{r ggplot} ggplot(data = gapminder, aes(x = lifeExp) ) + # aesthetics layer @@ -47,18 +47,18 @@ set. ``` You can see that in `ggplot` you use `+` as a pipe, to add layers. -Within `ggplot` call, it is the only pipe that will work. But, it is +Within the `ggplot()` call, it is the only pipe that will work. But, it is possible to chain operations on a data set with a pipe that we have -already learned: `%>%` ( or `|>`) and follow them by ggplot grammar. +already learned: `%>%` ( or `|>`) and follow them by ggplot syntax. Let's create another plot, this time only on a subset of observations: ```{r ggplot-col} gapminder %>% # we select a data set filter(year == 2007 & - continent == 'Americas') %>% # and filter it to keep only one year and one continent - ggplot(aes(x = country, y = gdpPercap)) + # we create aesthetics, both x and y axis represent values of columns - geom_col() # we select a column graph as a geometry + continent == 'Americas') %>% # and filter it to keep only one year and one continent + ggplot(aes(x = country, y = gdpPercap)) + # the x and y axes represent values of columns + geom_col() # we select a column graph as a geometry ``` Now, you can iteratively improve how the plot looks like. For example, @@ -70,7 +70,7 @@ gapminder %>% continent == 'Americas') %>% ggplot(aes(x = country, y = gdpPercap)) + geom_col()+ - coord_flip() + coord_flip() # flip axes ``` One thing you might want to change here is the order in which countries @@ -85,30 +85,30 @@ capita. gapminder %>% filter(year == 2007, continent == 'Americas') %>% - mutate(country = fct_reorder(country, gdpPercap )) %>% + mutate(country = fct_reorder(country, gdpPercap )) %>% # reorder factor levels ggplot(aes(x = country , y = gdpPercap)) + geom_col() + coord_flip() ``` -Let's make things more colorful - let's represent the average life -expectancy of a country by color +Let's make things more colourful - let's represent the average life +expectancy of a country by colour ```{r ggplot-colors} gapminder %>% filter(year == 2007, continent == 'Americas') %>% mutate(country = fct_reorder(country, gdpPercap )) %>% - ggplot(aes(x = country, y = gdpPercap, fill = lifeExp )) + # fill argument for coloring surfaces, color for points and lines + ggplot(aes(x = country, y = gdpPercap, fill = lifeExp )) + # fill argument for colouring surfaces, colour for points and lines geom_col()+ coord_flip() ``` -We can also adapt the color scale. Common choice that is used for its -readibility and colorblind-proofness are the pallettes available in the +We can also adapt the colour scale. Common choice that is used for its +readability and colorblind-proofness are the palettes available in the `viridis` package. ```{r ggplot-colors-adapt} @@ -119,7 +119,7 @@ gapminder %>% ggplot(aes(x = country, y = gdpPercap, fill = lifeExp )) + geom_col()+ coord_flip()+ - scale_fill_viridis_c() # _c stands for continuous scale + scale_fill_viridis_c() # _c stands for continuous scale ``` @@ -127,17 +127,16 @@ Maybe we don't need that much information about the life expectancy. We only want to know if it's below or above average. ```{r ggplot-colors-discrete} -plot_d <- # this time let's save the plot in the object. +plot_d <- # this time let's save the plot in an object gapminder %>% filter(year == 2007 & continent == 'Americas') %>% mutate(country = fct_reorder(country, gdpPercap ), - lifeExpCat = if_else(lifeExp >= mean(lifeExp), 'high', 'low' ) - ) %>% + lifeExpCat = if_else(lifeExp >= mean(lifeExp), 'high', 'low')) %>% ggplot(aes(x = country, y = gdpPercap, fill = lifeExpCat)) + geom_col()+ coord_flip()+ - scale_fill_manual(values = c('light blue', 'orange')) + scale_fill_manual(values = c('light blue', 'orange')) # customize the colours of the fill aesthetic ``` @@ -173,15 +172,15 @@ choice. Remember to save it in the dedicated folder. ```{r save-plot} ggsave(plot = plot_d, - filename = here('fig_output','plot_americas_2007.pdf') ) # By default, ggsave() saves the last displayed plot, but you can also explicitly name the plot you want to save + filename = here('fig_output','plot_americas_2007.pdf')) # By default, ggsave() saves the last displayed plot, but you can also explicitly name the plot you want to save ``` ### Using help documentation My saved plot is not very readable. We can see why it happened by -exploring the help documentation. We can do it by writing directly in -the Console: +exploring the help documentation. We can do that by writing directly in +the console: ```{r help, eval=FALSE} ?ggsave @@ -195,8 +194,8 @@ explore the documentation to see how to adapt the size e.g. by adapting ## Saving the data Another output of your work you want to save is a cleaned data set. In -your analysis, you can then load directly that data set. Say we want to -save the data only for Australia: +your analysis, you can then load directly that data set. Let's say we want to +save the data only for Americas: ```{r writing-data} gapminder_amr_2007 <- gapminder %>% From 40a46fb4d4c1f346f9c3ba8796b547ae96dbf171 Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci Date: Mon, 15 Jan 2024 17:35:57 +0100 Subject: [PATCH 07/38] Fix duplicate code chunk lables --- episodes/02-data-structures.Rmd | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/episodes/02-data-structures.Rmd b/episodes/02-data-structures.Rmd index f9fef7e6..7cc38c3b 100644 --- a/episodes/02-data-structures.Rmd +++ b/episodes/02-data-structures.Rmd @@ -161,8 +161,8 @@ displayed in a plot or which category is taken as a baseline in a statistical mo You can reorder the categories using `factor()` function. -```{r factor-reorder} -nordic_cat <- factor(nordic_cat, levels = c('Norway' , 'Denmark', 'Sweden')) # now Norway should be the first category, Denmark second and Sweden third +```{r factor-reorder1} +nordic_cat <- factor(nordic_cat, levels = c('Norway' , 'Denmark', 'Sweden')) # now Norway should be the first category, Denmark second and Sweden third nordic_cat ``` @@ -172,7 +172,7 @@ nordic_cat There is more than one way to reorder factors. Later in the lesson, we will use `fct_relevel()` function from `forcats` package to do the reordering. -```{r factor-reorder} +```{r factor-reorder2} # nordic_cat <- fct_relevel(nordic_cat, 'Norway' , 'Denmark', 'Sweden') # now Norway should be the first category, Denmark second and Sweden third nordic_cat From df39c8988ab21e7a7a51ae4047eec5cb5ac4c84b Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci Date: Mon, 15 Jan 2024 18:38:29 +0100 Subject: [PATCH 08/38] Add setup code chunks in episodes 3 and 4 --- episodes/03-explore-data.Rmd | 16 ++++++++++++++++ episodes/04-intro-to-visualisation.Rmd | 19 +++++++++++++++++++ 2 files changed, 35 insertions(+) diff --git a/episodes/03-explore-data.Rmd b/episodes/03-explore-data.Rmd index 643fb750..60809f98 100644 --- a/episodes/03-explore-data.Rmd +++ b/episodes/03-explore-data.Rmd @@ -4,6 +4,22 @@ teaching: 10 exercises: 2 --- +```{r setup, include=FALSE} +knitr::opts_chunk$set( + echo = TRUE, + message = FALSE, + warning = FALSE +) + +# Load libraries ---------------------------------------------------------- +# Package names +packages <- c("tidyverse", "here") + +# Packages loading +invisible(lapply(packages, library, character.only = TRUE)) + +``` + :::::::::::::::::::::::::::::::::::::: questions - What is a data frame? diff --git a/episodes/04-intro-to-visualisation.Rmd b/episodes/04-intro-to-visualisation.Rmd index 1ee412bf..2c131d0d 100644 --- a/episodes/04-intro-to-visualisation.Rmd +++ b/episodes/04-intro-to-visualisation.Rmd @@ -4,6 +4,25 @@ teaching: 10 # to be updated by Jerome & Kyri exercises: 2 # to be updated by Jerome & Kyri --- +```{r setup, include=FALSE} +knitr::opts_chunk$set( + echo = TRUE, + message = FALSE, + warning = FALSE +) + +# Load libraries ---------------------------------------------------------- +# Package names +packages <- c("tidyverse", "here") + +# Packages loading +invisible(lapply(packages, library, character.only = TRUE)) + +# Load gapminder data +gapminder <- read.csv("data/gapminder_data.csv") + +``` + :::::::::::::::::::::::::::::::::::::: questions - How can I create a basic plot in R? From 7a6092efb76333c6b2a73228af16855895fa3ec6 Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci Date: Mon, 15 Jan 2024 18:39:27 +0100 Subject: [PATCH 09/38] Add small text revision in episode 3 --- episodes/03-explore-data.Rmd | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/episodes/03-explore-data.Rmd b/episodes/03-explore-data.Rmd index 60809f98..55019a18 100644 --- a/episodes/03-explore-data.Rmd +++ b/episodes/03-explore-data.Rmd @@ -80,7 +80,8 @@ str(gapminder) ``` -We can see that the `gapminder` object is a data.frame with `r nrow(gapminder)` observations/ rows and `r ncol(gapminder)` variables/columns. +We can see that the `gapminder` object is a data.frame with `r nrow(gapminder)` observations (rows) and `r ncol(gapminder)` variables (columns). + In each line after a `$` sign, we see the name of each column, its type and first few values. From 8dba5dc417ef6e81d71adbb1335a36059732765a Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci Date: Mon, 15 Jan 2024 18:39:51 +0100 Subject: [PATCH 10/38] Fix paths to data --- episodes/01-intro-to-r.Rmd | 2 +- episodes/03-explore-data.Rmd | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/episodes/01-intro-to-r.Rmd b/episodes/01-intro-to-r.Rmd index 73e2aa60..545f828d 100644 --- a/episodes/01-intro-to-r.Rmd +++ b/episodes/01-intro-to-r.Rmd @@ -300,7 +300,7 @@ In the script, we will write: ```{r download-files} # Download the data download.file('https://bit.ly/geospatial_data', - here('data','gapminder_data.csv'), mode = 'wb') + here('episodes', 'data','gapminder_data.csv'), mode = 'wb') ``` diff --git a/episodes/03-explore-data.Rmd b/episodes/03-explore-data.Rmd index 55019a18..2ce99435 100644 --- a/episodes/03-explore-data.Rmd +++ b/episodes/03-explore-data.Rmd @@ -66,7 +66,7 @@ For example, here is a figure depicting a data frame comprising a numeric, a cha We're gonna read in the `gapminder` data set with information about countries' size, GDP and average life expectancy in different years. ```{r reading-data} -gapminder <- read.csv(here('data','gapminder_data.csv') ) +gapminder <- read.csv("data/gapminder_data.csv") ``` From 62984e5c0562aaa90306389c12fcaee53495abd9 Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci Date: Mon, 15 Jan 2024 18:40:13 +0100 Subject: [PATCH 11/38] Fix list formatting in visualisation episode --- episodes/04-intro-to-visualisation.Rmd | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/episodes/04-intro-to-visualisation.Rmd b/episodes/04-intro-to-visualisation.Rmd index 2c131d0d..1ce3d7a0 100644 --- a/episodes/04-intro-to-visualisation.Rmd +++ b/episodes/04-intro-to-visualisation.Rmd @@ -49,10 +49,12 @@ gapminder <- read.csv("data/gapminder_data.csv") The package `ggplot2` is a powerful plotting system. We will start with an introduction of key features of `ggplot2`. In the following parts of this workshop, you will use this package to visualize geospatial data. `gg` stands for grammar -of graphics, the idea that three components needed to create a graph -are: - data - aesthetics - coordinate system on which we map the data -(what is represented on x axis, what on y axis) - geometries - visual -representation of the data (points, bars, etc.) +of graphics, the idea that three components are needed to create a graph: + +- data, +- aesthetics - a coordinate system on which we map the data +(what is represented on x axis, what on y axis), and +- geometries - visual representation of the data (points, bars, etc.) Fun part about `ggplot2` is that you can add layers to the plot to provide more information and to make it more beautiful. From ceb99ac534e780586cba11f7d79031ba143b71b8 Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci Date: Mon, 15 Jan 2024 18:40:40 +0100 Subject: [PATCH 12/38] Simplify plot object name to p --- episodes/04-intro-to-visualisation.Rmd | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/episodes/04-intro-to-visualisation.Rmd b/episodes/04-intro-to-visualisation.Rmd index 1ce3d7a0..df78e234 100644 --- a/episodes/04-intro-to-visualisation.Rmd +++ b/episodes/04-intro-to-visualisation.Rmd @@ -148,7 +148,7 @@ Maybe we don't need that much information about the life expectancy. We only want to know if it's below or above average. ```{r ggplot-colors-discrete} -plot_d <- # this time let's save the plot in an object +p <- # this time let's save the plot in an object gapminder %>% filter(year == 2007 & continent == 'Americas') %>% @@ -166,7 +166,7 @@ like with any other object in `R`, if you want to see it, you need to call it. ```{r ggplot-call} -plot_d +p ``` @@ -175,13 +175,13 @@ Now we can make use of the saved object and add things to it. Let's also give it a title and name the axes: ```{r ggplot-titles} -plot_d <- - plot_d + +p <- + p + ggtitle('GDP per capita in Americas', subtitle = 'Year 2007') + xlab('Country')+ ylab('GDP per capita') -plot_d +p ``` # [Writing data](https://datacarpentry.org/r-intro-geospatial/08-writing-data/index.html) @@ -192,7 +192,7 @@ Once we are happy with our plot we can save it in a format of our choice. Remember to save it in the dedicated folder. ```{r save-plot} -ggsave(plot = plot_d, +ggsave(plot = p, filename = here('fig_output','plot_americas_2007.pdf')) # By default, ggsave() saves the last displayed plot, but you can also explicitly name the plot you want to save ``` From 1359c9fd5ed42e8310d5ff7069f49ac7d0b37bca Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci <33600128+cforgaci@users.noreply.github.com> Date: Tue, 16 Jan 2024 19:22:06 +0100 Subject: [PATCH 13/38] Fix typo in 03-explore-data.Rmd Co-authored-by: fcjerome <129063142+fcjerome@users.noreply.github.com> --- episodes/03-explore-data.Rmd | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/episodes/03-explore-data.Rmd b/episodes/03-explore-data.Rmd index 2ce99435..5fd26193 100644 --- a/episodes/03-explore-data.Rmd +++ b/episodes/03-explore-data.Rmd @@ -150,7 +150,7 @@ First we define data set, then - with the use of pipe we pass it on to the `sele ## Filter -We already now how to select only the needed columns. But now, we also want to filter the data set via certain condition with `filter()` function. Instead doing it in separate steps, we can do it all together. +We already know how to select only the needed columns. But now, we also want to filter the data set via certain conditions with `filter()` function. Instead of doing it in separate steps, we can do it all together. In the `gapminder` data set, we want to see the results from outside of Europe for the 21st century. ```{r} From 102840aa977eade4c677e0aff9bbc31e873f64b3 Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci <33600128+cforgaci@users.noreply.github.com> Date: Tue, 16 Jan 2024 19:23:17 +0100 Subject: [PATCH 14/38] Fix logical operator in 03-explore-data.Rmd Co-authored-by: fcjerome <129063142+fcjerome@users.noreply.github.com> --- episodes/03-explore-data.Rmd | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/episodes/03-explore-data.Rmd b/episodes/03-explore-data.Rmd index 5fd26193..70749319 100644 --- a/episodes/03-explore-data.Rmd +++ b/episodes/03-explore-data.Rmd @@ -155,7 +155,7 @@ We already know how to select only the needed columns. But now, we also want to In the `gapminder` data set, we want to see the results from outside of Europe for the 21st century. ```{r} year_country_gdp_euro <- gapminder %>% - filter(continent != "Europe" & year > 2000) %>% # & operator (AND) - both conditions must be met + filter(continent != "Europe" & year >= 2000) %>% # & operator (AND) - both conditions must be met select(year, country, gdpPercap) head(year_country_gdp_euro) From e65316ab5917cec7434cfe854c542dc45b20e4d9 Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci Date: Wed, 17 Jan 2024 08:33:19 +0100 Subject: [PATCH 15/38] Update explanation of running scripts --- episodes/01-intro-to-r.Rmd | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/episodes/01-intro-to-r.Rmd b/episodes/01-intro-to-r.Rmd index 545f828d..4f1e2393 100644 --- a/episodes/01-intro-to-r.Rmd +++ b/episodes/01-intro-to-r.Rmd @@ -177,10 +177,15 @@ We will now learn how to run the code both in the console and the script. - In the R script there are two way to execute the code: + You can use the `Run` button on the top right of the script window. + Alternatively, you can use a keyboard shortcut: Ctrl + - Enter or Command + Return for MAC users. + Enter or Command + Return for Mac users. In both cases, the active line (the line where your cursor is placed) or a -highlighted snippet of code will be executed. +highlighted snippet of code will be executed. A common source of error in scripts, +such as a previously created object not found, is code that has not been executed in +previous lines: make sure that all code has been executed as described above. +To run all lines before the active line, you can use the keyboard shortcut +Ctrl + Alt + B on Windows/Linux or +Command + option + B on Mac. :::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: callout @@ -192,7 +197,7 @@ It will show `+` sign if it still requires input for the command to be executed. Sometimes you don't know what is missing/ you change your mind and want to run something else, or your code is running much too long and you just want it to stop. -The way to do it is to hit Esc. +The way to do it is to press Esc. :::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: From df93aaf5dabf0814cda183a5ca5e9e73de2209ba Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci Date: Wed, 17 Jan 2024 08:43:09 +0100 Subject: [PATCH 16/38] Update description of handling paths with here According to Kyri's suggestion --- episodes/01-intro-to-r.Rmd | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/episodes/01-intro-to-r.Rmd b/episodes/01-intro-to-r.Rmd index 4f1e2393..7ccef0a5 100644 --- a/episodes/01-intro-to-r.Rmd +++ b/episodes/01-intro-to-r.Rmd @@ -275,16 +275,19 @@ you will need to specify the path from the folder you are in (most likely the `scripts/` folder) to those files. That can become complicated and might cause a reproducibility problem, -if the person using your code (e.g. future you) +if the person using your code (including future you) is working in a different sub-folder. -We will use `here()` package to tackle this issue! This package converts relative +We will use the `here()` package to tackle this issue. This package converts relative paths from the root (main folder) of your project to absolute paths (the exact -location on your computer). +location on your computer). For instance, instead of writing out the full path like "C:/Users/YourName/Documents/r-geospatial-urban/data/file.csv" or "~/Documents/r-geospatial-urban/data/file.csv", you can use the `here()` function +to create a path relative to your project's main directory. This makes your code +more portable and reproducible, as it doesn't depend on a specific location of +your project on your computer. -It might be confusing, so let's see how it works. We will use the `here` function -from the `here` package. In the console, please write: +It might be confusing, so let's see how it works. We will use the `here()` function +from the `here` package. In the console, we write: ```{r here} here() From 294513e7ccb91065db663b13281d9f9a84826820 Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci Date: Wed, 17 Jan 2024 08:43:09 +0100 Subject: [PATCH 17/38] Update description of handling paths with here According to Kyri's suggestion --- episodes/01-intro-to-r.Rmd | 19 ++++++++++++------- 1 file changed, 12 insertions(+), 7 deletions(-) diff --git a/episodes/01-intro-to-r.Rmd b/episodes/01-intro-to-r.Rmd index 4f1e2393..e4a33a23 100644 --- a/episodes/01-intro-to-r.Rmd +++ b/episodes/01-intro-to-r.Rmd @@ -177,7 +177,7 @@ We will now learn how to run the code both in the console and the script. - In the R script there are two way to execute the code: + You can use the `Run` button on the top right of the script window. + Alternatively, you can use a keyboard shortcut: Ctrl + - Enter or Command + Return for Mac users. + Enter or Command + Return for MAC users. In both cases, the active line (the line where your cursor is placed) or a highlighted snippet of code will be executed. A common source of error in scripts, @@ -275,16 +275,21 @@ you will need to specify the path from the folder you are in (most likely the `scripts/` folder) to those files. That can become complicated and might cause a reproducibility problem, -if the person using your code (e.g. future you) +if the person using your code (including future you) is working in a different sub-folder. -We will use `here()` package to tackle this issue! This package converts relative +We will use the `here()` package to tackle this issue. This package converts relative paths from the root (main folder) of your project to absolute paths (the exact -location on your computer). - -It might be confusing, so let's see how it works. We will use the `here` function -from the `here` package. In the console, please write: +location on your computer). For instance, instead of writing out the full path like +"C:/Users/YourName/Documents/r-geospatial-urban/data/file.csv" or +"~/Documents/r-geospatial-urban/data/file.csv", you can use the `here()` function +to create a path relative to your project's main directory. This makes your code +more portable and reproducible, as it doesn't depend on a specific location of +your project on your computer. + +It might be confusing, so let's see how it works. We will use the `here()` function +from the `here` package. In the console, we write: ```{r here} here() From 6ab21e06355884c5bb0cef967323eedaa4f74795 Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci Date: Wed, 17 Jan 2024 08:56:27 +0100 Subject: [PATCH 18/38] Add callout about importing data into R According to Clementine's suggestion in the review of PR#5 --- episodes/01-intro-to-r.Rmd | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/episodes/01-intro-to-r.Rmd b/episodes/01-intro-to-r.Rmd index e4a33a23..3075925c 100644 --- a/episodes/01-intro-to-r.Rmd +++ b/episodes/01-intro-to-r.Rmd @@ -314,6 +314,21 @@ download.file('https://bit.ly/geospatial_data', ``` +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: callout + +# Importing data into R + +Three of the most common ways of importing data in R are: + +- loading a package with pre-installed data; +- downloading data from a URL; +- reading a file from your computer. + +For larger datasets, database connections or API requests are also possible. We +will not cover these in the workshop. + +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: + # Introduction to R From 4191aba4e5e74d628dcd7d8c8e2b86bdbd4e3060 Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci Date: Wed, 17 Jan 2024 09:11:10 +0100 Subject: [PATCH 19/38] Remove unnecessary mode = 'wb' from download.file --- episodes/01-intro-to-r.Rmd | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/episodes/01-intro-to-r.Rmd b/episodes/01-intro-to-r.Rmd index 3075925c..ab5c33c1 100644 --- a/episodes/01-intro-to-r.Rmd +++ b/episodes/01-intro-to-r.Rmd @@ -310,7 +310,7 @@ In the script, we will write: ```{r download-files} # Download the data download.file('https://bit.ly/geospatial_data', - here('episodes', 'data','gapminder_data.csv'), mode = 'wb') + here('episodes', 'data','gapminder_data.csv')) ``` From e4358dd4b04ad4cb19479eae82c04e492875e094 Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci Date: Wed, 17 Jan 2024 09:43:49 +0100 Subject: [PATCH 20/38] Update description of data structures As suggested by Clementine in PR#5 --- episodes/02-data-structures.Rmd | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/episodes/02-data-structures.Rmd b/episodes/02-data-structures.Rmd index 7cc38c3b..05659e38 100644 --- a/episodes/02-data-structures.Rmd +++ b/episodes/02-data-structures.Rmd @@ -21,7 +21,7 @@ exercises: 2 ## Vectors So far we've looked on individual values. Now we will move to a data structure -called vectors. Vectors are arrays of values of a same data type. +called vectors. Vectors are arrays of values of the same data type. :::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: callout @@ -41,6 +41,16 @@ We won't discuss `complex` or `raw` data type in the workshop. ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: callout + +### Data structures + +Vectors are the most common and basic data structure in R but you will come +across other data structures such as lists, data frames and matrices as well. +For an overview, see [Data Types and Structures](https://swcarpentry.github.io/r-novice-inflammation/13-supp-data-structures.html). + +::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: + You can create a vector with a `c()` function. ```{r vectors} From a11191807fe0929cbe3f204f5de532b18e5ce161 Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci Date: Wed, 17 Jan 2024 10:02:12 +0100 Subject: [PATCH 21/38] Add explanation of data structures According to Clementine's sugegstion in PR#5 --- episodes/02-data-structures.Rmd | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/episodes/02-data-structures.Rmd b/episodes/02-data-structures.Rmd index 05659e38..08812b3d 100644 --- a/episodes/02-data-structures.Rmd +++ b/episodes/02-data-structures.Rmd @@ -46,8 +46,16 @@ We won't discuss `complex` or `raw` data type in the workshop. ### Data structures Vectors are the most common and basic data structure in R but you will come -across other data structures such as lists, data frames and matrices as well. -For an overview, see [Data Types and Structures](https://swcarpentry.github.io/r-novice-inflammation/13-supp-data-structures.html). +across other data structures such as data frames, lists and matrices as well. +In short: + +- data.frames is a two-dimensional data structure in which columns are vectors of the same length that can have different data types. We will use this data structure in this lesson. +- lists can have an arbitrary structure and can mix data types; +- matrices are two-dimensional data structures containing elements of the same data type. + +For a more detailed description, see [Data Types and Structures](https://swcarpentry.github.io/r-novice-inflammation/13-supp-data-structures.html). + +Data structures for geospatial data use combinations of lists, data frames, matrices and vectors. While vector data (not the data structure with the same name!) combines a data frame structure with lists for attributes and geometry in a nested way, raster data are essentially represented as matrices in which each cell is a pixel. More about vector and raster data later in the workshop! ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: From f57997563ba2134649c15dabffd61fe63f625f1f Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci <33600128+cforgaci@users.noreply.github.com> Date: Wed, 17 Jan 2024 10:12:50 +0100 Subject: [PATCH 22/38] Shorten piped expression in episodes/03-explore-data.Rmd Co-authored-by: fcjerome <129063142+fcjerome@users.noreply.github.com> --- episodes/03-explore-data.Rmd | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/episodes/03-explore-data.Rmd b/episodes/03-explore-data.Rmd index 70749319..030cd9a1 100644 --- a/episodes/03-explore-data.Rmd +++ b/episodes/03-explore-data.Rmd @@ -216,14 +216,10 @@ Calculate the average life expectancy per country. Which country has the longest ```{r ex6 , class.source="bg-info"} -lifeExp_bycountry <- gapminder %>% +gapminder %>% group_by(country) %>% - summarize(avg_lifeExp=mean(lifeExp)) - - -lifeExp_bycountry %>% + summarize(avg_lifeExp=mean(lifeExp)) %>% filter(avg_lifeExp == min(avg_lifeExp) | avg_lifeExp == max(avg_lifeExp)) -``` ### Multiple groups and summary variables You can also group by multiple columns: From ea476171c09feb26c6ee8404c3c6a1dea5d20f80 Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci Date: Wed, 17 Jan 2024 10:18:13 +0100 Subject: [PATCH 23/38] Remove template examples --- episodes/03-explore-data.Rmd | 64 +----------------------------------- 1 file changed, 1 insertion(+), 63 deletions(-) diff --git a/episodes/03-explore-data.Rmd b/episodes/03-explore-data.Rmd index 70749319..9fd9046a 100644 --- a/episodes/03-explore-data.Rmd +++ b/episodes/03-explore-data.Rmd @@ -274,71 +274,9 @@ head(gapminder_gdp) ``` - -::::::::::::::::::::::::::::::::::::: challenge - -## Challenge 1: Can you do it? - -What is the output of this command? - -```r -paste("This", "new", "lesson", "looks", "good") -``` - -:::::::::::::::::::::::: solution - -## Output - -```output -[1] "This new lesson looks good" -``` - -::::::::::::::::::::::::::::::::: - - -## Challenge 2: how do you nest solutions within challenge blocks? - -:::::::::::::::::::::::: solution - -You can add a line with at least three colons and a `solution` tag. - -::::::::::::::::::::::::::::::::: -:::::::::::::::::::::::::::::::::::::::::::::::: - -## Figures - -You can include figures generated from R Markdown: - -```{r pyramid, fig.alt = "pie chart illusion of a pyramid", fig.cap = "Sun arise each and every morning"} -pie( - c(Sky = 78, "Sunny side of pyramid" = 17, "Shady side of pyramid" = 5), - init.angle = 315, - col = c("deepskyblue", "yellow", "yellow3"), - border = FALSE -) -``` -Or you can use pandoc markdown for static figures with the following syntax: - -`![optional caption that appears below the figure](figure url){alt='alt text for -accessibility purposes'}` - -![You belong in The Carpentries!](https://raw.githubusercontent.com/carpentries/logo/master/Badge_Carpentries.svg){alt='Blue Carpentries hex person logo with no text.'} - -## Math - -One of our episodes contains $\LaTeX$ equations when describing how to create -dynamic reports with {knitr}, so we now use mathjax to describe this: - -`$\alpha = \dfrac{1}{(1 - \beta)^2}$` becomes: $\alpha = \dfrac{1}{(1 - \beta)^2}$ - -Cool, right? - ::::::::::::::::::::::::::::::::::::: keypoints -- Use `.md` files for episodes when you want static content -- Use `.Rmd` files for episodes when you need to generate output -- Run `sandpaper::check_lesson()` to identify any issues with your lesson -- Run `sandpaper::build_lesson()` to preview your lesson locally +- :::::::::::::::::::::::::::::::::::::::::::::::: From f652dd7fe6f2ccb161a2453befe04fb352d99221 Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci <33600128+cforgaci@users.noreply.github.com> Date: Wed, 17 Jan 2024 10:29:21 +0100 Subject: [PATCH 24/38] Explain why and give example when factors are useful --- episodes/02-data-structures.Rmd | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/episodes/02-data-structures.Rmd b/episodes/02-data-structures.Rmd index 08812b3d..dc8af77a 100644 --- a/episodes/02-data-structures.Rmd +++ b/episodes/02-data-structures.Rmd @@ -177,7 +177,7 @@ not in the order of occurrence in the vector. `R` assigns value of: This is important as it can affect e.g. the order in which categories are displayed in a plot or which category is taken as a baseline in a statistical model. -You can reorder the categories using `factor()` function. +You can reorder the categories using `factor()` function. This can be useful, for instance, to select a reference category (first level) in a regression model or for ordering legend items in a plot, rather than using the default category systematically (i.e. based on alphabetical order). ```{r factor-reorder1} nordic_cat <- factor(nordic_cat, levels = c('Norway' , 'Denmark', 'Sweden')) # now Norway should be the first category, Denmark second and Sweden third From b945cb2b4ada4fbbaf000870aa57abec2f05a4f3 Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci <33600128+cforgaci@users.noreply.github.com> Date: Wed, 17 Jan 2024 10:30:08 +0100 Subject: [PATCH 25/38] Explain why the use of numbers in factors is useful --- episodes/02-data-structures.Rmd | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/episodes/02-data-structures.Rmd b/episodes/02-data-structures.Rmd index dc8af77a..f4994711 100644 --- a/episodes/02-data-structures.Rmd +++ b/episodes/02-data-structures.Rmd @@ -137,7 +137,8 @@ Factors look like character data, but are used to represent categorical informat Factors create a structured relation between the different levels (values) of a categorical variable, such as days of the week or responses to a question in a survey. While factors look (and often behave) like character vectors, they are -actually treated as numbers by `R`. +actually treated as numbers by `R`, which is useful for computing summary +statistics about their distribution, running regression analysis, etc. So you need to be very careful when treating them as strings. ### Create factors From 2c848d71c2860e256ca5801b2ecde0fbf44aa6e2 Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci <33600128+cforgaci@users.noreply.github.com> Date: Wed, 17 Jan 2024 10:30:33 +0100 Subject: [PATCH 26/38] Update exercise to include logical operators --- episodes/03-explore-data.Rmd | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/episodes/03-explore-data.Rmd b/episodes/03-explore-data.Rmd index 961dc77a..dd70851e 100644 --- a/episodes/03-explore-data.Rmd +++ b/episodes/03-explore-data.Rmd @@ -174,7 +174,7 @@ head(year_country_gdp_eurasia)
Challenge -Write a single command (which can span multiple lines and includes pipes) that will produce a dataframe that has the African values for life expectancy, country and year, but not for other Continents. How many rows does your data frame have and why? +Write a single command (which can span multiple lines and includes pipes) that will produce a data frame that has the values for life expectancy, country and year, only for Eurasia. How many rows does your data frame have and why? Solution From 37c36f9bbd89ce221111e3928c0d7fe38531db5d Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci <33600128+cforgaci@users.noreply.github.com> Date: Wed, 17 Jan 2024 10:30:59 +0100 Subject: [PATCH 27/38] Give relevant example for the use of mutate() --- episodes/03-explore-data.Rmd | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/episodes/03-explore-data.Rmd b/episodes/03-explore-data.Rmd index dd70851e..a1e4b320 100644 --- a/episodes/03-explore-data.Rmd +++ b/episodes/03-explore-data.Rmd @@ -259,7 +259,7 @@ gapminder %>% ## Mutate -Frequently you’ll want to create new columns based on the values in existing columns, for example to do unit conversions, or to find the ratio of values in two columns. For this we’ll use `mutate()`. +Frequently you’ll want to create new columns based on the values in existing columns. For example, instead of only having the GDP per capita, we might want to create a new GDP variable and convert its units into Billions. For this, we’ll use `mutate()`. ```{r dplyr-mutate} gapminder_gdp <- gapminder %>% From 9f74c06256167cf47d2cc7824d30aa5c13441336 Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci <33600128+cforgaci@users.noreply.github.com> Date: Wed, 17 Jan 2024 10:31:49 +0100 Subject: [PATCH 28/38] Explain the importance of checking data types of df columns --- episodes/03-explore-data.Rmd | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/episodes/03-explore-data.Rmd b/episodes/03-explore-data.Rmd index a1e4b320..330969aa 100644 --- a/episodes/03-explore-data.Rmd +++ b/episodes/03-explore-data.Rmd @@ -73,7 +73,7 @@ gapminder <- read.csv("data/gapminder_data.csv") ## Exploring dataset Let’s investigate the `gapminder` data frame a bit; the first thing we should always do is check out what the data looks like. -It is important to see if all the variables (columns) have the data type that we require. Otherwise we can run into trouble. +It is important to see if all the variables (columns) have the data type that we require. For instance, a column might have numbers stored as characters, which would not allow us to make calculations with those numbers. ```{r inspecting-data-str} str(gapminder) From 27506485a3cddab2ca9b69711d10cf79db8cefc8 Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci Date: Wed, 17 Jan 2024 10:58:19 +0100 Subject: [PATCH 29/38] Add data --- episodes/data/gapminder_data.csv | 1705 ++++++++++++++++++++++++++++++ 1 file changed, 1705 insertions(+) create mode 100644 episodes/data/gapminder_data.csv diff --git a/episodes/data/gapminder_data.csv b/episodes/data/gapminder_data.csv new file mode 100644 index 00000000..661ddefc --- /dev/null +++ b/episodes/data/gapminder_data.csv @@ -0,0 +1,1705 @@ +country,year,pop,continent,lifeExp,gdpPercap +Afghanistan,1952,8425333,Asia,28.801,779.4453145 +Afghanistan,1957,9240934,Asia,30.332,820.8530296 +Afghanistan,1962,10267083,Asia,31.997,853.10071 +Afghanistan,1967,11537966,Asia,34.02,836.1971382 +Afghanistan,1972,13079460,Asia,36.088,739.9811058 +Afghanistan,1977,14880372,Asia,38.438,786.11336 +Afghanistan,1982,12881816,Asia,39.854,978.0114388 +Afghanistan,1987,13867957,Asia,40.822,852.3959448 +Afghanistan,1992,16317921,Asia,41.674,649.3413952 +Afghanistan,1997,22227415,Asia,41.763,635.341351 +Afghanistan,2002,25268405,Asia,42.129,726.7340548 +Afghanistan,2007,31889923,Asia,43.828,974.5803384 +Albania,1952,1282697,Europe,55.23,1601.056136 +Albania,1957,1476505,Europe,59.28,1942.284244 +Albania,1962,1728137,Europe,64.82,2312.888958 +Albania,1967,1984060,Europe,66.22,2760.196931 +Albania,1972,2263554,Europe,67.69,3313.422188 +Albania,1977,2509048,Europe,68.93,3533.00391 +Albania,1982,2780097,Europe,70.42,3630.880722 +Albania,1987,3075321,Europe,72,3738.932735 +Albania,1992,3326498,Europe,71.581,2497.437901 +Albania,1997,3428038,Europe,72.95,3193.054604 +Albania,2002,3508512,Europe,75.651,4604.211737 +Albania,2007,3600523,Europe,76.423,5937.029526 +Algeria,1952,9279525,Africa,43.077,2449.008185 +Algeria,1957,10270856,Africa,45.685,3013.976023 +Algeria,1962,11000948,Africa,48.303,2550.81688 +Algeria,1967,12760499,Africa,51.407,3246.991771 +Algeria,1972,14760787,Africa,54.518,4182.663766 +Algeria,1977,17152804,Africa,58.014,4910.416756 +Algeria,1982,20033753,Africa,61.368,5745.160213 +Algeria,1987,23254956,Africa,65.799,5681.358539 +Algeria,1992,26298373,Africa,67.744,5023.216647 +Algeria,1997,29072015,Africa,69.152,4797.295051 +Algeria,2002,31287142,Africa,70.994,5288.040382 +Algeria,2007,33333216,Africa,72.301,6223.367465 +Angola,1952,4232095,Africa,30.015,3520.610273 +Angola,1957,4561361,Africa,31.999,3827.940465 +Angola,1962,4826015,Africa,34,4269.276742 +Angola,1967,5247469,Africa,35.985,5522.776375 +Angola,1972,5894858,Africa,37.928,5473.288005 +Angola,1977,6162675,Africa,39.483,3008.647355 +Angola,1982,7016384,Africa,39.942,2756.953672 +Angola,1987,7874230,Africa,39.906,2430.208311 +Angola,1992,8735988,Africa,40.647,2627.845685 +Angola,1997,9875024,Africa,40.963,2277.140884 +Angola,2002,10866106,Africa,41.003,2773.287312 +Angola,2007,12420476,Africa,42.731,4797.231267 +Argentina,1952,17876956,Americas,62.485,5911.315053 +Argentina,1957,19610538,Americas,64.399,6856.856212 +Argentina,1962,21283783,Americas,65.142,7133.166023 +Argentina,1967,22934225,Americas,65.634,8052.953021 +Argentina,1972,24779799,Americas,67.065,9443.038526 +Argentina,1977,26983828,Americas,68.481,10079.02674 +Argentina,1982,29341374,Americas,69.942,8997.897412 +Argentina,1987,31620918,Americas,70.774,9139.671389 +Argentina,1992,33958947,Americas,71.868,9308.41871 +Argentina,1997,36203463,Americas,73.275,10967.28195 +Argentina,2002,38331121,Americas,74.34,8797.640716 +Argentina,2007,40301927,Americas,75.32,12779.37964 +Australia,1952,8691212,Oceania,69.12,10039.59564 +Australia,1957,9712569,Oceania,70.33,10949.64959 +Australia,1962,10794968,Oceania,70.93,12217.22686 +Australia,1967,11872264,Oceania,71.1,14526.12465 +Australia,1972,13177000,Oceania,71.93,16788.62948 +Australia,1977,14074100,Oceania,73.49,18334.19751 +Australia,1982,15184200,Oceania,74.74,19477.00928 +Australia,1987,16257249,Oceania,76.32,21888.88903 +Australia,1992,17481977,Oceania,77.56,23424.76683 +Australia,1997,18565243,Oceania,78.83,26997.93657 +Australia,2002,19546792,Oceania,80.37,30687.75473 +Australia,2007,20434176,Oceania,81.235,34435.36744 +Austria,1952,6927772,Europe,66.8,6137.076492 +Austria,1957,6965860,Europe,67.48,8842.59803 +Austria,1962,7129864,Europe,69.54,10750.72111 +Austria,1967,7376998,Europe,70.14,12834.6024 +Austria,1972,7544201,Europe,70.63,16661.6256 +Austria,1977,7568430,Europe,72.17,19749.4223 +Austria,1982,7574613,Europe,73.18,21597.08362 +Austria,1987,7578903,Europe,74.94,23687.82607 +Austria,1992,7914969,Europe,76.04,27042.01868 +Austria,1997,8069876,Europe,77.51,29095.92066 +Austria,2002,8148312,Europe,78.98,32417.60769 +Austria,2007,8199783,Europe,79.829,36126.4927 +Bahrain,1952,120447,Asia,50.939,9867.084765 +Bahrain,1957,138655,Asia,53.832,11635.79945 +Bahrain,1962,171863,Asia,56.923,12753.27514 +Bahrain,1967,202182,Asia,59.923,14804.6727 +Bahrain,1972,230800,Asia,63.3,18268.65839 +Bahrain,1977,297410,Asia,65.593,19340.10196 +Bahrain,1982,377967,Asia,69.052,19211.14731 +Bahrain,1987,454612,Asia,70.75,18524.02406 +Bahrain,1992,529491,Asia,72.601,19035.57917 +Bahrain,1997,598561,Asia,73.925,20292.01679 +Bahrain,2002,656397,Asia,74.795,23403.55927 +Bahrain,2007,708573,Asia,75.635,29796.04834 +Bangladesh,1952,46886859,Asia,37.484,684.2441716 +Bangladesh,1957,51365468,Asia,39.348,661.6374577 +Bangladesh,1962,56839289,Asia,41.216,686.3415538 +Bangladesh,1967,62821884,Asia,43.453,721.1860862 +Bangladesh,1972,70759295,Asia,45.252,630.2336265 +Bangladesh,1977,80428306,Asia,46.923,659.8772322 +Bangladesh,1982,93074406,Asia,50.009,676.9818656 +Bangladesh,1987,103764241,Asia,52.819,751.9794035 +Bangladesh,1992,113704579,Asia,56.018,837.8101643 +Bangladesh,1997,123315288,Asia,59.412,972.7700352 +Bangladesh,2002,135656790,Asia,62.013,1136.39043 +Bangladesh,2007,150448339,Asia,64.062,1391.253792 +Belgium,1952,8730405,Europe,68,8343.105127 +Belgium,1957,8989111,Europe,69.24,9714.960623 +Belgium,1962,9218400,Europe,70.25,10991.20676 +Belgium,1967,9556500,Europe,70.94,13149.04119 +Belgium,1972,9709100,Europe,71.44,16672.14356 +Belgium,1977,9821800,Europe,72.8,19117.97448 +Belgium,1982,9856303,Europe,73.93,20979.84589 +Belgium,1987,9870200,Europe,75.35,22525.56308 +Belgium,1992,10045622,Europe,76.46,25575.57069 +Belgium,1997,10199787,Europe,77.53,27561.19663 +Belgium,2002,10311970,Europe,78.32,30485.88375 +Belgium,2007,10392226,Europe,79.441,33692.60508 +Benin,1952,1738315,Africa,38.223,1062.7522 +Benin,1957,1925173,Africa,40.358,959.6010805 +Benin,1962,2151895,Africa,42.618,949.4990641 +Benin,1967,2427334,Africa,44.885,1035.831411 +Benin,1972,2761407,Africa,47.014,1085.796879 +Benin,1977,3168267,Africa,49.19,1029.161251 +Benin,1982,3641603,Africa,50.904,1277.897616 +Benin,1987,4243788,Africa,52.337,1225.85601 +Benin,1992,4981671,Africa,53.919,1191.207681 +Benin,1997,6066080,Africa,54.777,1232.975292 +Benin,2002,7026113,Africa,54.406,1372.877931 +Benin,2007,8078314,Africa,56.728,1441.284873 +Bolivia,1952,2883315,Americas,40.414,2677.326347 +Bolivia,1957,3211738,Americas,41.89,2127.686326 +Bolivia,1962,3593918,Americas,43.428,2180.972546 +Bolivia,1967,4040665,Americas,45.032,2586.886053 +Bolivia,1972,4565872,Americas,46.714,2980.331339 +Bolivia,1977,5079716,Americas,50.023,3548.097832 +Bolivia,1982,5642224,Americas,53.859,3156.510452 +Bolivia,1987,6156369,Americas,57.251,2753.69149 +Bolivia,1992,6893451,Americas,59.957,2961.699694 +Bolivia,1997,7693188,Americas,62.05,3326.143191 +Bolivia,2002,8445134,Americas,63.883,3413.26269 +Bolivia,2007,9119152,Americas,65.554,3822.137084 +Bosnia and Herzegovina,1952,2791000,Europe,53.82,973.5331948 +Bosnia and Herzegovina,1957,3076000,Europe,58.45,1353.989176 +Bosnia and Herzegovina,1962,3349000,Europe,61.93,1709.683679 +Bosnia and Herzegovina,1967,3585000,Europe,64.79,2172.352423 +Bosnia and Herzegovina,1972,3819000,Europe,67.45,2860.16975 +Bosnia and Herzegovina,1977,4086000,Europe,69.86,3528.481305 +Bosnia and Herzegovina,1982,4172693,Europe,70.69,4126.613157 +Bosnia and Herzegovina,1987,4338977,Europe,71.14,4314.114757 +Bosnia and Herzegovina,1992,4256013,Europe,72.178,2546.781445 +Bosnia and Herzegovina,1997,3607000,Europe,73.244,4766.355904 +Bosnia and Herzegovina,2002,4165416,Europe,74.09,6018.975239 +Bosnia and Herzegovina,2007,4552198,Europe,74.852,7446.298803 +Botswana,1952,442308,Africa,47.622,851.2411407 +Botswana,1957,474639,Africa,49.618,918.2325349 +Botswana,1962,512764,Africa,51.52,983.6539764 +Botswana,1967,553541,Africa,53.298,1214.709294 +Botswana,1972,619351,Africa,56.024,2263.611114 +Botswana,1977,781472,Africa,59.319,3214.857818 +Botswana,1982,970347,Africa,61.484,4551.14215 +Botswana,1987,1151184,Africa,63.622,6205.88385 +Botswana,1992,1342614,Africa,62.745,7954.111645 +Botswana,1997,1536536,Africa,52.556,8647.142313 +Botswana,2002,1630347,Africa,46.634,11003.60508 +Botswana,2007,1639131,Africa,50.728,12569.85177 +Brazil,1952,56602560,Americas,50.917,2108.944355 +Brazil,1957,65551171,Americas,53.285,2487.365989 +Brazil,1962,76039390,Americas,55.665,3336.585802 +Brazil,1967,88049823,Americas,57.632,3429.864357 +Brazil,1972,100840058,Americas,59.504,4985.711467 +Brazil,1977,114313951,Americas,61.489,6660.118654 +Brazil,1982,128962939,Americas,63.336,7030.835878 +Brazil,1987,142938076,Americas,65.205,7807.095818 +Brazil,1992,155975974,Americas,67.057,6950.283021 +Brazil,1997,168546719,Americas,69.388,7957.980824 +Brazil,2002,179914212,Americas,71.006,8131.212843 +Brazil,2007,190010647,Americas,72.39,9065.800825 +Bulgaria,1952,7274900,Europe,59.6,2444.286648 +Bulgaria,1957,7651254,Europe,66.61,3008.670727 +Bulgaria,1962,8012946,Europe,69.51,4254.337839 +Bulgaria,1967,8310226,Europe,70.42,5577.0028 +Bulgaria,1972,8576200,Europe,70.9,6597.494398 +Bulgaria,1977,8797022,Europe,70.81,7612.240438 +Bulgaria,1982,8892098,Europe,71.08,8224.191647 +Bulgaria,1987,8971958,Europe,71.34,8239.854824 +Bulgaria,1992,8658506,Europe,71.19,6302.623438 +Bulgaria,1997,8066057,Europe,70.32,5970.38876 +Bulgaria,2002,7661799,Europe,72.14,7696.777725 +Bulgaria,2007,7322858,Europe,73.005,10680.79282 +Burkina Faso,1952,4469979,Africa,31.975,543.2552413 +Burkina Faso,1957,4713416,Africa,34.906,617.1834648 +Burkina Faso,1962,4919632,Africa,37.814,722.5120206 +Burkina Faso,1967,5127935,Africa,40.697,794.8265597 +Burkina Faso,1972,5433886,Africa,43.591,854.7359763 +Burkina Faso,1977,5889574,Africa,46.137,743.3870368 +Burkina Faso,1982,6634596,Africa,48.122,807.1985855 +Burkina Faso,1987,7586551,Africa,49.557,912.0631417 +Burkina Faso,1992,8878303,Africa,50.26,931.7527731 +Burkina Faso,1997,10352843,Africa,50.324,946.2949618 +Burkina Faso,2002,12251209,Africa,50.65,1037.645221 +Burkina Faso,2007,14326203,Africa,52.295,1217.032994 +Burundi,1952,2445618,Africa,39.031,339.2964587 +Burundi,1957,2667518,Africa,40.533,379.5646281 +Burundi,1962,2961915,Africa,42.045,355.2032273 +Burundi,1967,3330989,Africa,43.548,412.9775136 +Burundi,1972,3529983,Africa,44.057,464.0995039 +Burundi,1977,3834415,Africa,45.91,556.1032651 +Burundi,1982,4580410,Africa,47.471,559.603231 +Burundi,1987,5126023,Africa,48.211,621.8188189 +Burundi,1992,5809236,Africa,44.736,631.6998778 +Burundi,1997,6121610,Africa,45.326,463.1151478 +Burundi,2002,7021078,Africa,47.36,446.4035126 +Burundi,2007,8390505,Africa,49.58,430.0706916 +Cambodia,1952,4693836,Asia,39.417,368.4692856 +Cambodia,1957,5322536,Asia,41.366,434.0383364 +Cambodia,1962,6083619,Asia,43.415,496.9136476 +Cambodia,1967,6960067,Asia,45.415,523.4323142 +Cambodia,1972,7450606,Asia,40.317,421.6240257 +Cambodia,1977,6978607,Asia,31.22,524.9721832 +Cambodia,1982,7272485,Asia,50.957,624.4754784 +Cambodia,1987,8371791,Asia,53.914,683.8955732 +Cambodia,1992,10150094,Asia,55.803,682.3031755 +Cambodia,1997,11782962,Asia,56.534,734.28517 +Cambodia,2002,12926707,Asia,56.752,896.2260153 +Cambodia,2007,14131858,Asia,59.723,1713.778686 +Cameroon,1952,5009067,Africa,38.523,1172.667655 +Cameroon,1957,5359923,Africa,40.428,1313.048099 +Cameroon,1962,5793633,Africa,42.643,1399.607441 +Cameroon,1967,6335506,Africa,44.799,1508.453148 +Cameroon,1972,7021028,Africa,47.049,1684.146528 +Cameroon,1977,7959865,Africa,49.355,1783.432873 +Cameroon,1982,9250831,Africa,52.961,2367.983282 +Cameroon,1987,10780667,Africa,54.985,2602.664206 +Cameroon,1992,12467171,Africa,54.314,1793.163278 +Cameroon,1997,14195809,Africa,52.199,1694.337469 +Cameroon,2002,15929988,Africa,49.856,1934.011449 +Cameroon,2007,17696293,Africa,50.43,2042.09524 +Canada,1952,14785584,Americas,68.75,11367.16112 +Canada,1957,17010154,Americas,69.96,12489.95006 +Canada,1962,18985849,Americas,71.3,13462.48555 +Canada,1967,20819767,Americas,72.13,16076.58803 +Canada,1972,22284500,Americas,72.88,18970.57086 +Canada,1977,23796400,Americas,74.21,22090.88306 +Canada,1982,25201900,Americas,75.76,22898.79214 +Canada,1987,26549700,Americas,76.86,26626.51503 +Canada,1992,28523502,Americas,77.95,26342.88426 +Canada,1997,30305843,Americas,78.61,28954.92589 +Canada,2002,31902268,Americas,79.77,33328.96507 +Canada,2007,33390141,Americas,80.653,36319.23501 +Central African Republic,1952,1291695,Africa,35.463,1071.310713 +Central African Republic,1957,1392284,Africa,37.464,1190.844328 +Central African Republic,1962,1523478,Africa,39.475,1193.068753 +Central African Republic,1967,1733638,Africa,41.478,1136.056615 +Central African Republic,1972,1927260,Africa,43.457,1070.013275 +Central African Republic,1977,2167533,Africa,46.775,1109.374338 +Central African Republic,1982,2476971,Africa,48.295,956.7529907 +Central African Republic,1987,2840009,Africa,50.485,844.8763504 +Central African Republic,1992,3265124,Africa,49.396,747.9055252 +Central African Republic,1997,3696513,Africa,46.066,740.5063317 +Central African Republic,2002,4048013,Africa,43.308,738.6906068 +Central African Republic,2007,4369038,Africa,44.741,706.016537 +Chad,1952,2682462,Africa,38.092,1178.665927 +Chad,1957,2894855,Africa,39.881,1308.495577 +Chad,1962,3150417,Africa,41.716,1389.817618 +Chad,1967,3495967,Africa,43.601,1196.810565 +Chad,1972,3899068,Africa,45.569,1104.103987 +Chad,1977,4388260,Africa,47.383,1133.98495 +Chad,1982,4875118,Africa,49.517,797.9081006 +Chad,1987,5498955,Africa,51.051,952.386129 +Chad,1992,6429417,Africa,51.724,1058.0643 +Chad,1997,7562011,Africa,51.573,1004.961353 +Chad,2002,8835739,Africa,50.525,1156.18186 +Chad,2007,10238807,Africa,50.651,1704.063724 +Chile,1952,6377619,Americas,54.745,3939.978789 +Chile,1957,7048426,Americas,56.074,4315.622723 +Chile,1962,7961258,Americas,57.924,4519.094331 +Chile,1967,8858908,Americas,60.523,5106.654313 +Chile,1972,9717524,Americas,63.441,5494.024437 +Chile,1977,10599793,Americas,67.052,4756.763836 +Chile,1982,11487112,Americas,70.565,5095.665738 +Chile,1987,12463354,Americas,72.492,5547.063754 +Chile,1992,13572994,Americas,74.126,7596.125964 +Chile,1997,14599929,Americas,75.816,10118.05318 +Chile,2002,15497046,Americas,77.86,10778.78385 +Chile,2007,16284741,Americas,78.553,13171.63885 +China,1952,556263527.999989,Asia,44,400.448610699994 +China,1957,637408000,Asia,50.54896,575.9870009 +China,1962,665770000,Asia,44.50136,487.6740183 +China,1967,754550000,Asia,58.38112,612.7056934 +China,1972,862030000,Asia,63.11888,676.9000921 +China,1977,943455000,Asia,63.96736,741.2374699 +China,1982,1000281000,Asia,65.525,962.4213805 +China,1987,1084035000,Asia,67.274,1378.904018 +China,1992,1164970000,Asia,68.69,1655.784158 +China,1997,1230075000,Asia,70.426,2289.234136 +China,2002,1280400000,Asia,72.028,3119.280896 +China,2007,1318683096,Asia,72.961,4959.114854 +Colombia,1952,12350771,Americas,50.643,2144.115096 +Colombia,1957,14485993,Americas,55.118,2323.805581 +Colombia,1962,17009885,Americas,57.863,2492.351109 +Colombia,1967,19764027,Americas,59.963,2678.729839 +Colombia,1972,22542890,Americas,61.623,3264.660041 +Colombia,1977,25094412,Americas,63.837,3815.80787 +Colombia,1982,27764644,Americas,66.653,4397.575659 +Colombia,1987,30964245,Americas,67.768,4903.2191 +Colombia,1992,34202721,Americas,68.421,5444.648617 +Colombia,1997,37657830,Americas,70.313,6117.361746 +Colombia,2002,41008227,Americas,71.682,5755.259962 +Colombia,2007,44227550,Americas,72.889,7006.580419 +Comoros,1952,153936,Africa,40.715,1102.990936 +Comoros,1957,170928,Africa,42.46,1211.148548 +Comoros,1962,191689,Africa,44.467,1406.648278 +Comoros,1967,217378,Africa,46.472,1876.029643 +Comoros,1972,250027,Africa,48.944,1937.577675 +Comoros,1977,304739,Africa,50.939,1172.603047 +Comoros,1982,348643,Africa,52.933,1267.100083 +Comoros,1987,395114,Africa,54.926,1315.980812 +Comoros,1992,454429,Africa,57.939,1246.90737 +Comoros,1997,527982,Africa,60.66,1173.618235 +Comoros,2002,614382,Africa,62.974,1075.811558 +Comoros,2007,710960,Africa,65.152,986.1478792 +Congo Dem. Rep.,1952,14100005,Africa,39.143,780.5423257 +Congo Dem. Rep.,1957,15577932,Africa,40.652,905.8602303 +Congo Dem. Rep.,1962,17486434,Africa,42.122,896.3146335 +Congo Dem. Rep.,1967,19941073,Africa,44.056,861.5932424 +Congo Dem. Rep.,1972,23007669,Africa,45.989,904.8960685 +Congo Dem. Rep.,1977,26480870,Africa,47.804,795.757282 +Congo Dem. Rep.,1982,30646495,Africa,47.784,673.7478181 +Congo Dem. Rep.,1987,35481645,Africa,47.412,672.774812 +Congo Dem. Rep.,1992,41672143,Africa,45.548,457.7191807 +Congo Dem. Rep.,1997,47798986,Africa,42.587,312.188423 +Congo Dem. Rep.,2002,55379852,Africa,44.966,241.1658765 +Congo Dem. Rep.,2007,64606759,Africa,46.462,277.5518587 +Congo Rep.,1952,854885,Africa,42.111,2125.621418 +Congo Rep.,1957,940458,Africa,45.053,2315.056572 +Congo Rep.,1962,1047924,Africa,48.435,2464.783157 +Congo Rep.,1967,1179760,Africa,52.04,2677.939642 +Congo Rep.,1972,1340458,Africa,54.907,3213.152683 +Congo Rep.,1977,1536769,Africa,55.625,3259.178978 +Congo Rep.,1982,1774735,Africa,56.695,4879.507522 +Congo Rep.,1987,2064095,Africa,57.47,4201.194937 +Congo Rep.,1992,2409073,Africa,56.433,4016.239529 +Congo Rep.,1997,2800947,Africa,52.962,3484.164376 +Congo Rep.,2002,3328795,Africa,52.97,3484.06197 +Congo Rep.,2007,3800610,Africa,55.322,3632.557798 +Costa Rica,1952,926317,Americas,57.206,2627.009471 +Costa Rica,1957,1112300,Americas,60.026,2990.010802 +Costa Rica,1962,1345187,Americas,62.842,3460.937025 +Costa Rica,1967,1588717,Americas,65.424,4161.727834 +Costa Rica,1972,1834796,Americas,67.849,5118.146939 +Costa Rica,1977,2108457,Americas,70.75,5926.876967 +Costa Rica,1982,2424367,Americas,73.45,5262.734751 +Costa Rica,1987,2799811,Americas,74.752,5629.915318 +Costa Rica,1992,3173216,Americas,75.713,6160.416317 +Costa Rica,1997,3518107,Americas,77.26,6677.045314 +Costa Rica,2002,3834934,Americas,78.123,7723.447195 +Costa Rica,2007,4133884,Americas,78.782,9645.06142 +"Cote d'Ivoire",1952,2977019,Africa,40.477,1388.594732 +"Cote d'Ivoire",1957,3300000,Africa,42.469,1500.895925 +"Cote d'Ivoire",1962,3832408,Africa,44.93,1728.869428 +"Cote d'Ivoire",1967,4744870,Africa,47.35,2052.050473 +"Cote d'Ivoire",1972,6071696,Africa,49.801,2378.201111 +"Cote d'Ivoire",1977,7459574,Africa,52.374,2517.736547 +"Cote d'Ivoire",1982,9025951,Africa,53.983,2602.710169 +"Cote d'Ivoire",1987,10761098,Africa,54.655,2156.956069 +"Cote d'Ivoire",1992,12772596,Africa,52.044,1648.073791 +"Cote d'Ivoire",1997,14625967,Africa,47.991,1786.265407 +"Cote d'Ivoire",2002,16252726,Africa,46.832,1648.800823 +"Cote d'Ivoire",2007,18013409,Africa,48.328,1544.750112 +Croatia,1952,3882229,Europe,61.21,3119.23652 +Croatia,1957,3991242,Europe,64.77,4338.231617 +Croatia,1962,4076557,Europe,67.13,5477.890018 +Croatia,1967,4174366,Europe,68.5,6960.297861 +Croatia,1972,4225310,Europe,69.61,9164.090127 +Croatia,1977,4318673,Europe,70.64,11305.38517 +Croatia,1982,4413368,Europe,70.46,13221.82184 +Croatia,1987,4484310,Europe,71.52,13822.58394 +Croatia,1992,4494013,Europe,72.527,8447.794873 +Croatia,1997,4444595,Europe,73.68,9875.604515 +Croatia,2002,4481020,Europe,74.876,11628.38895 +Croatia,2007,4493312,Europe,75.748,14619.22272 +Cuba,1952,6007797,Americas,59.421,5586.53878 +Cuba,1957,6640752,Americas,62.325,6092.174359 +Cuba,1962,7254373,Americas,65.246,5180.75591 +Cuba,1967,8139332,Americas,68.29,5690.268015 +Cuba,1972,8831348,Americas,70.723,5305.445256 +Cuba,1977,9537988,Americas,72.649,6380.494966 +Cuba,1982,9789224,Americas,73.717,7316.918107 +Cuba,1987,10239839,Americas,74.174,7532.924763 +Cuba,1992,10723260,Americas,74.414,5592.843963 +Cuba,1997,10983007,Americas,76.151,5431.990415 +Cuba,2002,11226999,Americas,77.158,6340.646683 +Cuba,2007,11416987,Americas,78.273,8948.102923 +Czech Republic,1952,9125183,Europe,66.87,6876.14025 +Czech Republic,1957,9513758,Europe,69.03,8256.343918 +Czech Republic,1962,9620282,Europe,69.9,10136.86713 +Czech Republic,1967,9835109,Europe,70.38,11399.44489 +Czech Republic,1972,9862158,Europe,70.29,13108.4536 +Czech Republic,1977,10161915,Europe,70.71,14800.16062 +Czech Republic,1982,10303704,Europe,70.96,15377.22855 +Czech Republic,1987,10311597,Europe,71.58,16310.4434 +Czech Republic,1992,10315702,Europe,72.4,14297.02122 +Czech Republic,1997,10300707,Europe,74.01,16048.51424 +Czech Republic,2002,10256295,Europe,75.51,17596.21022 +Czech Republic,2007,10228744,Europe,76.486,22833.30851 +Denmark,1952,4334000,Europe,70.78,9692.385245 +Denmark,1957,4487831,Europe,71.81,11099.65935 +Denmark,1962,4646899,Europe,72.35,13583.31351 +Denmark,1967,4838800,Europe,72.96,15937.21123 +Denmark,1972,4991596,Europe,73.47,18866.20721 +Denmark,1977,5088419,Europe,74.69,20422.9015 +Denmark,1982,5117810,Europe,74.63,21688.04048 +Denmark,1987,5127024,Europe,74.8,25116.17581 +Denmark,1992,5171393,Europe,75.33,26406.73985 +Denmark,1997,5283663,Europe,76.11,29804.34567 +Denmark,2002,5374693,Europe,77.18,32166.50006 +Denmark,2007,5468120,Europe,78.332,35278.41874 +Djibouti,1952,63149,Africa,34.812,2669.529475 +Djibouti,1957,71851,Africa,37.328,2864.969076 +Djibouti,1962,89898,Africa,39.693,3020.989263 +Djibouti,1967,127617,Africa,42.074,3020.050513 +Djibouti,1972,178848,Africa,44.366,3694.212352 +Djibouti,1977,228694,Africa,46.519,3081.761022 +Djibouti,1982,305991,Africa,48.812,2879.468067 +Djibouti,1987,311025,Africa,50.04,2880.102568 +Djibouti,1992,384156,Africa,51.604,2377.156192 +Djibouti,1997,417908,Africa,53.157,1895.016984 +Djibouti,2002,447416,Africa,53.373,1908.260867 +Djibouti,2007,496374,Africa,54.791,2082.481567 +Dominican Republic,1952,2491346,Americas,45.928,1397.717137 +Dominican Republic,1957,2923186,Americas,49.828,1544.402995 +Dominican Republic,1962,3453434,Americas,53.459,1662.137359 +Dominican Republic,1967,4049146,Americas,56.751,1653.723003 +Dominican Republic,1972,4671329,Americas,59.631,2189.874499 +Dominican Republic,1977,5302800,Americas,61.788,2681.9889 +Dominican Republic,1982,5968349,Americas,63.727,2861.092386 +Dominican Republic,1987,6655297,Americas,66.046,2899.842175 +Dominican Republic,1992,7351181,Americas,68.457,3044.214214 +Dominican Republic,1997,7992357,Americas,69.957,3614.101285 +Dominican Republic,2002,8650322,Americas,70.847,4563.808154 +Dominican Republic,2007,9319622,Americas,72.235,6025.374752 +Ecuador,1952,3548753,Americas,48.357,3522.110717 +Ecuador,1957,4058385,Americas,51.356,3780.546651 +Ecuador,1962,4681707,Americas,54.64,4086.114078 +Ecuador,1967,5432424,Americas,56.678,4579.074215 +Ecuador,1972,6298651,Americas,58.796,5280.99471 +Ecuador,1977,7278866,Americas,61.31,6679.62326 +Ecuador,1982,8365850,Americas,64.342,7213.791267 +Ecuador,1987,9545158,Americas,67.231,6481.776993 +Ecuador,1992,10748394,Americas,69.613,7103.702595 +Ecuador,1997,11911819,Americas,72.312,7429.455877 +Ecuador,2002,12921234,Americas,74.173,5773.044512 +Ecuador,2007,13755680,Americas,74.994,6873.262326 +Egypt,1952,22223309,Africa,41.893,1418.822445 +Egypt,1957,25009741,Africa,44.444,1458.915272 +Egypt,1962,28173309,Africa,46.992,1693.335853 +Egypt,1967,31681188,Africa,49.293,1814.880728 +Egypt,1972,34807417,Africa,51.137,2024.008147 +Egypt,1977,38783863,Africa,53.319,2785.493582 +Egypt,1982,45681811,Africa,56.006,3503.729636 +Egypt,1987,52799062,Africa,59.797,3885.46071 +Egypt,1992,59402198,Africa,63.674,3794.755195 +Egypt,1997,66134291,Africa,67.217,4173.181797 +Egypt,2002,73312559,Africa,69.806,4754.604414 +Egypt,2007,80264543,Africa,71.338,5581.180998 +El Salvador,1952,2042865,Americas,45.262,3048.3029 +El Salvador,1957,2355805,Americas,48.57,3421.523218 +El Salvador,1962,2747687,Americas,52.307,3776.803627 +El Salvador,1967,3232927,Americas,55.855,4358.595393 +El Salvador,1972,3790903,Americas,58.207,4520.246008 +El Salvador,1977,4282586,Americas,56.696,5138.922374 +El Salvador,1982,4474873,Americas,56.604,4098.344175 +El Salvador,1987,4842194,Americas,63.154,4140.442097 +El Salvador,1992,5274649,Americas,66.798,4444.2317 +El Salvador,1997,5783439,Americas,69.535,5154.825496 +El Salvador,2002,6353681,Americas,70.734,5351.568666 +El Salvador,2007,6939688,Americas,71.878,5728.353514 +Equatorial Guinea,1952,216964,Africa,34.482,375.6431231 +Equatorial Guinea,1957,232922,Africa,35.983,426.0964081 +Equatorial Guinea,1962,249220,Africa,37.485,582.8419714 +Equatorial Guinea,1967,259864,Africa,38.987,915.5960025 +Equatorial Guinea,1972,277603,Africa,40.516,672.4122571 +Equatorial Guinea,1977,192675,Africa,42.024,958.5668124 +Equatorial Guinea,1982,285483,Africa,43.662,927.8253427 +Equatorial Guinea,1987,341244,Africa,45.664,966.8968149 +Equatorial Guinea,1992,387838,Africa,47.545,1132.055034 +Equatorial Guinea,1997,439971,Africa,48.245,2814.480755 +Equatorial Guinea,2002,495627,Africa,49.348,7703.4959 +Equatorial Guinea,2007,551201,Africa,51.579,12154.08975 +Eritrea,1952,1438760,Africa,35.928,328.9405571 +Eritrea,1957,1542611,Africa,38.047,344.1618859 +Eritrea,1962,1666618,Africa,40.158,380.9958433 +Eritrea,1967,1820319,Africa,42.189,468.7949699 +Eritrea,1972,2260187,Africa,44.142,514.3242082 +Eritrea,1977,2512642,Africa,44.535,505.7538077 +Eritrea,1982,2637297,Africa,43.89,524.8758493 +Eritrea,1987,2915959,Africa,46.453,521.1341333 +Eritrea,1992,3668440,Africa,49.991,582.8585102 +Eritrea,1997,4058319,Africa,53.378,913.47079 +Eritrea,2002,4414865,Africa,55.24,765.3500015 +Eritrea,2007,4906585,Africa,58.04,641.3695236 +Ethiopia,1952,20860941,Africa,34.078,362.1462796 +Ethiopia,1957,22815614,Africa,36.667,378.9041632 +Ethiopia,1962,25145372,Africa,40.059,419.4564161 +Ethiopia,1967,27860297,Africa,42.115,516.1186438 +Ethiopia,1972,30770372,Africa,43.515,566.2439442 +Ethiopia,1977,34617799,Africa,44.51,556.8083834 +Ethiopia,1982,38111756,Africa,44.916,577.8607471 +Ethiopia,1987,42999530,Africa,46.684,573.7413142 +Ethiopia,1992,52088559,Africa,48.091,421.3534653 +Ethiopia,1997,59861301,Africa,49.402,515.8894013 +Ethiopia,2002,67946797,Africa,50.725,530.0535319 +Ethiopia,2007,76511887,Africa,52.947,690.8055759 +Finland,1952,4090500,Europe,66.55,6424.519071 +Finland,1957,4324000,Europe,67.49,7545.415386 +Finland,1962,4491443,Europe,68.75,9371.842561 +Finland,1967,4605744,Europe,69.83,10921.63626 +Finland,1972,4639657,Europe,70.87,14358.8759 +Finland,1977,4738902,Europe,72.52,15605.42283 +Finland,1982,4826933,Europe,74.55,18533.15761 +Finland,1987,4931729,Europe,74.83,21141.01223 +Finland,1992,5041039,Europe,75.7,20647.16499 +Finland,1997,5134406,Europe,77.13,23723.9502 +Finland,2002,5193039,Europe,78.37,28204.59057 +Finland,2007,5238460,Europe,79.313,33207.0844 +France,1952,42459667,Europe,67.41,7029.809327 +France,1957,44310863,Europe,68.93,8662.834898 +France,1962,47124000,Europe,70.51,10560.48553 +France,1967,49569000,Europe,71.55,12999.91766 +France,1972,51732000,Europe,72.38,16107.19171 +France,1977,53165019,Europe,73.83,18292.63514 +France,1982,54433565,Europe,74.89,20293.89746 +France,1987,55630100,Europe,76.34,22066.44214 +France,1992,57374179,Europe,77.46,24703.79615 +France,1997,58623428,Europe,78.64,25889.78487 +France,2002,59925035,Europe,79.59,28926.03234 +France,2007,61083916,Europe,80.657,30470.0167 +Gabon,1952,420702,Africa,37.003,4293.476475 +Gabon,1957,434904,Africa,38.999,4976.198099 +Gabon,1962,455661,Africa,40.489,6631.459222 +Gabon,1967,489004,Africa,44.598,8358.761987 +Gabon,1972,537977,Africa,48.69,11401.94841 +Gabon,1977,706367,Africa,52.79,21745.57328 +Gabon,1982,753874,Africa,56.564,15113.36194 +Gabon,1987,880397,Africa,60.19,11864.40844 +Gabon,1992,985739,Africa,61.366,13522.15752 +Gabon,1997,1126189,Africa,60.461,14722.84188 +Gabon,2002,1299304,Africa,56.761,12521.71392 +Gabon,2007,1454867,Africa,56.735,13206.48452 +Gambia,1952,284320,Africa,30,485.2306591 +Gambia,1957,323150,Africa,32.065,520.9267111 +Gambia,1962,374020,Africa,33.896,599.650276 +Gambia,1967,439593,Africa,35.857,734.7829124 +Gambia,1972,517101,Africa,38.308,756.0868363 +Gambia,1977,608274,Africa,41.842,884.7552507 +Gambia,1982,715523,Africa,45.58,835.8096108 +Gambia,1987,848406,Africa,49.265,611.6588611 +Gambia,1992,1025384,Africa,52.644,665.6244126 +Gambia,1997,1235767,Africa,55.861,653.7301704 +Gambia,2002,1457766,Africa,58.041,660.5855997 +Gambia,2007,1688359,Africa,59.448,752.7497265 +Germany,1952,69145952,Europe,67.5,7144.114393 +Germany,1957,71019069,Europe,69.1,10187.82665 +Germany,1962,73739117,Europe,70.3,12902.46291 +Germany,1967,76368453,Europe,70.8,14745.62561 +Germany,1972,78717088,Europe,71,18016.18027 +Germany,1977,78160773,Europe,72.5,20512.92123 +Germany,1982,78335266,Europe,73.8,22031.53274 +Germany,1987,77718298,Europe,74.847,24639.18566 +Germany,1992,80597764,Europe,76.07,26505.30317 +Germany,1997,82011073,Europe,77.34,27788.88416 +Germany,2002,82350671,Europe,78.67,30035.80198 +Germany,2007,82400996,Europe,79.406,32170.37442 +Ghana,1952,5581001,Africa,43.149,911.2989371 +Ghana,1957,6391288,Africa,44.779,1043.561537 +Ghana,1962,7355248,Africa,46.452,1190.041118 +Ghana,1967,8490213,Africa,48.072,1125.69716 +Ghana,1972,9354120,Africa,49.875,1178.223708 +Ghana,1977,10538093,Africa,51.756,993.2239571 +Ghana,1982,11400338,Africa,53.744,876.032569 +Ghana,1987,14168101,Africa,55.729,847.0061135 +Ghana,1992,16278738,Africa,57.501,925.060154 +Ghana,1997,18418288,Africa,58.556,1005.245812 +Ghana,2002,20550751,Africa,58.453,1111.984578 +Ghana,2007,22873338,Africa,60.022,1327.60891 +Greece,1952,7733250,Europe,65.86,3530.690067 +Greece,1957,8096218,Europe,67.86,4916.299889 +Greece,1962,8448233,Europe,69.51,6017.190733 +Greece,1967,8716441,Europe,71,8513.097016 +Greece,1972,8888628,Europe,72.34,12724.82957 +Greece,1977,9308479,Europe,73.68,14195.52428 +Greece,1982,9786480,Europe,75.24,15268.42089 +Greece,1987,9974490,Europe,76.67,16120.52839 +Greece,1992,10325429,Europe,77.03,17541.49634 +Greece,1997,10502372,Europe,77.869,18747.69814 +Greece,2002,10603863,Europe,78.256,22514.2548 +Greece,2007,10706290,Europe,79.483,27538.41188 +Guatemala,1952,3146381,Americas,42.023,2428.237769 +Guatemala,1957,3640876,Americas,44.142,2617.155967 +Guatemala,1962,4208858,Americas,46.954,2750.364446 +Guatemala,1967,4690773,Americas,50.016,3242.531147 +Guatemala,1972,5149581,Americas,53.738,4031.408271 +Guatemala,1977,5703430,Americas,56.029,4879.992748 +Guatemala,1982,6395630,Americas,58.137,4820.49479 +Guatemala,1987,7326406,Americas,60.782,4246.485974 +Guatemala,1992,8486949,Americas,63.373,4439.45084 +Guatemala,1997,9803875,Americas,66.322,4684.313807 +Guatemala,2002,11178650,Americas,68.978,4858.347495 +Guatemala,2007,12572928,Americas,70.259,5186.050003 +Guinea,1952,2664249,Africa,33.609,510.1964923 +Guinea,1957,2876726,Africa,34.558,576.2670245 +Guinea,1962,3140003,Africa,35.753,686.3736739 +Guinea,1967,3451418,Africa,37.197,708.7595409 +Guinea,1972,3811387,Africa,38.842,741.6662307 +Guinea,1977,4227026,Africa,40.762,874.6858643 +Guinea,1982,4710497,Africa,42.891,857.2503577 +Guinea,1987,5650262,Africa,45.552,805.5724718 +Guinea,1992,6990574,Africa,48.576,794.3484384 +Guinea,1997,8048834,Africa,51.455,869.4497668 +Guinea,2002,8807818,Africa,53.676,945.5835837 +Guinea,2007,9947814,Africa,56.007,942.6542111 +Guinea-Bissau,1952,580653,Africa,32.5,299.850319 +Guinea-Bissau,1957,601095,Africa,33.489,431.7904566 +Guinea-Bissau,1962,627820,Africa,34.488,522.0343725 +Guinea-Bissau,1967,601287,Africa,35.492,715.5806402 +Guinea-Bissau,1972,625361,Africa,36.486,820.2245876 +Guinea-Bissau,1977,745228,Africa,37.465,764.7259628 +Guinea-Bissau,1982,825987,Africa,39.327,838.1239671 +Guinea-Bissau,1987,927524,Africa,41.245,736.4153921 +Guinea-Bissau,1992,1050938,Africa,43.266,745.5398706 +Guinea-Bissau,1997,1193708,Africa,44.873,796.6644681 +Guinea-Bissau,2002,1332459,Africa,45.504,575.7047176 +Guinea-Bissau,2007,1472041,Africa,46.388,579.231743 +Haiti,1952,3201488,Americas,37.579,1840.366939 +Haiti,1957,3507701,Americas,40.696,1726.887882 +Haiti,1962,3880130,Americas,43.59,1796.589032 +Haiti,1967,4318137,Americas,46.243,1452.057666 +Haiti,1972,4698301,Americas,48.042,1654.456946 +Haiti,1977,4908554,Americas,49.923,1874.298931 +Haiti,1982,5198399,Americas,51.461,2011.159549 +Haiti,1987,5756203,Americas,53.636,1823.015995 +Haiti,1992,6326682,Americas,55.089,1456.309517 +Haiti,1997,6913545,Americas,56.671,1341.726931 +Haiti,2002,7607651,Americas,58.137,1270.364932 +Haiti,2007,8502814,Americas,60.916,1201.637154 +Honduras,1952,1517453,Americas,41.912,2194.926204 +Honduras,1957,1770390,Americas,44.665,2220.487682 +Honduras,1962,2090162,Americas,48.041,2291.156835 +Honduras,1967,2500689,Americas,50.924,2538.269358 +Honduras,1972,2965146,Americas,53.884,2529.842345 +Honduras,1977,3055235,Americas,57.402,3203.208066 +Honduras,1982,3669448,Americas,60.909,3121.760794 +Honduras,1987,4372203,Americas,64.492,3023.096699 +Honduras,1992,5077347,Americas,66.399,3081.694603 +Honduras,1997,5867957,Americas,67.659,3160.454906 +Honduras,2002,6677328,Americas,68.565,3099.72866 +Honduras,2007,7483763,Americas,70.198,3548.330846 +Hong Kong China,1952,2125900,Asia,60.96,3054.421209 +Hong Kong China,1957,2736300,Asia,64.75,3629.076457 +Hong Kong China,1962,3305200,Asia,67.65,4692.648272 +Hong Kong China,1967,3722800,Asia,70,6197.962814 +Hong Kong China,1972,4115700,Asia,72,8315.928145 +Hong Kong China,1977,4583700,Asia,73.6,11186.14125 +Hong Kong China,1982,5264500,Asia,75.45,14560.53051 +Hong Kong China,1987,5584510,Asia,76.2,20038.47269 +Hong Kong China,1992,5829696,Asia,77.601,24757.60301 +Hong Kong China,1997,6495918,Asia,80,28377.63219 +Hong Kong China,2002,6762476,Asia,81.495,30209.01516 +Hong Kong China,2007,6980412,Asia,82.208,39724.97867 +Hungary,1952,9504000,Europe,64.03,5263.673816 +Hungary,1957,9839000,Europe,66.41,6040.180011 +Hungary,1962,10063000,Europe,67.96,7550.359877 +Hungary,1967,10223422,Europe,69.5,9326.64467 +Hungary,1972,10394091,Europe,69.76,10168.65611 +Hungary,1977,10637171,Europe,69.95,11674.83737 +Hungary,1982,10705535,Europe,69.39,12545.99066 +Hungary,1987,10612740,Europe,69.58,12986.47998 +Hungary,1992,10348684,Europe,69.17,10535.62855 +Hungary,1997,10244684,Europe,71.04,11712.7768 +Hungary,2002,10083313,Europe,72.59,14843.93556 +Hungary,2007,9956108,Europe,73.338,18008.94444 +Iceland,1952,147962,Europe,72.49,7267.688428 +Iceland,1957,165110,Europe,73.47,9244.001412 +Iceland,1962,182053,Europe,73.68,10350.15906 +Iceland,1967,198676,Europe,73.73,13319.89568 +Iceland,1972,209275,Europe,74.46,15798.06362 +Iceland,1977,221823,Europe,76.11,19654.96247 +Iceland,1982,233997,Europe,76.99,23269.6075 +Iceland,1987,244676,Europe,77.23,26923.20628 +Iceland,1992,259012,Europe,78.77,25144.39201 +Iceland,1997,271192,Europe,78.95,28061.09966 +Iceland,2002,288030,Europe,80.5,31163.20196 +Iceland,2007,301931,Europe,81.757,36180.78919 +India,1952,3.72e+08,Asia,37.373,546.5657493 +India,1957,4.09e+08,Asia,40.249,590.061996 +India,1962,4.54e+08,Asia,43.605,658.3471509 +India,1967,5.06e+08,Asia,47.193,700.7706107 +India,1972,5.67e+08,Asia,50.651,724.032527 +India,1977,6.34e+08,Asia,54.208,813.337323 +India,1982,7.08e+08,Asia,56.596,855.7235377 +India,1987,7.88e+08,Asia,58.553,976.5126756 +India,1992,8.72e+08,Asia,60.223,1164.406809 +India,1997,9.59e+08,Asia,61.765,1458.817442 +India,2002,1034172547,Asia,62.879,1746.769454 +India,2007,1110396331,Asia,64.698,2452.210407 +Indonesia,1952,82052000,Asia,37.468,749.6816546 +Indonesia,1957,90124000,Asia,39.918,858.9002707 +Indonesia,1962,99028000,Asia,42.518,849.2897701 +Indonesia,1967,109343000,Asia,45.964,762.4317721 +Indonesia,1972,121282000,Asia,49.203,1111.107907 +Indonesia,1977,136725000,Asia,52.702,1382.702056 +Indonesia,1982,153343000,Asia,56.159,1516.872988 +Indonesia,1987,169276000,Asia,60.137,1748.356961 +Indonesia,1992,184816000,Asia,62.681,2383.140898 +Indonesia,1997,199278000,Asia,66.041,3119.335603 +Indonesia,2002,211060000,Asia,68.588,2873.91287 +Indonesia,2007,223547000,Asia,70.65,3540.651564 +Iran,1952,17272000,Asia,44.869,3035.326002 +Iran,1957,19792000,Asia,47.181,3290.257643 +Iran,1962,22874000,Asia,49.325,4187.329802 +Iran,1967,26538000,Asia,52.469,5906.731805 +Iran,1972,30614000,Asia,55.234,9613.818607 +Iran,1977,35480679,Asia,57.702,11888.59508 +Iran,1982,43072751,Asia,59.62,7608.334602 +Iran,1987,51889696,Asia,63.04,6642.881371 +Iran,1992,60397973,Asia,65.742,7235.653188 +Iran,1997,63327987,Asia,68.042,8263.590301 +Iran,2002,66907826,Asia,69.451,9240.761975 +Iran,2007,69453570,Asia,70.964,11605.71449 +Iraq,1952,5441766,Asia,45.32,4129.766056 +Iraq,1957,6248643,Asia,48.437,6229.333562 +Iraq,1962,7240260,Asia,51.457,8341.737815 +Iraq,1967,8519282,Asia,54.459,8931.459811 +Iraq,1972,10061506,Asia,56.95,9576.037596 +Iraq,1977,11882916,Asia,60.413,14688.23507 +Iraq,1982,14173318,Asia,62.038,14517.90711 +Iraq,1987,16543189,Asia,65.044,11643.57268 +Iraq,1992,17861905,Asia,59.461,3745.640687 +Iraq,1997,20775703,Asia,58.811,3076.239795 +Iraq,2002,24001816,Asia,57.046,4390.717312 +Iraq,2007,27499638,Asia,59.545,4471.061906 +Ireland,1952,2952156,Europe,66.91,5210.280328 +Ireland,1957,2878220,Europe,68.9,5599.077872 +Ireland,1962,2830000,Europe,70.29,6631.597314 +Ireland,1967,2900100,Europe,71.08,7655.568963 +Ireland,1972,3024400,Europe,71.28,9530.772896 +Ireland,1977,3271900,Europe,72.03,11150.98113 +Ireland,1982,3480000,Europe,73.1,12618.32141 +Ireland,1987,3539900,Europe,74.36,13872.86652 +Ireland,1992,3557761,Europe,75.467,17558.81555 +Ireland,1997,3667233,Europe,76.122,24521.94713 +Ireland,2002,3879155,Europe,77.783,34077.04939 +Ireland,2007,4109086,Europe,78.885,40675.99635 +Israel,1952,1620914,Asia,65.39,4086.522128 +Israel,1957,1944401,Asia,67.84,5385.278451 +Israel,1962,2310904,Asia,69.39,7105.630706 +Israel,1967,2693585,Asia,70.75,8393.741404 +Israel,1972,3095893,Asia,71.63,12786.93223 +Israel,1977,3495918,Asia,73.06,13306.61921 +Israel,1982,3858421,Asia,74.45,15367.0292 +Israel,1987,4203148,Asia,75.6,17122.47986 +Israel,1992,4936550,Asia,76.93,18051.52254 +Israel,1997,5531387,Asia,78.269,20896.60924 +Israel,2002,6029529,Asia,79.696,21905.59514 +Israel,2007,6426679,Asia,80.745,25523.2771 +Italy,1952,47666000,Europe,65.94,4931.404155 +Italy,1957,49182000,Europe,67.81,6248.656232 +Italy,1962,50843200,Europe,69.24,8243.58234 +Italy,1967,52667100,Europe,71.06,10022.40131 +Italy,1972,54365564,Europe,72.19,12269.27378 +Italy,1977,56059245,Europe,73.48,14255.98475 +Italy,1982,56535636,Europe,74.98,16537.4835 +Italy,1987,56729703,Europe,76.42,19207.23482 +Italy,1992,56840847,Europe,77.44,22013.64486 +Italy,1997,57479469,Europe,78.82,24675.02446 +Italy,2002,57926999,Europe,80.24,27968.09817 +Italy,2007,58147733,Europe,80.546,28569.7197 +Jamaica,1952,1426095,Americas,58.53,2898.530881 +Jamaica,1957,1535090,Americas,62.61,4756.525781 +Jamaica,1962,1665128,Americas,65.61,5246.107524 +Jamaica,1967,1861096,Americas,67.51,6124.703451 +Jamaica,1972,1997616,Americas,69,7433.889293 +Jamaica,1977,2156814,Americas,70.11,6650.195573 +Jamaica,1982,2298309,Americas,71.21,6068.05135 +Jamaica,1987,2326606,Americas,71.77,6351.237495 +Jamaica,1992,2378618,Americas,71.766,7404.923685 +Jamaica,1997,2531311,Americas,72.262,7121.924704 +Jamaica,2002,2664659,Americas,72.047,6994.774861 +Jamaica,2007,2780132,Americas,72.567,7320.880262 +Japan,1952,86459025,Asia,63.03,3216.956347 +Japan,1957,91563009,Asia,65.5,4317.694365 +Japan,1962,95831757,Asia,68.73,6576.649461 +Japan,1967,100825279,Asia,71.43,9847.788607 +Japan,1972,107188273,Asia,73.42,14778.78636 +Japan,1977,113872473,Asia,75.38,16610.37701 +Japan,1982,118454974,Asia,77.11,19384.10571 +Japan,1987,122091325,Asia,78.67,22375.94189 +Japan,1992,124329269,Asia,79.36,26824.89511 +Japan,1997,125956499,Asia,80.69,28816.58499 +Japan,2002,127065841,Asia,82,28604.5919 +Japan,2007,127467972,Asia,82.603,31656.06806 +Jordan,1952,607914,Asia,43.158,1546.907807 +Jordan,1957,746559,Asia,45.669,1886.080591 +Jordan,1962,933559,Asia,48.126,2348.009158 +Jordan,1967,1255058,Asia,51.629,2741.796252 +Jordan,1972,1613551,Asia,56.528,2110.856309 +Jordan,1977,1937652,Asia,61.134,2852.351568 +Jordan,1982,2347031,Asia,63.739,4161.415959 +Jordan,1987,2820042,Asia,65.869,4448.679912 +Jordan,1992,3867409,Asia,68.015,3431.593647 +Jordan,1997,4526235,Asia,69.772,3645.379572 +Jordan,2002,5307470,Asia,71.263,3844.917194 +Jordan,2007,6053193,Asia,72.535,4519.461171 +Kenya,1952,6464046,Africa,42.27,853.540919 +Kenya,1957,7454779,Africa,44.686,944.4383152 +Kenya,1962,8678557,Africa,47.949,896.9663732 +Kenya,1967,10191512,Africa,50.654,1056.736457 +Kenya,1972,12044785,Africa,53.559,1222.359968 +Kenya,1977,14500404,Africa,56.155,1267.613204 +Kenya,1982,17661452,Africa,58.766,1348.225791 +Kenya,1987,21198082,Africa,59.339,1361.936856 +Kenya,1992,25020539,Africa,59.285,1341.921721 +Kenya,1997,28263827,Africa,54.407,1360.485021 +Kenya,2002,31386842,Africa,50.992,1287.514732 +Kenya,2007,35610177,Africa,54.11,1463.249282 +Korea Dem. Rep.,1952,8865488,Asia,50.056,1088.277758 +Korea Dem. Rep.,1957,9411381,Asia,54.081,1571.134655 +Korea Dem. Rep.,1962,10917494,Asia,56.656,1621.693598 +Korea Dem. Rep.,1967,12617009,Asia,59.942,2143.540609 +Korea Dem. Rep.,1972,14781241,Asia,63.983,3701.621503 +Korea Dem. Rep.,1977,16325320,Asia,67.159,4106.301249 +Korea Dem. Rep.,1982,17647518,Asia,69.1,4106.525293 +Korea Dem. Rep.,1987,19067554,Asia,70.647,4106.492315 +Korea Dem. Rep.,1992,20711375,Asia,69.978,3726.063507 +Korea Dem. Rep.,1997,21585105,Asia,67.727,1690.756814 +Korea Dem. Rep.,2002,22215365,Asia,66.662,1646.758151 +Korea Dem. Rep.,2007,23301725,Asia,67.297,1593.06548 +Korea Rep.,1952,20947571,Asia,47.453,1030.592226 +Korea Rep.,1957,22611552,Asia,52.681,1487.593537 +Korea Rep.,1962,26420307,Asia,55.292,1536.344387 +Korea Rep.,1967,30131000,Asia,57.716,2029.228142 +Korea Rep.,1972,33505000,Asia,62.612,3030.87665 +Korea Rep.,1977,36436000,Asia,64.766,4657.22102 +Korea Rep.,1982,39326000,Asia,67.123,5622.942464 +Korea Rep.,1987,41622000,Asia,69.81,8533.088805 +Korea Rep.,1992,43805450,Asia,72.244,12104.27872 +Korea Rep.,1997,46173816,Asia,74.647,15993.52796 +Korea Rep.,2002,47969150,Asia,77.045,19233.98818 +Korea Rep.,2007,49044790,Asia,78.623,23348.13973 +Kuwait,1952,160000,Asia,55.565,108382.3529 +Kuwait,1957,212846,Asia,58.033,113523.1329 +Kuwait,1962,358266,Asia,60.47,95458.11176 +Kuwait,1967,575003,Asia,64.624,80894.88326 +Kuwait,1972,841934,Asia,67.712,109347.867 +Kuwait,1977,1140357,Asia,69.343,59265.47714 +Kuwait,1982,1497494,Asia,71.309,31354.03573 +Kuwait,1987,1891487,Asia,74.174,28118.42998 +Kuwait,1992,1418095,Asia,75.19,34932.91959 +Kuwait,1997,1765345,Asia,76.156,40300.61996 +Kuwait,2002,2111561,Asia,76.904,35110.10566 +Kuwait,2007,2505559,Asia,77.588,47306.98978 +Lebanon,1952,1439529,Asia,55.928,4834.804067 +Lebanon,1957,1647412,Asia,59.489,6089.786934 +Lebanon,1962,1886848,Asia,62.094,5714.560611 +Lebanon,1967,2186894,Asia,63.87,6006.983042 +Lebanon,1972,2680018,Asia,65.421,7486.384341 +Lebanon,1977,3115787,Asia,66.099,8659.696836 +Lebanon,1982,3086876,Asia,66.983,7640.519521 +Lebanon,1987,3089353,Asia,67.926,5377.091329 +Lebanon,1992,3219994,Asia,69.292,6890.806854 +Lebanon,1997,3430388,Asia,70.265,8754.96385 +Lebanon,2002,3677780,Asia,71.028,9313.93883 +Lebanon,2007,3921278,Asia,71.993,10461.05868 +Lesotho,1952,748747,Africa,42.138,298.8462121 +Lesotho,1957,813338,Africa,45.047,335.9971151 +Lesotho,1962,893143,Africa,47.747,411.8006266 +Lesotho,1967,996380,Africa,48.492,498.6390265 +Lesotho,1972,1116779,Africa,49.767,496.5815922 +Lesotho,1977,1251524,Africa,52.208,745.3695408 +Lesotho,1982,1411807,Africa,55.078,797.2631074 +Lesotho,1987,1599200,Africa,57.18,773.9932141 +Lesotho,1992,1803195,Africa,59.685,977.4862725 +Lesotho,1997,1982823,Africa,55.558,1186.147994 +Lesotho,2002,2046772,Africa,44.593,1275.184575 +Lesotho,2007,2012649,Africa,42.592,1569.331442 +Liberia,1952,863308,Africa,38.48,575.5729961 +Liberia,1957,975950,Africa,39.486,620.9699901 +Liberia,1962,1112796,Africa,40.502,634.1951625 +Liberia,1967,1279406,Africa,41.536,713.6036483 +Liberia,1972,1482628,Africa,42.614,803.0054535 +Liberia,1977,1703617,Africa,43.764,640.3224383 +Liberia,1982,1956875,Africa,44.852,572.1995694 +Liberia,1987,2269414,Africa,46.027,506.1138573 +Liberia,1992,1912974,Africa,40.802,636.6229191 +Liberia,1997,2200725,Africa,42.221,609.1739508 +Liberia,2002,2814651,Africa,43.753,531.4823679 +Liberia,2007,3193942,Africa,45.678,414.5073415 +Libya,1952,1019729,Africa,42.723,2387.54806 +Libya,1957,1201578,Africa,45.289,3448.284395 +Libya,1962,1441863,Africa,47.808,6757.030816 +Libya,1967,1759224,Africa,50.227,18772.75169 +Libya,1972,2183877,Africa,52.773,21011.49721 +Libya,1977,2721783,Africa,57.442,21951.21176 +Libya,1982,3344074,Africa,62.155,17364.27538 +Libya,1987,3799845,Africa,66.234,11770.5898 +Libya,1992,4364501,Africa,68.755,9640.138501 +Libya,1997,4759670,Africa,71.555,9467.446056 +Libya,2002,5368585,Africa,72.737,9534.677467 +Libya,2007,6036914,Africa,73.952,12057.49928 +Madagascar,1952,4762912,Africa,36.681,1443.011715 +Madagascar,1957,5181679,Africa,38.865,1589.20275 +Madagascar,1962,5703324,Africa,40.848,1643.38711 +Madagascar,1967,6334556,Africa,42.881,1634.047282 +Madagascar,1972,7082430,Africa,44.851,1748.562982 +Madagascar,1977,8007166,Africa,46.881,1544.228586 +Madagascar,1982,9171477,Africa,48.969,1302.878658 +Madagascar,1987,10568642,Africa,49.35,1155.441948 +Madagascar,1992,12210395,Africa,52.214,1040.67619 +Madagascar,1997,14165114,Africa,54.978,986.2958956 +Madagascar,2002,16473477,Africa,57.286,894.6370822 +Madagascar,2007,19167654,Africa,59.443,1044.770126 +Malawi,1952,2917802,Africa,36.256,369.1650802 +Malawi,1957,3221238,Africa,37.207,416.3698064 +Malawi,1962,3628608,Africa,38.41,427.9010856 +Malawi,1967,4147252,Africa,39.487,495.5147806 +Malawi,1972,4730997,Africa,41.766,584.6219709 +Malawi,1977,5637246,Africa,43.767,663.2236766 +Malawi,1982,6502825,Africa,45.642,632.8039209 +Malawi,1987,7824747,Africa,47.457,635.5173634 +Malawi,1992,10014249,Africa,49.42,563.2000145 +Malawi,1997,10419991,Africa,47.495,692.2758103 +Malawi,2002,11824495,Africa,45.009,665.4231186 +Malawi,2007,13327079,Africa,48.303,759.3499101 +Malaysia,1952,6748378,Asia,48.463,1831.132894 +Malaysia,1957,7739235,Asia,52.102,1810.066992 +Malaysia,1962,8906385,Asia,55.737,2036.884944 +Malaysia,1967,10154878,Asia,59.371,2277.742396 +Malaysia,1972,11441462,Asia,63.01,2849.09478 +Malaysia,1977,12845381,Asia,65.256,3827.921571 +Malaysia,1982,14441916,Asia,68,4920.355951 +Malaysia,1987,16331785,Asia,69.5,5249.802653 +Malaysia,1992,18319502,Asia,70.693,7277.912802 +Malaysia,1997,20476091,Asia,71.938,10132.90964 +Malaysia,2002,22662365,Asia,73.044,10206.97794 +Malaysia,2007,24821286,Asia,74.241,12451.6558 +Mali,1952,3838168,Africa,33.685,452.3369807 +Mali,1957,4241884,Africa,35.307,490.3821867 +Mali,1962,4690372,Africa,36.936,496.1743428 +Mali,1967,5212416,Africa,38.487,545.0098873 +Mali,1972,5828158,Africa,39.977,581.3688761 +Mali,1977,6491649,Africa,41.714,686.3952693 +Mali,1982,6998256,Africa,43.916,618.0140641 +Mali,1987,7634008,Africa,46.364,684.1715576 +Mali,1992,8416215,Africa,48.388,739.014375 +Mali,1997,9384984,Africa,49.903,790.2579846 +Mali,2002,10580176,Africa,51.818,951.4097518 +Mali,2007,12031795,Africa,54.467,1042.581557 +Mauritania,1952,1022556,Africa,40.543,743.1159097 +Mauritania,1957,1076852,Africa,42.338,846.1202613 +Mauritania,1962,1146757,Africa,44.248,1055.896036 +Mauritania,1967,1230542,Africa,46.289,1421.145193 +Mauritania,1972,1332786,Africa,48.437,1586.851781 +Mauritania,1977,1456688,Africa,50.852,1497.492223 +Mauritania,1982,1622136,Africa,53.599,1481.150189 +Mauritania,1987,1841240,Africa,56.145,1421.603576 +Mauritania,1992,2119465,Africa,58.333,1361.369784 +Mauritania,1997,2444741,Africa,60.43,1483.136136 +Mauritania,2002,2828858,Africa,62.247,1579.019543 +Mauritania,2007,3270065,Africa,64.164,1803.151496 +Mauritius,1952,516556,Africa,50.986,1967.955707 +Mauritius,1957,609816,Africa,58.089,2034.037981 +Mauritius,1962,701016,Africa,60.246,2529.067487 +Mauritius,1967,789309,Africa,61.557,2475.387562 +Mauritius,1972,851334,Africa,62.944,2575.484158 +Mauritius,1977,913025,Africa,64.93,3710.982963 +Mauritius,1982,992040,Africa,66.711,3688.037739 +Mauritius,1987,1042663,Africa,68.74,4783.586903 +Mauritius,1992,1096202,Africa,69.745,6058.253846 +Mauritius,1997,1149818,Africa,70.736,7425.705295 +Mauritius,2002,1200206,Africa,71.954,9021.815894 +Mauritius,2007,1250882,Africa,72.801,10956.99112 +Mexico,1952,30144317,Americas,50.789,3478.125529 +Mexico,1957,35015548,Americas,55.19,4131.546641 +Mexico,1962,41121485,Americas,58.299,4581.609385 +Mexico,1967,47995559,Americas,60.11,5754.733883 +Mexico,1972,55984294,Americas,62.361,6809.40669 +Mexico,1977,63759976,Americas,65.032,7674.929108 +Mexico,1982,71640904,Americas,67.405,9611.147541 +Mexico,1987,80122492,Americas,69.498,8688.156003 +Mexico,1992,88111030,Americas,71.455,9472.384295 +Mexico,1997,95895146,Americas,73.67,9767.29753 +Mexico,2002,102479927,Americas,74.902,10742.44053 +Mexico,2007,108700891,Americas,76.195,11977.57496 +Mongolia,1952,800663,Asia,42.244,786.5668575 +Mongolia,1957,882134,Asia,45.248,912.6626085 +Mongolia,1962,1010280,Asia,48.251,1056.353958 +Mongolia,1967,1149500,Asia,51.253,1226.04113 +Mongolia,1972,1320500,Asia,53.754,1421.741975 +Mongolia,1977,1528000,Asia,55.491,1647.511665 +Mongolia,1982,1756032,Asia,57.489,2000.603139 +Mongolia,1987,2015133,Asia,60.222,2338.008304 +Mongolia,1992,2312802,Asia,61.271,1785.402016 +Mongolia,1997,2494803,Asia,63.625,1902.2521 +Mongolia,2002,2674234,Asia,65.033,2140.739323 +Mongolia,2007,2874127,Asia,66.803,3095.772271 +Montenegro,1952,413834,Europe,59.164,2647.585601 +Montenegro,1957,442829,Europe,61.448,3682.259903 +Montenegro,1962,474528,Europe,63.728,4649.593785 +Montenegro,1967,501035,Europe,67.178,5907.850937 +Montenegro,1972,527678,Europe,70.636,7778.414017 +Montenegro,1977,560073,Europe,73.066,9595.929905 +Montenegro,1982,562548,Europe,74.101,11222.58762 +Montenegro,1987,569473,Europe,74.865,11732.51017 +Montenegro,1992,621621,Europe,75.435,7003.339037 +Montenegro,1997,692651,Europe,75.445,6465.613349 +Montenegro,2002,720230,Europe,73.981,6557.194282 +Montenegro,2007,684736,Europe,74.543,9253.896111 +Morocco,1952,9939217,Africa,42.873,1688.20357 +Morocco,1957,11406350,Africa,45.423,1642.002314 +Morocco,1962,13056604,Africa,47.924,1566.353493 +Morocco,1967,14770296,Africa,50.335,1711.04477 +Morocco,1972,16660670,Africa,52.862,1930.194975 +Morocco,1977,18396941,Africa,55.73,2370.619976 +Morocco,1982,20198730,Africa,59.65,2702.620356 +Morocco,1987,22987397,Africa,62.677,2755.046991 +Morocco,1992,25798239,Africa,65.393,2948.047252 +Morocco,1997,28529501,Africa,67.66,2982.101858 +Morocco,2002,31167783,Africa,69.615,3258.495584 +Morocco,2007,33757175,Africa,71.164,3820.17523 +Mozambique,1952,6446316,Africa,31.286,468.5260381 +Mozambique,1957,7038035,Africa,33.779,495.5868333 +Mozambique,1962,7788944,Africa,36.161,556.6863539 +Mozambique,1967,8680909,Africa,38.113,566.6691539 +Mozambique,1972,9809596,Africa,40.328,724.9178037 +Mozambique,1977,11127868,Africa,42.495,502.3197334 +Mozambique,1982,12587223,Africa,42.795,462.2114149 +Mozambique,1987,12891952,Africa,42.861,389.8761846 +Mozambique,1992,13160731,Africa,44.284,410.8968239 +Mozambique,1997,16603334,Africa,46.344,472.3460771 +Mozambique,2002,18473780,Africa,44.026,633.6179466 +Mozambique,2007,19951656,Africa,42.082,823.6856205 +Myanmar,1952,20092996,Asia,36.319,331 +Myanmar,1957,21731844,Asia,41.905,350 +Myanmar,1962,23634436,Asia,45.108,388 +Myanmar,1967,25870271,Asia,49.379,349 +Myanmar,1972,28466390,Asia,53.07,357 +Myanmar,1977,31528087,Asia,56.059,371 +Myanmar,1982,34680442,Asia,58.056,424 +Myanmar,1987,38028578,Asia,58.339,385 +Myanmar,1992,40546538,Asia,59.32,347 +Myanmar,1997,43247867,Asia,60.328,415 +Myanmar,2002,45598081,Asia,59.908,611 +Myanmar,2007,47761980,Asia,62.069,944 +Namibia,1952,485831,Africa,41.725,2423.780443 +Namibia,1957,548080,Africa,45.226,2621.448058 +Namibia,1962,621392,Africa,48.386,3173.215595 +Namibia,1967,706640,Africa,51.159,3793.694753 +Namibia,1972,821782,Africa,53.867,3746.080948 +Namibia,1977,977026,Africa,56.437,3876.485958 +Namibia,1982,1099010,Africa,58.968,4191.100511 +Namibia,1987,1278184,Africa,60.835,3693.731337 +Namibia,1992,1554253,Africa,61.999,3804.537999 +Namibia,1997,1774766,Africa,58.909,3899.52426 +Namibia,2002,1972153,Africa,51.479,4072.324751 +Namibia,2007,2055080,Africa,52.906,4811.060429 +Nepal,1952,9182536,Asia,36.157,545.8657229 +Nepal,1957,9682338,Asia,37.686,597.9363558 +Nepal,1962,10332057,Asia,39.393,652.3968593 +Nepal,1967,11261690,Asia,41.472,676.4422254 +Nepal,1972,12412593,Asia,43.971,674.7881296 +Nepal,1977,13933198,Asia,46.748,694.1124398 +Nepal,1982,15796314,Asia,49.594,718.3730947 +Nepal,1987,17917180,Asia,52.537,775.6324501 +Nepal,1992,20326209,Asia,55.727,897.7403604 +Nepal,1997,23001113,Asia,59.426,1010.892138 +Nepal,2002,25873917,Asia,61.34,1057.206311 +Nepal,2007,28901790,Asia,63.785,1091.359778 +Netherlands,1952,10381988,Europe,72.13,8941.571858 +Netherlands,1957,11026383,Europe,72.99,11276.19344 +Netherlands,1962,11805689,Europe,73.23,12790.84956 +Netherlands,1967,12596822,Europe,73.82,15363.25136 +Netherlands,1972,13329874,Europe,73.75,18794.74567 +Netherlands,1977,13852989,Europe,75.24,21209.0592 +Netherlands,1982,14310401,Europe,76.05,21399.46046 +Netherlands,1987,14665278,Europe,76.83,23651.32361 +Netherlands,1992,15174244,Europe,77.42,26790.94961 +Netherlands,1997,15604464,Europe,78.03,30246.13063 +Netherlands,2002,16122830,Europe,78.53,33724.75778 +Netherlands,2007,16570613,Europe,79.762,36797.93332 +New Zealand,1952,1994794,Oceania,69.39,10556.57566 +New Zealand,1957,2229407,Oceania,70.26,12247.39532 +New Zealand,1962,2488550,Oceania,71.24,13175.678 +New Zealand,1967,2728150,Oceania,71.52,14463.91893 +New Zealand,1972,2929100,Oceania,71.89,16046.03728 +New Zealand,1977,3164900,Oceania,72.22,16233.7177 +New Zealand,1982,3210650,Oceania,73.84,17632.4104 +New Zealand,1987,3317166,Oceania,74.32,19007.19129 +New Zealand,1992,3437674,Oceania,76.33,18363.32494 +New Zealand,1997,3676187,Oceania,77.55,21050.41377 +New Zealand,2002,3908037,Oceania,79.11,23189.80135 +New Zealand,2007,4115771,Oceania,80.204,25185.00911 +Nicaragua,1952,1165790,Americas,42.314,3112.363948 +Nicaragua,1957,1358828,Americas,45.432,3457.415947 +Nicaragua,1962,1590597,Americas,48.632,3634.364406 +Nicaragua,1967,1865490,Americas,51.884,4643.393534 +Nicaragua,1972,2182908,Americas,55.151,4688.593267 +Nicaragua,1977,2554598,Americas,57.47,5486.371089 +Nicaragua,1982,2979423,Americas,59.298,3470.338156 +Nicaragua,1987,3344353,Americas,62.008,2955.984375 +Nicaragua,1992,4017939,Americas,65.843,2170.151724 +Nicaragua,1997,4609572,Americas,68.426,2253.023004 +Nicaragua,2002,5146848,Americas,70.836,2474.548819 +Nicaragua,2007,5675356,Americas,72.899,2749.320965 +Niger,1952,3379468,Africa,37.444,761.879376 +Niger,1957,3692184,Africa,38.598,835.5234025 +Niger,1962,4076008,Africa,39.487,997.7661127 +Niger,1967,4534062,Africa,40.118,1054.384891 +Niger,1972,5060262,Africa,40.546,954.2092363 +Niger,1977,5682086,Africa,41.291,808.8970728 +Niger,1982,6437188,Africa,42.598,909.7221354 +Niger,1987,7332638,Africa,44.555,668.3000228 +Niger,1992,8392818,Africa,47.391,581.182725 +Niger,1997,9666252,Africa,51.313,580.3052092 +Niger,2002,11140655,Africa,54.496,601.0745012 +Niger,2007,12894865,Africa,56.867,619.6768924 +Nigeria,1952,33119096,Africa,36.324,1077.281856 +Nigeria,1957,37173340,Africa,37.802,1100.592563 +Nigeria,1962,41871351,Africa,39.36,1150.927478 +Nigeria,1967,47287752,Africa,41.04,1014.514104 +Nigeria,1972,53740085,Africa,42.821,1698.388838 +Nigeria,1977,62209173,Africa,44.514,1981.951806 +Nigeria,1982,73039376,Africa,45.826,1576.97375 +Nigeria,1987,81551520,Africa,46.886,1385.029563 +Nigeria,1992,93364244,Africa,47.472,1619.848217 +Nigeria,1997,106207839,Africa,47.464,1624.941275 +Nigeria,2002,119901274,Africa,46.608,1615.286395 +Nigeria,2007,135031164,Africa,46.859,2013.977305 +Norway,1952,3327728,Europe,72.67,10095.42172 +Norway,1957,3491938,Europe,73.44,11653.97304 +Norway,1962,3638919,Europe,73.47,13450.40151 +Norway,1967,3786019,Europe,74.08,16361.87647 +Norway,1972,3933004,Europe,74.34,18965.05551 +Norway,1977,4043205,Europe,75.37,23311.34939 +Norway,1982,4114787,Europe,75.97,26298.63531 +Norway,1987,4186147,Europe,75.89,31540.9748 +Norway,1992,4286357,Europe,77.32,33965.66115 +Norway,1997,4405672,Europe,78.32,41283.16433 +Norway,2002,4535591,Europe,79.05,44683.97525 +Norway,2007,4627926,Europe,80.196,49357.19017 +Oman,1952,507833,Asia,37.578,1828.230307 +Oman,1957,561977,Asia,40.08,2242.746551 +Oman,1962,628164,Asia,43.165,2924.638113 +Oman,1967,714775,Asia,46.988,4720.942687 +Oman,1972,829050,Asia,52.143,10618.03855 +Oman,1977,1004533,Asia,57.367,11848.34392 +Oman,1982,1301048,Asia,62.728,12954.79101 +Oman,1987,1593882,Asia,67.734,18115.22313 +Oman,1992,1915208,Asia,71.197,18616.70691 +Oman,1997,2283635,Asia,72.499,19702.05581 +Oman,2002,2713462,Asia,74.193,19774.83687 +Oman,2007,3204897,Asia,75.64,22316.19287 +Pakistan,1952,41346560,Asia,43.436,684.5971438 +Pakistan,1957,46679944,Asia,45.557,747.0835292 +Pakistan,1962,53100671,Asia,47.67,803.3427418 +Pakistan,1967,60641899,Asia,49.8,942.4082588 +Pakistan,1972,69325921,Asia,51.929,1049.938981 +Pakistan,1977,78152686,Asia,54.043,1175.921193 +Pakistan,1982,91462088,Asia,56.158,1443.429832 +Pakistan,1987,105186881,Asia,58.245,1704.686583 +Pakistan,1992,120065004,Asia,60.838,1971.829464 +Pakistan,1997,135564834,Asia,61.818,2049.350521 +Pakistan,2002,153403524,Asia,63.61,2092.712441 +Pakistan,2007,169270617,Asia,65.483,2605.94758 +Panama,1952,940080,Americas,55.191,2480.380334 +Panama,1957,1063506,Americas,59.201,2961.800905 +Panama,1962,1215725,Americas,61.817,3536.540301 +Panama,1967,1405486,Americas,64.071,4421.009084 +Panama,1972,1616384,Americas,66.216,5364.249663 +Panama,1977,1839782,Americas,68.681,5351.912144 +Panama,1982,2036305,Americas,70.472,7009.601598 +Panama,1987,2253639,Americas,71.523,7034.779161 +Panama,1992,2484997,Americas,72.462,6618.74305 +Panama,1997,2734531,Americas,73.738,7113.692252 +Panama,2002,2990875,Americas,74.712,7356.031934 +Panama,2007,3242173,Americas,75.537,9809.185636 +Paraguay,1952,1555876,Americas,62.649,1952.308701 +Paraguay,1957,1770902,Americas,63.196,2046.154706 +Paraguay,1962,2009813,Americas,64.361,2148.027146 +Paraguay,1967,2287985,Americas,64.951,2299.376311 +Paraguay,1972,2614104,Americas,65.815,2523.337977 +Paraguay,1977,2984494,Americas,66.353,3248.373311 +Paraguay,1982,3366439,Americas,66.874,4258.503604 +Paraguay,1987,3886512,Americas,67.378,3998.875695 +Paraguay,1992,4483945,Americas,68.225,4196.411078 +Paraguay,1997,5154123,Americas,69.4,4247.400261 +Paraguay,2002,5884491,Americas,70.755,3783.674243 +Paraguay,2007,6667147,Americas,71.752,4172.838464 +Peru,1952,8025700,Americas,43.902,3758.523437 +Peru,1957,9146100,Americas,46.263,4245.256698 +Peru,1962,10516500,Americas,49.096,4957.037982 +Peru,1967,12132200,Americas,51.445,5788.09333 +Peru,1972,13954700,Americas,55.448,5937.827283 +Peru,1977,15990099,Americas,58.447,6281.290855 +Peru,1982,18125129,Americas,61.406,6434.501797 +Peru,1987,20195924,Americas,64.134,6360.943444 +Peru,1992,22430449,Americas,66.458,4446.380924 +Peru,1997,24748122,Americas,68.386,5838.347657 +Peru,2002,26769436,Americas,69.906,5909.020073 +Peru,2007,28674757,Americas,71.421,7408.905561 +Philippines,1952,22438691,Asia,47.752,1272.880995 +Philippines,1957,26072194,Asia,51.334,1547.944844 +Philippines,1962,30325264,Asia,54.757,1649.552153 +Philippines,1967,35356600,Asia,56.393,1814.12743 +Philippines,1972,40850141,Asia,58.065,1989.37407 +Philippines,1977,46850962,Asia,60.06,2373.204287 +Philippines,1982,53456774,Asia,62.082,2603.273765 +Philippines,1987,60017788,Asia,64.151,2189.634995 +Philippines,1992,67185766,Asia,66.458,2279.324017 +Philippines,1997,75012988,Asia,68.564,2536.534925 +Philippines,2002,82995088,Asia,70.303,2650.921068 +Philippines,2007,91077287,Asia,71.688,3190.481016 +Poland,1952,25730551,Europe,61.31,4029.329699 +Poland,1957,28235346,Europe,65.77,4734.253019 +Poland,1962,30329617,Europe,67.64,5338.752143 +Poland,1967,31785378,Europe,69.61,6557.152776 +Poland,1972,33039545,Europe,70.85,8006.506993 +Poland,1977,34621254,Europe,70.67,9508.141454 +Poland,1982,36227381,Europe,71.32,8451.531004 +Poland,1987,37740710,Europe,70.98,9082.351172 +Poland,1992,38370697,Europe,70.99,7738.881247 +Poland,1997,38654957,Europe,72.75,10159.58368 +Poland,2002,38625976,Europe,74.67,12002.23908 +Poland,2007,38518241,Europe,75.563,15389.92468 +Portugal,1952,8526050,Europe,59.82,3068.319867 +Portugal,1957,8817650,Europe,61.51,3774.571743 +Portugal,1962,9019800,Europe,64.39,4727.954889 +Portugal,1967,9103000,Europe,66.6,6361.517993 +Portugal,1972,8970450,Europe,69.26,9022.247417 +Portugal,1977,9662600,Europe,70.41,10172.48572 +Portugal,1982,9859650,Europe,72.77,11753.84291 +Portugal,1987,9915289,Europe,74.06,13039.30876 +Portugal,1992,9927680,Europe,74.86,16207.26663 +Portugal,1997,10156415,Europe,75.97,17641.03156 +Portugal,2002,10433867,Europe,77.29,19970.90787 +Portugal,2007,10642836,Europe,78.098,20509.64777 +Puerto Rico,1952,2227000,Americas,64.28,3081.959785 +Puerto Rico,1957,2260000,Americas,68.54,3907.156189 +Puerto Rico,1962,2448046,Americas,69.62,5108.34463 +Puerto Rico,1967,2648961,Americas,71.1,6929.277714 +Puerto Rico,1972,2847132,Americas,72.16,9123.041742 +Puerto Rico,1977,3080828,Americas,73.44,9770.524921 +Puerto Rico,1982,3279001,Americas,73.75,10330.98915 +Puerto Rico,1987,3444468,Americas,74.63,12281.34191 +Puerto Rico,1992,3585176,Americas,73.911,14641.58711 +Puerto Rico,1997,3759430,Americas,74.917,16999.4333 +Puerto Rico,2002,3859606,Americas,77.778,18855.60618 +Puerto Rico,2007,3942491,Americas,78.746,19328.70901 +Reunion,1952,257700,Africa,52.724,2718.885295 +Reunion,1957,308700,Africa,55.09,2769.451844 +Reunion,1962,358900,Africa,57.666,3173.72334 +Reunion,1967,414024,Africa,60.542,4021.175739 +Reunion,1972,461633,Africa,64.274,5047.658563 +Reunion,1977,492095,Africa,67.064,4319.804067 +Reunion,1982,517810,Africa,69.885,5267.219353 +Reunion,1987,562035,Africa,71.913,5303.377488 +Reunion,1992,622191,Africa,73.615,6101.255823 +Reunion,1997,684810,Africa,74.772,6071.941411 +Reunion,2002,743981,Africa,75.744,6316.1652 +Reunion,2007,798094,Africa,76.442,7670.122558 +Romania,1952,16630000,Europe,61.05,3144.613186 +Romania,1957,17829327,Europe,64.1,3943.370225 +Romania,1962,18680721,Europe,66.8,4734.997586 +Romania,1967,19284814,Europe,66.8,6470.866545 +Romania,1972,20662648,Europe,69.21,8011.414402 +Romania,1977,21658597,Europe,69.46,9356.39724 +Romania,1982,22356726,Europe,69.66,9605.314053 +Romania,1987,22686371,Europe,69.53,9696.273295 +Romania,1992,22797027,Europe,69.36,6598.409903 +Romania,1997,22562458,Europe,69.72,7346.547557 +Romania,2002,22404337,Europe,71.322,7885.360081 +Romania,2007,22276056,Europe,72.476,10808.47561 +Rwanda,1952,2534927,Africa,40,493.3238752 +Rwanda,1957,2822082,Africa,41.5,540.2893983 +Rwanda,1962,3051242,Africa,43,597.4730727 +Rwanda,1967,3451079,Africa,44.1,510.9637142 +Rwanda,1972,3992121,Africa,44.6,590.5806638 +Rwanda,1977,4657072,Africa,45,670.0806011 +Rwanda,1982,5507565,Africa,46.218,881.5706467 +Rwanda,1987,6349365,Africa,44.02,847.991217 +Rwanda,1992,7290203,Africa,23.599,737.0685949 +Rwanda,1997,7212583,Africa,36.087,589.9445051 +Rwanda,2002,7852401,Africa,43.413,785.6537648 +Rwanda,2007,8860588,Africa,46.242,863.0884639 +Sao Tome and Principe,1952,60011,Africa,46.471,879.5835855 +Sao Tome and Principe,1957,61325,Africa,48.945,860.7369026 +Sao Tome and Principe,1962,65345,Africa,51.893,1071.551119 +Sao Tome and Principe,1967,70787,Africa,54.425,1384.840593 +Sao Tome and Principe,1972,76595,Africa,56.48,1532.985254 +Sao Tome and Principe,1977,86796,Africa,58.55,1737.561657 +Sao Tome and Principe,1982,98593,Africa,60.351,1890.218117 +Sao Tome and Principe,1987,110812,Africa,61.728,1516.525457 +Sao Tome and Principe,1992,125911,Africa,62.742,1428.777814 +Sao Tome and Principe,1997,145608,Africa,63.306,1339.076036 +Sao Tome and Principe,2002,170372,Africa,64.337,1353.09239 +Sao Tome and Principe,2007,199579,Africa,65.528,1598.435089 +Saudi Arabia,1952,4005677,Asia,39.875,6459.554823 +Saudi Arabia,1957,4419650,Asia,42.868,8157.591248 +Saudi Arabia,1962,4943029,Asia,45.914,11626.41975 +Saudi Arabia,1967,5618198,Asia,49.901,16903.04886 +Saudi Arabia,1972,6472756,Asia,53.886,24837.42865 +Saudi Arabia,1977,8128505,Asia,58.69,34167.7626 +Saudi Arabia,1982,11254672,Asia,63.012,33693.17525 +Saudi Arabia,1987,14619745,Asia,66.295,21198.26136 +Saudi Arabia,1992,16945857,Asia,68.768,24841.61777 +Saudi Arabia,1997,21229759,Asia,70.533,20586.69019 +Saudi Arabia,2002,24501530,Asia,71.626,19014.54118 +Saudi Arabia,2007,27601038,Asia,72.777,21654.83194 +Senegal,1952,2755589,Africa,37.278,1450.356983 +Senegal,1957,3054547,Africa,39.329,1567.653006 +Senegal,1962,3430243,Africa,41.454,1654.988723 +Senegal,1967,3965841,Africa,43.563,1612.404632 +Senegal,1972,4588696,Africa,45.815,1597.712056 +Senegal,1977,5260855,Africa,48.879,1561.769116 +Senegal,1982,6147783,Africa,52.379,1518.479984 +Senegal,1987,7171347,Africa,55.769,1441.72072 +Senegal,1992,8307920,Africa,58.196,1367.899369 +Senegal,1997,9535314,Africa,60.187,1392.368347 +Senegal,2002,10870037,Africa,61.6,1519.635262 +Senegal,2007,12267493,Africa,63.062,1712.472136 +Serbia,1952,6860147,Europe,57.996,3581.459448 +Serbia,1957,7271135,Europe,61.685,4981.090891 +Serbia,1962,7616060,Europe,64.531,6289.629157 +Serbia,1967,7971222,Europe,66.914,7991.707066 +Serbia,1972,8313288,Europe,68.7,10522.06749 +Serbia,1977,8686367,Europe,70.3,12980.66956 +Serbia,1982,9032824,Europe,70.162,15181.0927 +Serbia,1987,9230783,Europe,71.218,15870.87851 +Serbia,1992,9826397,Europe,71.659,9325.068238 +Serbia,1997,10336594,Europe,72.232,7914.320304 +Serbia,2002,10111559,Europe,73.213,7236.075251 +Serbia,2007,10150265,Europe,74.002,9786.534714 +Sierra Leone,1952,2143249,Africa,30.331,879.7877358 +Sierra Leone,1957,2295678,Africa,31.57,1004.484437 +Sierra Leone,1962,2467895,Africa,32.767,1116.639877 +Sierra Leone,1967,2662190,Africa,34.113,1206.043465 +Sierra Leone,1972,2879013,Africa,35.4,1353.759762 +Sierra Leone,1977,3140897,Africa,36.788,1348.285159 +Sierra Leone,1982,3464522,Africa,38.445,1465.010784 +Sierra Leone,1987,3868905,Africa,40.006,1294.447788 +Sierra Leone,1992,4260884,Africa,38.333,1068.696278 +Sierra Leone,1997,4578212,Africa,39.897,574.6481576 +Sierra Leone,2002,5359092,Africa,41.012,699.489713 +Sierra Leone,2007,6144562,Africa,42.568,862.5407561 +Singapore,1952,1127000,Asia,60.396,2315.138227 +Singapore,1957,1445929,Asia,63.179,2843.104409 +Singapore,1962,1750200,Asia,65.798,3674.735572 +Singapore,1967,1977600,Asia,67.946,4977.41854 +Singapore,1972,2152400,Asia,69.521,8597.756202 +Singapore,1977,2325300,Asia,70.795,11210.08948 +Singapore,1982,2651869,Asia,71.76,15169.16112 +Singapore,1987,2794552,Asia,73.56,18861.53081 +Singapore,1992,3235865,Asia,75.788,24769.8912 +Singapore,1997,3802309,Asia,77.158,33519.4766 +Singapore,2002,4197776,Asia,78.77,36023.1054 +Singapore,2007,4553009,Asia,79.972,47143.17964 +Slovak Republic,1952,3558137,Europe,64.36,5074.659104 +Slovak Republic,1957,3844277,Europe,67.45,6093.26298 +Slovak Republic,1962,4237384,Europe,70.33,7481.107598 +Slovak Republic,1967,4442238,Europe,70.98,8412.902397 +Slovak Republic,1972,4593433,Europe,70.35,9674.167626 +Slovak Republic,1977,4827803,Europe,70.45,10922.66404 +Slovak Republic,1982,5048043,Europe,70.8,11348.54585 +Slovak Republic,1987,5199318,Europe,71.08,12037.26758 +Slovak Republic,1992,5302888,Europe,71.38,9498.467723 +Slovak Republic,1997,5383010,Europe,72.71,12126.23065 +Slovak Republic,2002,5410052,Europe,73.8,13638.77837 +Slovak Republic,2007,5447502,Europe,74.663,18678.31435 +Slovenia,1952,1489518,Europe,65.57,4215.041741 +Slovenia,1957,1533070,Europe,67.85,5862.276629 +Slovenia,1962,1582962,Europe,69.15,7402.303395 +Slovenia,1967,1646912,Europe,69.18,9405.489397 +Slovenia,1972,1694510,Europe,69.82,12383.4862 +Slovenia,1977,1746919,Europe,70.97,15277.03017 +Slovenia,1982,1861252,Europe,71.063,17866.72175 +Slovenia,1987,1945870,Europe,72.25,18678.53492 +Slovenia,1992,1999210,Europe,73.64,14214.71681 +Slovenia,1997,2011612,Europe,75.13,17161.10735 +Slovenia,2002,2011497,Europe,76.66,20660.01936 +Slovenia,2007,2009245,Europe,77.926,25768.25759 +Somalia,1952,2526994,Africa,32.978,1135.749842 +Somalia,1957,2780415,Africa,34.977,1258.147413 +Somalia,1962,3080153,Africa,36.981,1369.488336 +Somalia,1967,3428839,Africa,38.977,1284.73318 +Somalia,1972,3840161,Africa,40.973,1254.576127 +Somalia,1977,4353666,Africa,41.974,1450.992513 +Somalia,1982,5828892,Africa,42.955,1176.807031 +Somalia,1987,6921858,Africa,44.501,1093.244963 +Somalia,1992,6099799,Africa,39.658,926.9602964 +Somalia,1997,6633514,Africa,43.795,930.5964284 +Somalia,2002,7753310,Africa,45.936,882.0818218 +Somalia,2007,9118773,Africa,48.159,926.1410683 +South Africa,1952,14264935,Africa,45.009,4725.295531 +South Africa,1957,16151549,Africa,47.985,5487.104219 +South Africa,1962,18356657,Africa,49.951,5768.729717 +South Africa,1967,20997321,Africa,51.927,7114.477971 +South Africa,1972,23935810,Africa,53.696,7765.962636 +South Africa,1977,27129932,Africa,55.527,8028.651439 +South Africa,1982,31140029,Africa,58.161,8568.266228 +South Africa,1987,35933379,Africa,60.834,7825.823398 +South Africa,1992,39964159,Africa,61.888,7225.069258 +South Africa,1997,42835005,Africa,60.236,7479.188244 +South Africa,2002,44433622,Africa,53.365,7710.946444 +South Africa,2007,43997828,Africa,49.339,9269.657808 +Spain,1952,28549870,Europe,64.94,3834.034742 +Spain,1957,29841614,Europe,66.66,4564.80241 +Spain,1962,31158061,Europe,69.69,5693.843879 +Spain,1967,32850275,Europe,71.44,7993.512294 +Spain,1972,34513161,Europe,73.06,10638.75131 +Spain,1977,36439000,Europe,74.39,13236.92117 +Spain,1982,37983310,Europe,76.3,13926.16997 +Spain,1987,38880702,Europe,76.9,15764.98313 +Spain,1992,39549438,Europe,77.57,18603.06452 +Spain,1997,39855442,Europe,78.77,20445.29896 +Spain,2002,40152517,Europe,79.78,24835.47166 +Spain,2007,40448191,Europe,80.941,28821.0637 +Sri Lanka,1952,7982342,Asia,57.593,1083.53203 +Sri Lanka,1957,9128546,Asia,61.456,1072.546602 +Sri Lanka,1962,10421936,Asia,62.192,1074.47196 +Sri Lanka,1967,11737396,Asia,64.266,1135.514326 +Sri Lanka,1972,13016733,Asia,65.042,1213.39553 +Sri Lanka,1977,14116836,Asia,65.949,1348.775651 +Sri Lanka,1982,15410151,Asia,68.757,1648.079789 +Sri Lanka,1987,16495304,Asia,69.011,1876.766827 +Sri Lanka,1992,17587060,Asia,70.379,2153.739222 +Sri Lanka,1997,18698655,Asia,70.457,2664.477257 +Sri Lanka,2002,19576783,Asia,70.815,3015.378833 +Sri Lanka,2007,20378239,Asia,72.396,3970.095407 +Sudan,1952,8504667,Africa,38.635,1615.991129 +Sudan,1957,9753392,Africa,39.624,1770.337074 +Sudan,1962,11183227,Africa,40.87,1959.593767 +Sudan,1967,12716129,Africa,42.858,1687.997641 +Sudan,1972,14597019,Africa,45.083,1659.652775 +Sudan,1977,17104986,Africa,47.8,2202.988423 +Sudan,1982,20367053,Africa,50.338,1895.544073 +Sudan,1987,24725960,Africa,51.744,1507.819159 +Sudan,1992,28227588,Africa,53.556,1492.197043 +Sudan,1997,32160729,Africa,55.373,1632.210764 +Sudan,2002,37090298,Africa,56.369,1993.398314 +Sudan,2007,42292929,Africa,58.556,2602.394995 +Swaziland,1952,290243,Africa,41.407,1148.376626 +Swaziland,1957,326741,Africa,43.424,1244.708364 +Swaziland,1962,370006,Africa,44.992,1856.182125 +Swaziland,1967,420690,Africa,46.633,2613.101665 +Swaziland,1972,480105,Africa,49.552,3364.836625 +Swaziland,1977,551425,Africa,52.537,3781.410618 +Swaziland,1982,649901,Africa,55.561,3895.384018 +Swaziland,1987,779348,Africa,57.678,3984.839812 +Swaziland,1992,962344,Africa,58.474,3553.0224 +Swaziland,1997,1054486,Africa,54.289,3876.76846 +Swaziland,2002,1130269,Africa,43.869,4128.116943 +Swaziland,2007,1133066,Africa,39.613,4513.480643 +Sweden,1952,7124673,Europe,71.86,8527.844662 +Sweden,1957,7363802,Europe,72.49,9911.878226 +Sweden,1962,7561588,Europe,73.37,12329.44192 +Sweden,1967,7867931,Europe,74.16,15258.29697 +Sweden,1972,8122293,Europe,74.72,17832.02464 +Sweden,1977,8251648,Europe,75.44,18855.72521 +Sweden,1982,8325260,Europe,76.42,20667.38125 +Sweden,1987,8421403,Europe,77.19,23586.92927 +Sweden,1992,8718867,Europe,78.16,23880.01683 +Sweden,1997,8897619,Europe,79.39,25266.59499 +Sweden,2002,8954175,Europe,80.04,29341.63093 +Sweden,2007,9031088,Europe,80.884,33859.74835 +Switzerland,1952,4815000,Europe,69.62,14734.23275 +Switzerland,1957,5126000,Europe,70.56,17909.48973 +Switzerland,1962,5666000,Europe,71.32,20431.0927 +Switzerland,1967,6063000,Europe,72.77,22966.14432 +Switzerland,1972,6401400,Europe,73.78,27195.11304 +Switzerland,1977,6316424,Europe,75.39,26982.29052 +Switzerland,1982,6468126,Europe,76.21,28397.71512 +Switzerland,1987,6649942,Europe,77.41,30281.70459 +Switzerland,1992,6995447,Europe,78.03,31871.5303 +Switzerland,1997,7193761,Europe,79.37,32135.32301 +Switzerland,2002,7361757,Europe,80.62,34480.95771 +Switzerland,2007,7554661,Europe,81.701,37506.41907 +Syria,1952,3661549,Asia,45.883,1643.485354 +Syria,1957,4149908,Asia,48.284,2117.234893 +Syria,1962,4834621,Asia,50.305,2193.037133 +Syria,1967,5680812,Asia,53.655,1881.923632 +Syria,1972,6701172,Asia,57.296,2571.423014 +Syria,1977,7932503,Asia,61.195,3195.484582 +Syria,1982,9410494,Asia,64.59,3761.837715 +Syria,1987,11242847,Asia,66.974,3116.774285 +Syria,1992,13219062,Asia,69.249,3340.542768 +Syria,1997,15081016,Asia,71.527,4014.238972 +Syria,2002,17155814,Asia,73.053,4090.925331 +Syria,2007,19314747,Asia,74.143,4184.548089 +Taiwan,1952,8550362,Asia,58.5,1206.947913 +Taiwan,1957,10164215,Asia,62.4,1507.86129 +Taiwan,1962,11918938,Asia,65.2,1822.879028 +Taiwan,1967,13648692,Asia,67.5,2643.858681 +Taiwan,1972,15226039,Asia,69.39,4062.523897 +Taiwan,1977,16785196,Asia,70.59,5596.519826 +Taiwan,1982,18501390,Asia,72.16,7426.354774 +Taiwan,1987,19757799,Asia,73.4,11054.56175 +Taiwan,1992,20686918,Asia,74.26,15215.6579 +Taiwan,1997,21628605,Asia,75.25,20206.82098 +Taiwan,2002,22454239,Asia,76.99,23235.42329 +Taiwan,2007,23174294,Asia,78.4,28718.27684 +Tanzania,1952,8322925,Africa,41.215,716.6500721 +Tanzania,1957,9452826,Africa,42.974,698.5356073 +Tanzania,1962,10863958,Africa,44.246,722.0038073 +Tanzania,1967,12607312,Africa,45.757,848.2186575 +Tanzania,1972,14706593,Africa,47.62,915.9850592 +Tanzania,1977,17129565,Africa,49.919,962.4922932 +Tanzania,1982,19844382,Africa,50.608,874.2426069 +Tanzania,1987,23040630,Africa,51.535,831.8220794 +Tanzania,1992,26605473,Africa,50.44,825.682454 +Tanzania,1997,30686889,Africa,48.466,789.1862231 +Tanzania,2002,34593779,Africa,49.651,899.0742111 +Tanzania,2007,38139640,Africa,52.517,1107.482182 +Thailand,1952,21289402,Asia,50.848,757.7974177 +Thailand,1957,25041917,Asia,53.63,793.5774148 +Thailand,1962,29263397,Asia,56.061,1002.199172 +Thailand,1967,34024249,Asia,58.285,1295.46066 +Thailand,1972,39276153,Asia,60.405,1524.358936 +Thailand,1977,44148285,Asia,62.494,1961.224635 +Thailand,1982,48827160,Asia,64.597,2393.219781 +Thailand,1987,52910342,Asia,66.084,2982.653773 +Thailand,1992,56667095,Asia,67.298,4616.896545 +Thailand,1997,60216677,Asia,67.521,5852.625497 +Thailand,2002,62806748,Asia,68.564,5913.187529 +Thailand,2007,65068149,Asia,70.616,7458.396327 +Togo,1952,1219113,Africa,38.596,859.8086567 +Togo,1957,1357445,Africa,41.208,925.9083202 +Togo,1962,1528098,Africa,43.922,1067.53481 +Togo,1967,1735550,Africa,46.769,1477.59676 +Togo,1972,2056351,Africa,49.759,1649.660188 +Togo,1977,2308582,Africa,52.887,1532.776998 +Togo,1982,2644765,Africa,55.471,1344.577953 +Togo,1987,3154264,Africa,56.941,1202.201361 +Togo,1992,3747553,Africa,58.061,1034.298904 +Togo,1997,4320890,Africa,58.39,982.2869243 +Togo,2002,4977378,Africa,57.561,886.2205765 +Togo,2007,5701579,Africa,58.42,882.9699438 +Trinidad and Tobago,1952,662850,Americas,59.1,3023.271928 +Trinidad and Tobago,1957,764900,Americas,61.8,4100.3934 +Trinidad and Tobago,1962,887498,Americas,64.9,4997.523971 +Trinidad and Tobago,1967,960155,Americas,65.4,5621.368472 +Trinidad and Tobago,1972,975199,Americas,65.9,6619.551419 +Trinidad and Tobago,1977,1039009,Americas,68.3,7899.554209 +Trinidad and Tobago,1982,1116479,Americas,68.832,9119.528607 +Trinidad and Tobago,1987,1191336,Americas,69.582,7388.597823 +Trinidad and Tobago,1992,1183669,Americas,69.862,7370.990932 +Trinidad and Tobago,1997,1138101,Americas,69.465,8792.573126 +Trinidad and Tobago,2002,1101832,Americas,68.976,11460.60023 +Trinidad and Tobago,2007,1056608,Americas,69.819,18008.50924 +Tunisia,1952,3647735,Africa,44.6,1468.475631 +Tunisia,1957,3950849,Africa,47.1,1395.232468 +Tunisia,1962,4286552,Africa,49.579,1660.30321 +Tunisia,1967,4786986,Africa,52.053,1932.360167 +Tunisia,1972,5303507,Africa,55.602,2753.285994 +Tunisia,1977,6005061,Africa,59.837,3120.876811 +Tunisia,1982,6734098,Africa,64.048,3560.233174 +Tunisia,1987,7724976,Africa,66.894,3810.419296 +Tunisia,1992,8523077,Africa,70.001,4332.720164 +Tunisia,1997,9231669,Africa,71.973,4876.798614 +Tunisia,2002,9770575,Africa,73.042,5722.895655 +Tunisia,2007,10276158,Africa,73.923,7092.923025 +Turkey,1952,22235677,Europe,43.585,1969.10098 +Turkey,1957,25670939,Europe,48.079,2218.754257 +Turkey,1962,29788695,Europe,52.098,2322.869908 +Turkey,1967,33411317,Europe,54.336,2826.356387 +Turkey,1972,37492953,Europe,57.005,3450.69638 +Turkey,1977,42404033,Europe,59.507,4269.122326 +Turkey,1982,47328791,Europe,61.036,4241.356344 +Turkey,1987,52881328,Europe,63.108,5089.043686 +Turkey,1992,58179144,Europe,66.146,5678.348271 +Turkey,1997,63047647,Europe,68.835,6601.429915 +Turkey,2002,67308928,Europe,70.845,6508.085718 +Turkey,2007,71158647,Europe,71.777,8458.276384 +Uganda,1952,5824797,Africa,39.978,734.753484 +Uganda,1957,6675501,Africa,42.571,774.3710692 +Uganda,1962,7688797,Africa,45.344,767.2717398 +Uganda,1967,8900294,Africa,48.051,908.9185217 +Uganda,1972,10190285,Africa,51.016,950.735869 +Uganda,1977,11457758,Africa,50.35,843.7331372 +Uganda,1982,12939400,Africa,49.849,682.2662268 +Uganda,1987,15283050,Africa,51.509,617.7244065 +Uganda,1992,18252190,Africa,48.825,644.1707969 +Uganda,1997,21210254,Africa,44.578,816.559081 +Uganda,2002,24739869,Africa,47.813,927.7210018 +Uganda,2007,29170398,Africa,51.542,1056.380121 +United Kingdom,1952,50430000,Europe,69.18,9979.508487 +United Kingdom,1957,51430000,Europe,70.42,11283.17795 +United Kingdom,1962,53292000,Europe,70.76,12477.17707 +United Kingdom,1967,54959000,Europe,71.36,14142.85089 +United Kingdom,1972,56079000,Europe,72.01,15895.11641 +United Kingdom,1977,56179000,Europe,72.76,17428.74846 +United Kingdom,1982,56339704,Europe,74.04,18232.42452 +United Kingdom,1987,56981620,Europe,75.007,21664.78767 +United Kingdom,1992,57866349,Europe,76.42,22705.09254 +United Kingdom,1997,58808266,Europe,77.218,26074.53136 +United Kingdom,2002,59912431,Europe,78.471,29478.99919 +United Kingdom,2007,60776238,Europe,79.425,33203.26128 +United States,1952,157553000,Americas,68.44,13990.48208 +United States,1957,171984000,Americas,69.49,14847.12712 +United States,1962,186538000,Americas,70.21,16173.14586 +United States,1967,198712000,Americas,70.76,19530.36557 +United States,1972,209896000,Americas,71.34,21806.03594 +United States,1977,220239000,Americas,73.38,24072.63213 +United States,1982,232187835,Americas,74.65,25009.55914 +United States,1987,242803533,Americas,75.02,29884.35041 +United States,1992,256894189,Americas,76.09,32003.93224 +United States,1997,272911760,Americas,76.81,35767.43303 +United States,2002,287675526,Americas,77.31,39097.09955 +United States,2007,301139947,Americas,78.242,42951.65309 +Uruguay,1952,2252965,Americas,66.071,5716.766744 +Uruguay,1957,2424959,Americas,67.044,6150.772969 +Uruguay,1962,2598466,Americas,68.253,5603.357717 +Uruguay,1967,2748579,Americas,68.468,5444.61962 +Uruguay,1972,2829526,Americas,68.673,5703.408898 +Uruguay,1977,2873520,Americas,69.481,6504.339663 +Uruguay,1982,2953997,Americas,70.805,6920.223051 +Uruguay,1987,3045153,Americas,71.918,7452.398969 +Uruguay,1992,3149262,Americas,72.752,8137.004775 +Uruguay,1997,3262838,Americas,74.223,9230.240708 +Uruguay,2002,3363085,Americas,75.307,7727.002004 +Uruguay,2007,3447496,Americas,76.384,10611.46299 +Venezuela,1952,5439568,Americas,55.088,7689.799761 +Venezuela,1957,6702668,Americas,57.907,9802.466526 +Venezuela,1962,8143375,Americas,60.77,8422.974165 +Venezuela,1967,9709552,Americas,63.479,9541.474188 +Venezuela,1972,11515649,Americas,65.712,10505.25966 +Venezuela,1977,13503563,Americas,67.456,13143.95095 +Venezuela,1982,15620766,Americas,68.557,11152.41011 +Venezuela,1987,17910182,Americas,70.19,9883.584648 +Venezuela,1992,20265563,Americas,71.15,10733.92631 +Venezuela,1997,22374398,Americas,72.146,10165.49518 +Venezuela,2002,24287670,Americas,72.766,8605.047831 +Venezuela,2007,26084662,Americas,73.747,11415.80569 +Vietnam,1952,26246839,Asia,40.412,605.0664917 +Vietnam,1957,28998543,Asia,42.887,676.2854478 +Vietnam,1962,33796140,Asia,45.363,772.0491602 +Vietnam,1967,39463910,Asia,47.838,637.1232887 +Vietnam,1972,44655014,Asia,50.254,699.5016441 +Vietnam,1977,50533506,Asia,55.764,713.5371196 +Vietnam,1982,56142181,Asia,58.816,707.2357863 +Vietnam,1987,62826491,Asia,62.82,820.7994449 +Vietnam,1992,69940728,Asia,67.662,989.0231487 +Vietnam,1997,76048996,Asia,70.672,1385.896769 +Vietnam,2002,80908147,Asia,73.017,1764.456677 +Vietnam,2007,85262356,Asia,74.249,2441.576404 +West Bank and Gaza,1952,1030585,Asia,43.16,1515.592329 +West Bank and Gaza,1957,1070439,Asia,45.671,1827.067742 +West Bank and Gaza,1962,1133134,Asia,48.127,2198.956312 +West Bank and Gaza,1967,1142636,Asia,51.631,2649.715007 +West Bank and Gaza,1972,1089572,Asia,56.532,3133.409277 +West Bank and Gaza,1977,1261091,Asia,60.765,3682.831494 +West Bank and Gaza,1982,1425876,Asia,64.406,4336.032082 +West Bank and Gaza,1987,1691210,Asia,67.046,5107.197384 +West Bank and Gaza,1992,2104779,Asia,69.718,6017.654756 +West Bank and Gaza,1997,2826046,Asia,71.096,7110.667619 +West Bank and Gaza,2002,3389578,Asia,72.37,4515.487575 +West Bank and Gaza,2007,4018332,Asia,73.422,3025.349798 +Yemen Rep.,1952,4963829,Asia,32.548,781.7175761 +Yemen Rep.,1957,5498090,Asia,33.97,804.8304547 +Yemen Rep.,1962,6120081,Asia,35.18,825.6232006 +Yemen Rep.,1967,6740785,Asia,36.984,862.4421463 +Yemen Rep.,1972,7407075,Asia,39.848,1265.047031 +Yemen Rep.,1977,8403990,Asia,44.175,1829.765177 +Yemen Rep.,1982,9657618,Asia,49.113,1977.55701 +Yemen Rep.,1987,11219340,Asia,52.922,1971.741538 +Yemen Rep.,1992,13367997,Asia,55.599,1879.496673 +Yemen Rep.,1997,15826497,Asia,58.02,2117.484526 +Yemen Rep.,2002,18701257,Asia,60.308,2234.820827 +Yemen Rep.,2007,22211743,Asia,62.698,2280.769906 +Zambia,1952,2672000,Africa,42.038,1147.388831 +Zambia,1957,3016000,Africa,44.077,1311.956766 +Zambia,1962,3421000,Africa,46.023,1452.725766 +Zambia,1967,3900000,Africa,47.768,1777.077318 +Zambia,1972,4506497,Africa,50.107,1773.498265 +Zambia,1977,5216550,Africa,51.386,1588.688299 +Zambia,1982,6100407,Africa,51.821,1408.678565 +Zambia,1987,7272406,Africa,50.821,1213.315116 +Zambia,1992,8381163,Africa,46.1,1210.884633 +Zambia,1997,9417789,Africa,40.238,1071.353818 +Zambia,2002,10595811,Africa,39.193,1071.613938 +Zambia,2007,11746035,Africa,42.384,1271.211593 +Zimbabwe,1952,3080907,Africa,48.451,406.8841148 +Zimbabwe,1957,3646340,Africa,50.469,518.7642681 +Zimbabwe,1962,4277736,Africa,52.358,527.2721818 +Zimbabwe,1967,4995432,Africa,53.995,569.7950712 +Zimbabwe,1972,5861135,Africa,55.635,799.3621758 +Zimbabwe,1977,6642107,Africa,57.674,685.5876821 +Zimbabwe,1982,7636524,Africa,60.363,788.8550411 +Zimbabwe,1987,9216418,Africa,62.351,706.1573059 +Zimbabwe,1992,10704340,Africa,60.377,693.4207856 +Zimbabwe,1997,11404948,Africa,46.809,792.4499603 +Zimbabwe,2002,11926563,Africa,39.989,672.0386227 +Zimbabwe,2007,12311143,Africa,43.487,469.7092981 From 7710e6d876b08b011195e33046f581bc283113b4 Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci <33600128+cforgaci@users.noreply.github.com> Date: Wed, 17 Jan 2024 11:42:47 +0100 Subject: [PATCH 30/38] Remove description of geospatial data to avoid confusion --- episodes/02-data-structures.Rmd | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/episodes/02-data-structures.Rmd b/episodes/02-data-structures.Rmd index f4994711..d21b9251 100644 --- a/episodes/02-data-structures.Rmd +++ b/episodes/02-data-structures.Rmd @@ -55,7 +55,7 @@ In short: For a more detailed description, see [Data Types and Structures](https://swcarpentry.github.io/r-novice-inflammation/13-supp-data-structures.html). -Data structures for geospatial data use combinations of lists, data frames, matrices and vectors. While vector data (not the data structure with the same name!) combines a data frame structure with lists for attributes and geometry in a nested way, raster data are essentially represented as matrices in which each cell is a pixel. More about vector and raster data later in the workshop! +Note that vector data in the geospatial context is different from vector data types. More about vector data in a [later lesson](../episodes/09-open-and-plot-vector-layers.Rmd)! ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: From e9afcefe8721651d60c53696fcb7ff0079850887 Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci Date: Wed, 17 Jan 2024 11:46:12 +0100 Subject: [PATCH 31/38] Replace read.csv() with read_csv() --- episodes/03-explore-data.Rmd | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/episodes/03-explore-data.Rmd b/episodes/03-explore-data.Rmd index 330969aa..5214f95a 100644 --- a/episodes/03-explore-data.Rmd +++ b/episodes/03-explore-data.Rmd @@ -66,7 +66,7 @@ For example, here is a figure depicting a data frame comprising a numeric, a cha We're gonna read in the `gapminder` data set with information about countries' size, GDP and average life expectancy in different years. ```{r reading-data} -gapminder <- read.csv("data/gapminder_data.csv") +gapminder <- read_csv("data/gapminder_data.csv") ``` From 1ad3944e1953a592351b85a75d09a3b74c7ebdd2 Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci Date: Wed, 17 Jan 2024 11:53:44 +0100 Subject: [PATCH 32/38] Update missing image and path to it in Rmd --- episodes/03-explore-data.Rmd | 2 +- episodes/fig/data-frame.svg | 269 +++++++++++++++++++++++++++++++++++ 2 files changed, 270 insertions(+), 1 deletion(-) create mode 100644 episodes/fig/data-frame.svg diff --git a/episodes/03-explore-data.Rmd b/episodes/03-explore-data.Rmd index 5214f95a..1e334c00 100644 --- a/episodes/03-explore-data.Rmd +++ b/episodes/03-explore-data.Rmd @@ -56,7 +56,7 @@ A data frame is a representation of data in the format of a **table** where the Because columns are vectors, each column must contain a **single type of data** (e.g., characters, numeric, factors). For example, here is a figure depicting a data frame comprising a numeric, a character, and a logical vector. -![](assets/img/data-frame.svg) +![](fig/data-frame.svg) *Source*:[Data Carpentry R for Social Scientists ](https://datacarpentry.org/r-socialsci/02-starting-with-data/index.html#what-are-data-frames-and-tibbles) diff --git a/episodes/fig/data-frame.svg b/episodes/fig/data-frame.svg new file mode 100644 index 00000000..b82230ef --- /dev/null +++ b/episodes/fig/data-frame.svg @@ -0,0 +1,269 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + From f4155bcc6ccbe129ea2d51bd93973a6c17bdcb1d Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci Date: Mon, 22 Jan 2024 09:40:24 +0100 Subject: [PATCH 33/38] Fix incomplete code chunk --- episodes/03-explore-data.Rmd | 1 + 1 file changed, 1 insertion(+) diff --git a/episodes/03-explore-data.Rmd b/episodes/03-explore-data.Rmd index 1e334c00..b2e3a4a0 100644 --- a/episodes/03-explore-data.Rmd +++ b/episodes/03-explore-data.Rmd @@ -220,6 +220,7 @@ gapminder %>% group_by(country) %>% summarize(avg_lifeExp=mean(lifeExp)) %>% filter(avg_lifeExp == min(avg_lifeExp) | avg_lifeExp == max(avg_lifeExp)) +``` ### Multiple groups and summary variables You can also group by multiple columns: From 1b9b03af4e1661252368a2a42fb000cef6de1833 Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci <33600128+cforgaci@users.noreply.github.com> Date: Mon, 22 Jan 2024 10:01:11 +0100 Subject: [PATCH 34/38] Apply Jerome's suggestions Co-authored-by: fcjerome <129063142+fcjerome@users.noreply.github.com> --- episodes/03-explore-data.Rmd | 26 +++++++++----------------- episodes/04-intro-to-visualisation.Rmd | 12 +++++++++++- 2 files changed, 20 insertions(+), 18 deletions(-) diff --git a/episodes/03-explore-data.Rmd b/episodes/03-explore-data.Rmd index b2e3a4a0..b59b3340 100644 --- a/episodes/03-explore-data.Rmd +++ b/episodes/03-explore-data.Rmd @@ -90,7 +90,7 @@ There are multiple ways to explore a data set. Here are just a few examples: ```{r} -head(gapminder) # see first 5 rows of the data set +head(gapminder) # see first 6 rows of the data set summary(gapminder) # gives basic statistical information about each column. Information format differes by data type. @@ -150,7 +150,7 @@ First we define data set, then - with the use of pipe we pass it on to the `sele ## Filter -We already know how to select only the needed columns. But now, we also want to filter the data set via certain conditions with `filter()` function. Instead of doing it in separate steps, we can do it all together. +We already know how to select only the needed columns. But now, we also want to filter the rows of our data set via certain conditions with `filter()` function. Instead of doing it in separate steps, we can do it all together. In the `gapminder` data set, we want to see the results from outside of Europe for the 21st century. ```{r} @@ -160,15 +160,6 @@ year_country_gdp_euro <- gapminder %>% head(year_country_gdp_euro) ``` -Let's now find all the observations from Eurasia: - -```{r} -year_country_gdp_eurasia <- gapminder %>% - filter(continent == "Europe" | continent == "Asia") %>% # I operator (OR) - one of the conditions must be met - select(year, country, gdpPercap) - -head(year_country_gdp_eurasia) -``` ### Exercise 1 @@ -183,10 +174,9 @@ Write a single command (which can span multiple lines and includes pipes) that w ```{r ex5, class.source="bg-info"} -year_country_lifeExp_Africa <- gapminder %>% - filter(continent=="Africa" ) %>% - select(year,country,lifeExp) - +year_country_gdp_eurasia <- gapminder %>% + filter(continent == "Europe" | continent == "Asia") %>% # | operator (OR) - one of the conditions must be met + select(year, country, gdpPercap) nrow(year_country_lifeExp_Africa) ``` @@ -194,7 +184,7 @@ nrow(year_country_lifeExp_Africa) ## Group and summarize -So far, we have created a data frame for one of the continents represented in the `gapminder` data set. But often instead of doing that, we would like to know statistics about all of the continents, presented by group. +So far, we have provided summary statistics on the whole dataset, selected columns, and filtered the observations. But often instead of doing that, we would like to know statistics about all of the continents, presented by group. ```{r dplyr-group} gapminder %>% # select the dataset @@ -273,7 +263,9 @@ head(gapminder_gdp) ::::::::::::::::::::::::::::::::::::: keypoints -- +- We can use the `select()` and `filter()` functions to select certain columns in a data frame and to subset it based a specific conditions. +- With `mutate()`, we can create new columns in a data frame with values based on existing columns. +- By combining `group_by()` and `summarize()` in a pipe (`%>%`) chain, we can generate summary statistics for each group in a data frame. :::::::::::::::::::::::::::::::::::::::::::::::: diff --git a/episodes/04-intro-to-visualisation.Rmd b/episodes/04-intro-to-visualisation.Rmd index df78e234..56227978 100644 --- a/episodes/04-intro-to-visualisation.Rmd +++ b/episodes/04-intro-to-visualisation.Rmd @@ -145,7 +145,7 @@ gapminder %>% ``` Maybe we don't need that much information about the life expectancy. We -only want to know if it's below or above average. +only want to know if it's below or above average. We will make use of the `if_else()` function inside `mutate()` to create a new column `lifeExpCat` with the value `high` if life expectancy is above average and `low` otherwise. Note the usage of the `if_else()` function: `if_else(, , )`. ```{r ggplot-colors-discrete} p <- # this time let's save the plot in an object @@ -226,3 +226,13 @@ gapminder_amr_2007 <- gapminder %>% write.csv(gapminder_amr_2007, here('data_output', 'gapminder_americas_2007.csv'), row.names=FALSE) ``` + +::::::::::::::::::::::::::::::::::::: keypoints + +- With `ggplot2`, we use the `+` operator to combine plot layers and incrementally build a more complex plot. +- In the aesthetics (`aes()`), we can assign variables to the x and y axes and use the `fill` argument for colouring surfaces. +- With `scale_fill_viridis_c()` and `scale_fill_manual()` we can assign new colours to our plot. +- To open the help documentation for a function, we run the name of the function preceded by the `?` sign. + +:::::::::::::::::::::::::::::::::::::::::::::::: + From b6516ec550d0dd05693d50918fb2c93f412f7bd0 Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci <33600128+cforgaci@users.noreply.github.com> Date: Mon, 22 Jan 2024 10:02:24 +0100 Subject: [PATCH 35/38] Update format of objectives in intro lesson --- episodes/01-intro-to-r.Rmd | 2 ++ episodes/02-data-structures.Rmd | 2 ++ episodes/03-explore-data.Rmd | 2 ++ episodes/04-intro-to-visualisation.Rmd | 2 ++ 4 files changed, 8 insertions(+) diff --git a/episodes/01-intro-to-r.Rmd b/episodes/01-intro-to-r.Rmd index ab5c33c1..9593a135 100644 --- a/episodes/01-intro-to-r.Rmd +++ b/episodes/01-intro-to-r.Rmd @@ -38,6 +38,8 @@ invisible(lapply(packages, library, character.only = TRUE)) ::::::::::::::::::::::::::::::::::::: objectives +After completing this episode, participants should be able to… + - Create self-contained projects in RStudio - Install additional packages using R code. - Manage packages diff --git a/episodes/02-data-structures.Rmd b/episodes/02-data-structures.Rmd index d21b9251..dc3673a9 100644 --- a/episodes/02-data-structures.Rmd +++ b/episodes/02-data-structures.Rmd @@ -13,6 +13,8 @@ exercises: 2 ::::::::::::::::::::::::::::::::::::: objectives +After completing this episode, participants should be able to… + - To be aware of the different types of data. - To begin exploring data frames, and understand how they are related to vectors, factors and lists. - To be able to ask questions from R about the type, class, and structure of an object. diff --git a/episodes/03-explore-data.Rmd b/episodes/03-explore-data.Rmd index b59b3340..2f9b5051 100644 --- a/episodes/03-explore-data.Rmd +++ b/episodes/03-explore-data.Rmd @@ -33,6 +33,8 @@ invisible(lapply(packages, library, character.only = TRUE)) ::::::::::::::::::::::::::::::::::::: objectives +After completing this episode, participants should be able to… + - Describe what a data frame is. - Load external data from a .csv file into a data frame. - Summarize the contents of a data frame. diff --git a/episodes/04-intro-to-visualisation.Rmd b/episodes/04-intro-to-visualisation.Rmd index 56227978..60f9b941 100644 --- a/episodes/04-intro-to-visualisation.Rmd +++ b/episodes/04-intro-to-visualisation.Rmd @@ -36,6 +36,8 @@ gapminder <- read.csv("data/gapminder_data.csv") ::::::::::::::::::::::::::::::::::::: objectives +After completing this episode, participants should be able to… + - Generate plots to visualise data with `ggplot2`. - Add plot layers to incrementally build a more complex plot. - Use the `fill` argument for colouring surfaces, and modify colours with the viridis or scale_manual packages. From f29dc7365cf16e4130fdd886073b65b6cde0e1ad Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci <33600128+cforgaci@users.noreply.github.com> Date: Mon, 22 Jan 2024 10:17:47 +0100 Subject: [PATCH 36/38] Move figure source to new line Co-authored-by: KyriJanssen <105053276+KyriJanssen@users.noreply.github.com> --- episodes/02-data-structures.Rmd | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/episodes/02-data-structures.Rmd b/episodes/02-data-structures.Rmd index dc3673a9..bee71477 100644 --- a/episodes/02-data-structures.Rmd +++ b/episodes/02-data-structures.Rmd @@ -90,7 +90,25 @@ abcd_vector ``` -### Missing values +### Missing values + +::::::::::::::::::::::::::::::::::::: challenge + +### Exercise + +Combine the `abcd_vector` with the `numeric_vector` in R. What is the data type of this new vector and why? + +:::::::::::::::::::::::: solution + +``` +combined_vector <- c(abcd_vector, numeric_vector) +combined_vector +``` +The combined vector is a character vector. Because vectors can only hold one data type and `abcd_vector` cannot be interpreted as numbers, the numbers in `numeric_vector` are _coerced_ into characters. + +::::::::::::::::::::::::::::::::: + +:::::::::::::::::::::::::::::::::::::::::::::::: A common operation you want to perform is to remove all the missing values (in R denoted as `NA`). Let's have a look how to do it: From 35769318121d78b88a99102e8a08c276952c2d26 Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci <33600128+cforgaci@users.noreply.github.com> Date: Mon, 22 Jan 2024 10:19:55 +0100 Subject: [PATCH 37/38] Update episodes/03-explore-data.Rmd --- episodes/03-explore-data.Rmd | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/episodes/03-explore-data.Rmd b/episodes/03-explore-data.Rmd index 2f9b5051..56fe065e 100644 --- a/episodes/03-explore-data.Rmd +++ b/episodes/03-explore-data.Rmd @@ -59,7 +59,7 @@ Because columns are vectors, each column must contain a **single type of data** For example, here is a figure depicting a data frame comprising a numeric, a character, and a logical vector. ![](fig/data-frame.svg) -*Source*:[Data Carpentry R for Social Scientists ](https://datacarpentry.org/r-socialsci/02-starting-with-data/index.html#what-are-data-frames-and-tibbles) +
*Source*:[Data Carpentry R for Social Scientists ](https://datacarpentry.org/r-socialsci/02-starting-with-data/index.html#what-are-data-frames-and-tibbles) ## Reading data From f4bb56094f61ea634f3ea3249156303161800008 Mon Sep 17 00:00:00 2001 From: Claudiu Forgaci <33600128+cforgaci@users.noreply.github.com> Date: Mon, 22 Jan 2024 17:21:17 +0100 Subject: [PATCH 38/38] Apply suggestions from code review Co-authored-by: fcjerome <129063142+fcjerome@users.noreply.github.com> --- episodes/03-explore-data.Rmd | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/episodes/03-explore-data.Rmd b/episodes/03-explore-data.Rmd index 56fe065e..5fab2d56 100644 --- a/episodes/03-explore-data.Rmd +++ b/episodes/03-explore-data.Rmd @@ -180,7 +180,7 @@ year_country_gdp_eurasia <- gapminder %>% filter(continent == "Europe" | continent == "Asia") %>% # | operator (OR) - one of the conditions must be met select(year, country, gdpPercap) -nrow(year_country_lifeExp_Africa) +nrow(year_country_gdp_eurasia) ```