Tables and visuals
Display tabular data and visual outputs directly from your Python calculations using list-based tables and matplotlib figures.
Creating Tables
my_table = [
[1, "apple"],
["cat", 3.14]
]Generating Visuals
import matplotlib.pyplot as plt
import numpy as np
# Data for plotting
t = np.arange(0.0, 2.0, 0.01)
s = 1 + np.sin(2 * np.pi * t)
fig, ax = plt.subplots()
ax.plot(t, s)
ax.set(xlabel='time (s)', ylabel='voltage (mV)',
title='Sine Wave Example')
ax.grid()
Notes
Last updated