Multivariate Statistics and Machine Learning in R For Beginners

Chapter 1 A brief introduction to machine learning and multivariate statistics

An introduction to Machine Learning and Multivariate Statistics – video

An introduction to R – video

Chapter 2 Matrix Algebra

Basic matrix operations

R script

Determinant and inverse of a matrix

R script

Eigenvectors and eigenvalues

R script

Chapter 3 Managing data in R

Working with data frames

R script

Generate random data

R script

Missing data and imputation

R script

Datasets used in this book

R script

Chapter 4 Graphical illustration of multivariate data

R script

Chapter 5 Covariance and the correlation matrix

R script

Chapter 6 PCA and PCoA

Principal component analysis

R script

Standardization and how to extract components

R script

Loadings and Varimax rotation

R script

Principal Coordinates Analysis (PCoA)

R script

Chapter 7 Linear discriminant analysis

R script

Chapter 8 Distances in space

R script

Chapter 9 Multivariate statistical tests

Hotelling’s T-square and MANOVA

R script

PERMANOVA

R script

Canonical correlation analysis

R script

Chapter 10 Classification and performance metrics

Diagnostic Metrics

R script

ROC curve

R script

Validation

R script

Chapter 11 Supervised Machine Learning

Validation and evaluation

Linear discriminant analysis

R script

Logistic regression

R script

Decision trees

R script

Random forest

R script

k-Nearest Neighbors

R script

Gaussian Naive Bayes

R script

The problem with imbalanced datasets in ML

R script

Chapter 12 Clustering

Hierarchical clustering

R script

Heatmap

R script

K-Means clustering

R script

Chapter 13 PCR, PLS and Lasso regression

Principal component regression and Partial least squares regression

R script

Lasso regression

R script

Chapter 14 Case studies

Paper 1

Dataset: Cytokines

R script

Paper 2

R script

Chapter 15 Answers to the exercises

R script