As a starting point for tackling data analysis problems, I often start from the perspective of “how would I have done this in Excel, if even possible?” This is what happens when you’ve spent the bulk of your career knee-deep in Excel and then you shift to more advanced data science tools like Python and R.
I love good reference books and one that I keep on my bookshelf is Beyond Spreadsheets with R, by Dr. Jonathan Carroll. I’ve read through a lot of beginner’s guides to R and RStudio - If you come from a traditional financial modeling background, or you’re a daily power user of Microsoft Excel, I highly recommend this book. It teaches you everything from data manipulation to summarizing and grouping data, to looping with the R
In my opinion, Dr. Carroll lays out one of the easiest-to-follow and best introductions to vectorization and the benefits of the
purrr package. As stated by Dr. Carroll in Chapter 8 (link below), with
purrr, “you can think of just about everything as a series of functions to apply repeatedly to elements.” In corporate finance and financial modeling terms, the
purrr package is essentially your answer to super long, complicated, nested IF statements in Excel.