Plot
By creating an index.html
file in the correct directory, an interactive plot can be created. The easiest way to create an interactive plot would be to utilize plotly. However, it is not necessary to use any library. Handcrafting an HTML file is also possible so long that an HTML file is created in the following directory:
/data/{TRANSFORM_ID}/artifacts/index.html
pyplot
Following is an example using pyplot
import plotly.graph_objects as go
import plotly.offline as pyo
import os
def transform(df):
fig = go.Figure()
pyo.plot(fig, filename=f"/data/{os.environ['TRANSFORM_ID']}/artifacts/index.html")

Last updated