Skip to content

Home

This python package adds a custom Pandas accessor to generate polar wind rose plots from a Pandas dataframe.

I don't mean to compete with the wonderful windrose package already available, but that package has a little too much complexity for what I wanted. This package is meant to provide a minimal, simple interface to making wind rose plots. This is done by using Pandas methods pd.cut and df.groupby and using Matplotlib regular polar axes.

Install

Install with pip. The requirements are only pandas, numpy, and matplotlib.

pip install pandas-rose

Usage

Tutorial

TLDR: Pandas-rose is simple.

import pandas as pd
import rose

# df is a pandas dataframe with columns
# "wind_speed" and "wind_direction"
df = pd.DataFrame({
    "wind_speed":[1,2,3,4],
    "wind_direction":[20, 10, 190,300]
})

# Display a polar wind plot of the data
df.rose.plot()

# Show a table of the binned data
df.rose.plot()