Basic Linear Algebra with R

Basic linear algebra operations with R.  1 Introduction Linear algebra is the study of vectors and linear functions. On this post I’m going to show you how to perform some basic linear algebra operations with R. 2 Vector operations 2.1 Define vectors You can define vectors simply as follows: # Define two vectors x <- c(30, 20, 40, 10) y <- c(20, 15, 18, 40) 2.2 Sum You can add vectors with the same length:...

March 28, 2021