In my new pandas video, you're going to learn how to use the "merge" function so that you can combine multiple datasets into a single DataFrame.
Merging (also known as "joining") can be tricky to do correctly, which is why I'll walk you through the process in great detail. By the end of the video, you'll be fully prepared to merge your own DataFrames!
"This, by far, is the best explanation of these concepts." - M. Schuer
Click on a timestamp below to jump to a particular section:
1:21 Selecting a function (merge/join/concat/append)
3:36 Details of the merge process
12:07 Handling common merge issues
17:01 Comparing the four types of joins (inner/outer/left/right)
If you want to follow along with the code, you can download the Jupyter notebook and the datasets from GitHub.
Related Resources
- pandas documentation for merge and concat
- My video series: Easier data analysis in Python with pandas
- My videos on the pandas index: Part 1 and Part 2 (includes concat)
- My pandas tricks for merging: Using the indicator and validate parameters
- My pandas course on DataCamp: Analyzing Police Activity with pandas
If you have any questions, please let me know in the comments below!
from Planet Python
via read more
No comments:
Post a Comment