Share a ydata-profiling report
ProfileReport(df).to_file("profile.html") produces the single most useful
artifact in exploratory data analysis and the single most annoying one to
send. It is one file, which is good, and it is often 15–40 MB, which is why
it dies in an email filter, gets zipped, gets renamed profile_final_v2.html,
and ends up on one laptop.
Worse, the interesting part of a profile is never the profile. It is the
argument about it: whether a 31% null rate in customer_tier is a bug or a
business rule, whether that bimodal distribution is two products stapled
together. That conversation needs to happen on the numbers, not next to them.
Publish it
from ydata_profiling import ProfileReport
import requests, os
ProfileReport(df, title="Orders — profile", minimal=True).to_file("profile.html")
requests.post(
"https://commareports.com/api/v1/reports",
headers={"Authorization": f"Bearer {os.environ['COMMA_API_TOKEN']}"},
json={"title": "Orders — profile", "html": open("profile.html").read()},
).raise_for_status()
minimal=True is doing real work here. The default config computes pairwise
interactions and every correlation matrix, which is most of the file size and
most of the runtime — and for a first-pass review, nobody reads them. Turn it
off, get a file that fits comfortably under the 5 MB HTML cap, and turn it
back on for the one column pair that turns out to matter.