In the previous segment, we ran some basic queries on SQL to understand and explore our data sets. Now, from this segment onwards, we will be using Python as we will be running a lot more complex queries, which can be simplified considerably if we use Python directly.
Our first step before running any type of analysis is to join all the tables into a single table so that we have all our data in a single table.
In the forthcoming video, you will learn how to combine tables in Python with the help of the Pandas library. Let us go ahead and watch the video.
So, in the video, you learned how to use the rename and concat functions in the Pandas library to combine two tables. So, now that you know how to combine multiple tables, in the next video, Favio will apply these functions to all the tables in order to generate a single table with all the data. Let us go ahead and watch the video.
So, in the video, Favio joined all the tables using the concat function and removed duplicate columns using the duplicated function.
You can also convert this churn_all dataframe into a csv file by using the following code shown below.
churn_all.to_csv('churn_all.csv')
So, now that we have our main table ready, in the next segment, Favio will start with the analysis of the lifetime value (LTV).