Towards AI Can Help your Team Adopt AI: Corporate Training, Consulting, and Talent Solutions.


A Guide To Modular Prompting GPT-4 For Interactive Python Dashboards
Data Science   Latest   Machine Learning

A Guide To Modular Prompting GPT-4 For Interactive Python Dashboards

Last Updated on January 3, 2024 by Editorial Team

Author(s): John Loewen, PhD

Originally published on Towards AI.

Creating interactive Python Plotly dashboards one chart at a time
Dall-E image: Impressionist dripping oil colour painting of a visual dashboard

As a computer science professor, over the last 8 months I have tirelessly tasked GPT-4 to generate Python Plotly dashboard code.

I have found recently that GPT-4 has improved immensely in its ability to create Python Plotly code for displaying interactive data visuals.

Your edge as a data scientist may be your ability to whip up quick and clean interactive charts — to offer a set of views into a dataset — over time.

Need proof? Yes!

So, let’s create a set of 4 diverse visualizations for our interactive dashboard: stacked area, line, pie, and box plot charts.

And I will leave you with 3 awesome rules to ensure you can re-create an interactive dashboard with any data set.

When? Right now!

Let’s start with an interesting data set. Let’s use a data set on population projections — from a new report — the new UN population projections report (found HERE).

To start off with, we can upload the UN Population Projections dataset to GPT-4 and ask it to give us an overview of what it finds:

By doing this, we can see if GPT-4’s interpretation of the data set is aligned with our interpretation of the dataset.

An additional… Read the full blog for free on Medium.

Join thousands of data leaders on the AI newsletter. Join over 80,000 subscribers and keep up to date with the latest developments in AI. From research to projects and ideas. If you are building an AI startup, an AI-related product, or a service, we invite you to consider becoming a sponsor.

Published via Towards AI

Feedback ↓