Interactive windrose diagrams using pandas and plotly
Project description
Interactive windroses using pandas and plotly
Rosely leverages the polar bar char of Plotly and pandas to simplyfy the creation of beautiful and interactive windrose diagrams. This package was inspired by the Plotly polar bar chart with hoverable tooltips, zoom, pan, and other interactive features.``Rosely``’s main purpose is to make use of the Plotly polar bar chart more accessable and efficient for custom workflows using pandas and a simple object-oriented implementation.
Documentation
Coming soon.
Installation
Rosely’s dependencies are Python 3.4+, NumPy, pandas, and Plotly.
You may install the dependencies using the conda virtual environment (recommended), the environment file can be downloaded here and installed and activated by
conda env create -f environment.yml
conda activate rosely
Once activated install with PIP:
pip install rosely
Quick start
Given arbitrary time series data that contains wind speed and direction (degrees) Rosely can quickly produce wind statistics and interactive windrose diagrams once the data is loaded into a pandas.DataFrame.
This example uses the provided example CSV containing meterological data.
>>> import pandas as pd >>> from rosely import WindRose >>> df = pd.read_csv('path/to/example_data.csv') >>> # make a WindRose object from the dataframe with "ws" and "wd" columns >>> WR = WindRose(df) >>> WR.plot( >>> template='seaborn', colors='Plotly3', >>> title='Twitchell Island, California' >>> )
The resulting windrose diagram saved as a png (download this file for an interactive example):
Details and examples of plot customization, output options, and windrose calculation options can be found in the online documentation.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for Rosely-0.0.1-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 66678b5f1ab1029ad8643dba9bb62f43c542a8fe78e7716d59ab4002480dad8b |
|
MD5 | 94be9cf2b9762645b1b78a722af3b974 |
|
BLAKE2b-256 | 14e8be46cafe6c14745ea917161e79e7d1efd264509bd5ff48cec06e418eb384 |