Join Chris DallaVilla for an in-depth discussion in this video Exercise files, part of The Data Science of Marketing.
- [Instructor] You can download the exercise files and save them to your desktop, which is what I've done right here. And so, for example, if I open up the exercise files, you can see that each chapter, and each video, has a corresponding number. So, for example, exploratory analysis, is right here in 02_02. And you can see we have both an R file, and a data file as well. In the chapter just below that, this is a python file, and then some data for it down below, so we're going to walk through each of these, real quickly, just so that we know how to access the exercise files with our different platforms.
So the first is R, so I'm going to open up our studio. I'm going to select Not Now, in case you're getting this prompt as well. And, what I can see is I have the ability to input a command right here. And to access that data, and I'll go into more detail about some of the commands that we're typing in right now, in a future video. But for now, just to make sure you can access the different files I'm going to type myData, okay, and then I'm going to assign that to read.csv and then I'm going to input the path to those files.
So on Mac OSX, the path typically begins with a ~ if you're on Windows that path typically begins with a C:\. It's very important to assess what your particular path is at this stage in the course, because we're going to need to access these paths quite frequently. So, again, in this case, I'll do a ~/Desktop/Exercise_Files. Now, that, in essence, if we take a look back, let me open those exercise files up once more, we can see 02_02 has a CSV file inside of it called exploratory-r.csv.
I'm going to come back over to that command we were just writing out, and I'm now just going to paste that in. But, I need something else don't I? I need the full path into that directory. So, again, I'm going to come over and copy out 02_02, and then put that right there, and now if I hit Enter, that will connect to our data. So if I double-click here, we can quickly see that we're beginning to access some of our data, so that's how we do that in R, and again, I'll go into some further detail in a future chapter about some of the commands that we just typed.
So, I'm going to go ahead and close out of R, and I don't want to save this, because we're just getting our bearings here. So, next we're going to go into Python. I typically use Terminal to access python, again, you have two different ways you can open up the environment. What I'm going to do right now is I'm going to open up a Terminal window, and I'm going to write jupyter notebook. Okay, and this is going to open up that environment that we looked at in the previous video.
I'm going to navigate into Desktop, into Exercise_Files, and now into 02_03 and this'll give you a clear sense on how to access this data here. So now I could just simply click on this exploratory.ipynb, and, ultimately, that stands for ipython notebook. But you can see once I click on that file, you may get this message too, then again you may not. If you do, I'm just going to select Python [conda root], and click OK.
So that's how we will access our exercise files for Python. And at this stage of the game, I'm just going to go ahead and close this down. Again, we'll go into greater detail about this later, but for now, you can select this and click on Shut Down. That will stop the file from actively running. I'm also just going to go ahead and close out of that window, and come back into my Terminal, because, ultimately, what this shows us is that we have Python and Anaconda running in the background. So if I select, on the Mac, Ctrl + C, and then select yes, that will shut down the anaconda, and the jupyter platform.
And, then, finally, we're going to take a quick look at how we're going to access our exercise files using Tableau. In order to access Tableau, one of the things that I can do is open up my Finder, and go to my Applications, locate Tableau there, and I'm just going to go ahead and drag this icon into our Dock, right next to R. That'll give us a simple way just to crack open that application each time we need to, and I'm going to go ahead, and click on that to open up the application, and I'm going to continue trial.
And Tableau gives us a number of different ways to connect to our data. Much of what we'll be using in this course are CSV files which it considers a text file. So I'll click on Text file, then identify that particular text file in our exercise files, and there you have it. So that's how we'll access our data files for Tableau. So I'm going to go ahead and close out of Tableau. I don't want to save that, and now you have a quick sense as to how you'll access your exercise files, and again, it's very important at this stage of the game to ensure that you know your path to access some of these files.
As you saw with both Python and R, we need to be able to access our path quite frequently, so, if you don't have a sense as to how to access that path right now, hit the pause button for a few minutes while you figure that out, and maybe make a note to yourself on what that path to your exercise files will be. I think that'll help you as we go through the course. One last thing to point out, with our exercise files, is there's also a final directory. This will include the final files that you can use as reference as you go through the course.
In this course, discover how to gain valuable insights from large data sets using specific languages and tools. Follow Chris DallaVilla as he walks through how to use R, Python, and Tableau to perform data modeling and assess performance. As Chris dives into these concepts, he shares specific case studies that come directly from his own work with clients. Plus, he shares three essential—and practical—best practices for data-driven marketing that you can use to bolster your organization's marketing performance.
- Installing R, Python, and Tableau
- Navigating the UI for R, Python, and Tableau
- Using R, Python, and Tableau
- Exploratory analysis
- Performing regression analysis
- Performing a cluster analysis
- Performing a conjoint assessment
- Stakeholder alignment