Introduction Correlation matrix Correlogram Correlation test Code Photo by Pritesh Sudra Introduction Correlation, often computed as part of descriptive statistics, is a statistical tool used to study the relationship between two variables, ...

R Markdown: what, why and how? Before you start Components of a .Rmd file YAML header Code chunks Text Code inside text Images Tables Additional notes and useful resources Photo by Jon Tyson If you have spent some time writing code in R, you probably have heard of generating dynamic reports incorporating R code, R outputs (results) and text or comments. In this article, I will explain how R Markdown...

What is clustering analysis? Application 1: Computing distances Solution k-means clustering Application 2: k-means clustering Data kmeans() with 2 groups Quality of a k-means partition nstart for several initial centers kmeans() with 3 groups Manual application and verification in R Solution by hand Solution in R Hierarchical clustering Application 3: hierarchical clustering Data Solution by hand Single linkage Complete linkage Average linkage Solution in R Single linkage Complete linkage Average linkage k-means versus hierarchical clustering References Photo by Nikola Johnny Mirkovic What is clustering analysis? Clustering analysis...

What is a R package and how to use it? Inefficient way to install and load R packages More efficient way What is a R package and how to use it? Unlike other programs, only fundamental functionalities come by default with R. You will thus often need to install some “extensions” to perform the analyses you want. These extensions which are are collections...

What is a normal distribution? Empirical rule Parameters Probabilities and standard normal distribution Areas under the normal distribution in R and by hand Ex. 1 In R By hand Ex. 2 In R By hand Ex. 3 In R By hand Ex. 4 In R By hand Ex. 5 Why is the normal distribution so crucial in statistics? How to test the normality assumption Histogram Density plot QQ-plot Normality test References What is a normal distribution? The normal distribution is a function that defines how...

Introduction Hypotheses Example Data Observed frequencies Expected frequencies Fisher’s exact test in R Conclusion and interpretation References Introduction After presenting the Chi-square test of independence by hand and in R, this article focuses on the Fisher’s exact test. Independence tests are used to determine if there is a significant relationship between two categorical variables. There exists two different types of independence test: the Chi-square test (the most common) the Fisher’s exact test On...

Introduction Example Data Chi-square test of independence Conclusion and interpretation Introduction This article explains how to perform the Chi-square test of independence in R and how to interpret its results. To learn more about how the test works and how to do it by hand, I invite you to read the article “Chi-square test of independence by hand”. To briefly recap what have been said in...

What are RStudio addins? Installation Addins Esquisse Questionr Recoding factors Reordering factors Categorize a numeric variable Remedy Styler Snakecaser Blogdown What are RStudio addins? Although I have been using RStudio for several years, I only recently discovered RStudio addins. Since then, I am using these addins almost every time I use RStudio. What are RStudio addins? RStudio addins are extensions which provide a simple mechanism for executing advanced R functions from within RStudio....

Introduction Minimal reproducible example How to personalize it Introduction In this article, I show how to create a timeline of your CV in R. A CV timeline illustrates key information about your education, work experiences and extra activities. The main advantage of CV timelines compared to regular CV is that they make you stand out immediately by being visually appealing and easier to...

Introduction Data Minimum and maximum Range Mean Median First and third quartile Other quantiles Interquartile range Standard deviation and variance Summary Coefficient of variation Mode Contingency table Barplot Histogram Boxplot Scatterplot QQ-plot For a single variable By groups Density plot Introduction This article explains how to compute the main descriptive statistics in R and how to present them graphically. To learn more about the reasoning behind each descriptive statistics, how to compute them by hand and how to interpret them, read the...

e-mails with the latest R posts.

(You will not see this message again.)