Skip to content

Commit

Permalink
add kde option
Browse files Browse the repository at this point in the history
  • Loading branch information
ismael-mendoza committed Nov 1, 2024
1 parent a0a1d8b commit 85baf45
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion bpd/diagnostics.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,12 @@ def get_contour_plot(
names: list[str],
truth: dict[str, float],
figsize: tuple[float, float] = (7, 7),
kde: bool | int | float = False,
) -> Figure:
c = ChainConsumer()
for name, samples in zip(names, samples_list):
df = pd.DataFrame.from_dict(samples)
c.add_chain(Chain(samples=df, name=name))
c.add_chain(Chain(samples=df, name=name, kde=kde))
c.add_truth(Truth(location=truth))
return c.plotter.plot(figsize=figsize)

Expand Down

0 comments on commit 85baf45

Please sign in to comment.