PyDyGraphs
An interactive charting library using Dygraphs for the Jupyter Notebook
Install / Use
/learn @dinkelk/PyDyGraphsREADME
PyDyGraphs
An interactive charting library using Dygraphs for the Jupyter Notebook.
Intent
The Jupyter Notebook is an excellent tool for interacting with python and displaying data in real time. While tools like matplotlib can generate static plots in the Jupyter Notebook, interactive javascript plots are often more useful for exploring the data. This module can be readily included in an Jupyter Notebook and then used to generate beautiful time series plots with Dygraphs.
Screenshots
Simple Example

Subplot with Range Selector
Pandas Dataframe Plot

How It Works
This python module generates javascript that interacts with the Dygraphs library, and passes it to the Jupyter Notebook kernel for execution.
Currently the PyDyGraphs module depends on Pandas to generate a JSON representation of the data for plotting. This required dependancy may be removed with future work. Pandas can be installed via pip.
Example
Run the included example:examples/PyDyGraphTester.ipynb, or paste this code into an Jupyter Notebook to generate an interactive timeseries plot:
# Import pydygraphs and numpy
import dygraphs.graph as dy
import numpy as np
# Create a figure
fig = dy.figure(width = 600, height = 400)
# Generate data for the plot
x = np.array(range(100))
y = [np.sin(np.random.rand(100)),-np.sin(np.random.rand(100))]
# Plot the data on the figure
fig.plot(x,y, color=['navy','magenta'])
fig.title("Figure 1")
fig.xlabel('Series')
fig.ylabel('Value')
# Show the figure in this cell of the notebook
fig.show()
Installation:
Simply clone this repository and include the dygraphs.graph module in your Jupyter Notebooks. Note: PyDyGraphs only supports Python 3.
Want to contribute:
Please submit a pull request or issue with any questions you might have!
Related Skills
node-connect
351.8kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
frontend-design
110.9kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
openai-whisper-api
351.8kTranscribe audio via OpenAI Audio Transcriptions API (Whisper).
qqbot-media
351.8kQQBot 富媒体收发能力。使用 <qqmedia> 标签,系统根据文件扩展名自动识别类型(图片/语音/视频/文件)。
