This section covers some tools to share and download your data.
6.8.1. Datapane: Publish your Python Objects on the Web in 2 Lines of Code¶
!pip install datapane plotly
If you want to put together your pandas.DataFrame, interactive charts such as Plotly, Bokeh, Altair, or markdown into a nice report and publish it on the web, try Datapane. The code below shows how you can publish your Python objects using Datapane in a few lines of code.
importdatapaneasdpimportpandasaspdimportnumpyasnpimportplotly.expressaspx# Scripts to create df and chartdf=px.data.gapminder()chart=px.scatter(df.query("year==2007"),x="gdpPercap",y="lifeExp",size="pop",color="continent",hover_name="country",log_x=True,size_max=60,)# Once you have the df and the chart, simply user=dp.Report(dp.Text("my simple report"),# add descriptiondp.DataTable(df),# create a tabledp.Plot(chart),# create a chart)# Publish your reportr.upload(name="example")
Uploading report and associated data - please wait...
Report successfully uploaded, click here to view and share your report