From 85baf453e0ba47c715601532bd05986153b2982a Mon Sep 17 00:00:00 2001 From: ismael2395 Date: Fri, 1 Nov 2024 13:27:06 -0700 Subject: [PATCH] add kde option --- bpd/diagnostics.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bpd/diagnostics.py b/bpd/diagnostics.py index 41e09b1..ef5b418 100644 --- a/bpd/diagnostics.py +++ b/bpd/diagnostics.py @@ -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)