play

2 min read Original article ↗

QuestDB is a high-performance time series database that supports SQL queries and and can ingest data at millions of rows per second.

We put together this notebook to demonstrate a typical use of QuestDB with Python tooling such as Pandas, Jupyter and Matplotlib. We've included a large dataset of grid energy usage and forecasts at 15-minute intervals.

If you'd like to run this notebook interactively, pick one of the two commands below and paste in your terminal:

  • Python:
    • python3 -c "import urllib.request as w;exec(w.urlopen('https://dl.questdb.io/play/run.py').read())"
    • The script runs a virtual environment in a temporary directory, cleaned up on exit.
  • Docker:
    • docker run -p 8888:8888 -p 8812:8812 -p 9009:9009 -p 9000:9000 questdb/play:1.0.0.

These commands will allow you to run this notebook interactively without leaving any software or installed on your system.

Exploring the dataset

The Open Power System Data (OPSD) hosts aggregated data about the energy landscape in some European countries. One of the datasets they curate contains energy data in 15 minutes intervals for Austria, Belgium, Germany, Hungary, Luxembourg, and Netherlands. The original can be found at https://data.open-power-system-data.org/time_series/. We are providing a derivative dataset containing only two years of data (413383 rows) and four columns:

  • Timestamp of the measure, in UTC timezone
  • Actual total load in MW
  • Forecasted energy for the same period, one day ahead, in MW
  • Country code