in our present world of automationcloud computingalgorithmsartificial intelligenceand big datafew topics are as relevant as data science and machine learning their recent popularity lies not only in their applicability to real-life questionsbut also in their natural blending of many different disciplinesincluding mathematicsstatisticscomputer scienceengineeringscienceand finance to someone starting to learn these topicsthe multitude of computational techniques and mathematical ideas may seem overwhelming some may be satisfied with only learning how to use off-the-shelf recipes to apply to practical situations but what if the assumptions of the black-box recipe are violatedcan we still trust the resultshow should the algorithm be adaptedto be able to truly understand data science and machine learning it is important to appreciate the underlying mathematics and statisticsas well as the resulting algorithms the purpose of this book is to provide an accessibleyet comprehensiveaccount of data science and machine learning it is intended for anyone interested in gaining better understanding of the mathematics and statistics that underpin the rich variety of ideas and machine learning algorithms in data science our viewpoint is that computer languages come and gobut the underlying key ideas and algorithms will remain forever and will form the basis for future developments before we turn to description of the topics in this bookwe would like to say few words about its philosophy this book resulted from various courses in data science and machine learning at the universities of queensland and new south walesaustralia when we taught these courseswe noticed that students were eager to learn not only how to apply algorithms but also to understand how these algorithms actually work howevermany existing textbooks assumed either too much background knowledge ( measure theory and functional analysisor too little (everything is black box)and the information overload from often disjointed and contradictory internet sources made it more difficult for students to gradually build up their knowledge and understanding we therefore wanted to write book about data science and machine learning that can be read as linear storywith substantial "backstoryin the appendices the main narrative starts very simply and builds up gradually to quite an advanced level the backstory contains all the necessary xiii