Blog Archives

Tidy correlation tests in R

April 16, 2019
By
Tidy correlation tests in R

When we try to estimate the correlation coefficient between multiple variables, the task is more complicated in order to obtain a simple and tidy result. A simple solution is to use the tidy() function from the {broom} package. In this post we are going to estimate the correlation coefficients between the annual precipitation of several Spanish cities and climate...

Read more »

Import Excel sheets with R

March 9, 2019
By

We usually work with different data sources, and sometimes we can find tables distributed over several Excel sheets. In this post we are going to import the average daily temperature of Madrid and Berlin which is found in two Excel files with sheets for each year between 2000 and 2005: download. Packages In this post we will use the following packages: Packages Description tidyverse Collection...

Read more »

Calculating the distance to the sea in R

January 7, 2019
By
Calculating the distance to the sea in R

The distance to the sea is a fundamental variable in geography, especially relevant when it comes to modeling. For example, in interpolations of air temperature, the distance to the sea is usually used as a predictor variable, since there is a casual relationship between the two that explains the spatial variation. How can we estimate the (shortest) distance to...

Read more »

How to create ‘Warming Stripes’ in R

December 4, 2018
By
How to create ‘Warming Stripes’ in R

This year, the so-called warming stripes, which were created by the scientist Ed Hawkins of the University of Reading, became very famous all over the world. These graphs represent and communicate climate change in a very illustrative and effective way. Visualising global temperature change since records began in 1850. Versions for USA, central England & Toronto available too: https://t.co/H5Hv9YgZ7v pic.twitter.com/YMzdySrr3A—...

Read more »

Accessing OpenStreetMap data with R

November 2, 2018
By
Accessing OpenStreetMap data with R

The database of Open Street Maps Recently I created a map of the distribution of gas stations and electric charging stations in Europe. Population density through the number of gas stations in Europe. #dataviz @AGE_Oficial @mipazos @simongerman600 @openstreetmap pic.twitter.com/eIUx2yn7ej— Dominic Royé (@dr_xeo) February 25, 2018 How can you obtain this data? Well, in this case I used points of interest (POIs) from the...

Read more »

Access to climate reanalysis data from R

September 15, 2018
By
Access to climate reanalysis data from R

1 Introduction 2 NCEP 2.1 Packages 2.2 Data download 2.3 Monthly average 2.4 Visualization 3 ERA-Interim 3.1 Installation 3.2 Connection and download with the ECMWF API 3.3 Processing ncdf 4 Update for accessing ERA-5 A friend advised me to introduce R levels as categories. An idea that I now add to each blog post. There are three levels: elementary, intermediate, and advanced. I hope it will help the reader and...

Read more »

the pie chart

August 22, 2018
By
the pie chart

Welcome to my blog! I am Dominic Royé, researcher and lecturer of physical geography at the University of Santiago de Compostela. One of my passions is R programming to visualize and analyze any type of data. Hence, my idea of this blog has its origin in my datavis publications I have been cooking in the last year on Twitter...

Read more »

Search R-bloggers


Sponsors

Never miss an update!
Subscribe to R-bloggers to receive
e-mails with the latest R posts.
(You will not see this message again.)

Click here to close (This popup will not appear again)