You are here

Mathematical Foundations for Data Analysis

Jeff M. Phillips
Publication Date: 
Number of Pages: 
[Reviewed by
David R. Gurney
, on
This is an introductory text on the mathematics behind data science.  As someone who has dabbled at the edges of data science, the mathematics involved always seemed rather simplistic, but this book has changed my mind.  The book is fairly compact, but a lot of information is presented in those pages.  In terms of the mathematics discussed, the book is pretty much self-contained, but prior knowledge of linear algebra and python programming would benefit anyone reading the book.
The clear writing is backed in many instances by helpful illustrations.  Color is used judiciously throughout the text to help differentiate between objects and highlight items of interest.  Each of the eleven chapters has a set of exercises at the end to help reinforce the reader’s understanding of the topics presented.   
The notation choices in the book like \( Pr \) for probability, superscript T’s to signify transposes, and \( \left[n \right] \) to denote the set of integers  \( \left\{ 1, 2, \ldots, n \right\} \), are a definite aid in understanding.  Examples are bordered by green bands, geometric descriptions of underlying processes are bordered by maroon bands, and ethical questions that arise when the use of certain procedures is considered are bordered by blue bands.
To show how the various procedures presented in the book can be implemented, there are about twenty Python programs along with about thirty other algorithms presented in a pseudo programming format.  The author usually devotes a paragraph, before or after each algorithm, to explain how they work.  By presenting the algorithms in basic English (list the variables needed, state their initial values, describe the iterative steps, and identify the conditions for halting the process), these algorithms and their explanations would take up a lot less space. 
In the first 188 pages, there is about one error for every five pages.  This is probably to be expected for a first edition, especially one in a relatively new area that combines all kinds of mathematics: algebra, geometry, calculus, set theory, statistics, stochastic processes, and computation theory.  Most of the errors are basically typographical, but there are a couple of errors near the center of the book which are a little more serious.
On page 154, Phillips says the Frobenious norms of the matrices U and V from the singular value decomposition are one.  There is an example of a singular value decomposition given on page 151, and it is easy to check that the Frobenious norms of the matrices U and V in this example are not one.  What Phillips should have said – and the lead-in material seems to be headed in this direction – is that the matrices U and V are both norm-preserving.
Then on page 163, Phillips says the following:
Let \( E_{i} \) be an n x n matrix that is all 0s except the ith column which is all \( 1 \)s.  Then for a matrix \( Z \in R^{n \times n} \), the product \( E_{i} Z \) has each column as the ith column of \( Z \), and the product \( ZE_{i}^{T} \) has each row as the ith row of \( Z \). 
This explanation is backward.  Each row of \( E_{i} Z \) is the ith row of Z and each column of \( Z E_{i}^{T} \) is the ith column of \( Z \).  In the two display equations that follow, the symmetry of the formulas nullifies the error, but this is a dangerous mistake to make.
There are not many other self-contained sources on the mathematics of data science available.  Data Science for Mathematicians, edited by Nathan Carter (CRC Press 2020), at 544 pages is almost twice as long as Phillips’ book.  The chapters in Carter’s book, written by different authors, focus on different areas of mathematics and their relation to data science.  Thomas Nield’s Essential Math for Data Science is not scheduled for publication by O’Reilly until July 2022.  I’ve seen a cover image of a book with the same title by Hadrien Jean, also an O’Reilly product, but that’s all I know about it.  Most sources on the web recommend reading from three to a dozen or more books to learn about the mathematics behind data science.  Phillips’ book is much more concise, but still discusses many different mathematical aspects of data science.
David R. Gurney is an assistant professor of mathematics at Southeastern Louisiana University where he teaches many sections of elementary statistics.