Skip to content

Have a look at what's happening at Kanaries Open Source Community !

PYGWALKER
Changelog
PyGWalker 0.2. Update

Pygwalker 0.2 Update

In this document, we will walk you through the latest Pygwalker (version 0.2) update. This version introduces three key features:

  • Restore Configs: Maintains your configuration settings across sessions.
  • Display Charts: Allows visualization of Pygwalker-generated charts.
  • Preview Charts: Provides a chart preview when the kernel isn't running.

Install PyGWalker 0.2 Pre-release Version

To install the pre-release version of Pygwalker, use pip:

pip install pygwalker --pre

PyGWalker 0.2 Feature Walkthrough

Restore PyGWalker Congifuration

You can view a live example of this feature in action here (opens in a new tab).

To restore your Pygwalker configurations, execute your Pygwalker code as follows:

import pygwalker as pyg
 
pyg.walk(df, spec="config.json")

After interacting with the UI and setting up your chart, click the save icon. The configuration data for the current chart will be saved to the "config.json" file.

Upon re-running this code, Pygwalker will restore the last saved state, allowing you to pick up where you left off.

PyGWalker Config Store

Display Chart in PyGWalker

An operational demo of this feature can be found here (opens in a new tab).

You can generate and display your Pygwalker charts as follows:

import pygwalker as pyg
 
walker = pyg.walk(df, spec="first_explore.json")

After creating your charts on the UI, click the save icon to store them.

Display Chart in PyGWalker

Use the display function to visualize the saved charts in other cells.

walker.display_chart("chart name", title="title", desc="description")

Display Chart in PyGWalker

Preview Chart in PyGWalker 0.2

This feature's functionality is demonstrated here (opens in a new tab).

To generate a preview of your Pygwalker chart, use the following code:

import pygwalker as pyg
 
pyg.walk(df, spec="preview.json", use_preview=True)

Create your chart and save it.

Preview Chart in PyGWalker 0.2

During the saving process, a preview chart, based on the current chart, will be generated. This preview will be displayed when the kernel is not started, allowing for a quick overview without the need for the kernel to be running.

Preview Chart in PyGWalker 0.2