Technical requirements
You can download the datasets and code from the GitHub repository as follows:
- Data: https://github.com/PacktPublishing/Polars-Cookbook/tree/main/data
- Code: https://github.com/PacktPublishing/Polars-Cookbook/tree/main/Chapter09
It is assumed that you have installed the Polars library in your Python environment:
>>> pip install polars
And that you have imported it into your code:
import polars as pl
We’ll also be using the Polars built-in visualization feature in this chapter. Make sure to import the hvplot
library in the command line:
>>> pip install hvplot
We’ll be using the historical hourly weather dataset throughout this chapter. The dataset contains weather data in Toronto such as temperature and humidity. You can find it at this URL in our GitHub repo: https://github.com/PacktPublishing/Polars-Cookbook/blob/main/data/toronto_weather.csv.
We’ll use a LazyFrame instead of a DataFrame...