Learn how to load data into Pandas DataFrame from a database and how to join two DataFrames together. You can add weather data from an SQLite database and try to see if the temperature affects the number of rides.
- [Instructor] Sometimes our data is not found in one place.…Let's add some weather data to our taxi rides…to see how temperature affected the number of rides.…Our weather data is in weather.db,…which is an SQLite database.…SQLite is an embedded SQL database and is widely used.…If you use a browser or have an Android phone,…you already use SQLite.…Python has a standard API for accessing…relational or SQL databases.…Pandas uses this and offers a way to read data…from any database via to give it…a standard connections object.…
Let's see how it works.…So we'll import SQLite3 and connect to weather.db.…Now we're connected to the database.…To know what's inside the database…requires some SQL skills and is database specific.…Most times, you can find the SQL for the database schema…somewhere in the code base.…Apart from that, there are tools per database…that will show you the schema.…Other types found in the weather table.…Let's load it.…
Wdf = pd.read_sql and we'll give it an sql statement.…Select everything from weather…
- Working with Jupyter notebooks
- Using code cells
- Extensions to the Python language
- Markdown cells
- Editing notebooks
- NumPy basics
- Broadcasting, array operations, and ufuncs
- Folium and Geo
- Machine learning with scikit-learn
- Plotting with matplotlib and bokeh
- Branching into Numba, Cython, deep learning, and NLP
Skill Level Intermediate
1. Scientific Python Overview
2. The Jupyter Notebook
3. NumPy Basics
Manage environments5m 11s
6. Folium and Geo
7. NY Taxi Data
10. Other Packages
11. Development Process
Next steps1m 33s
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.