opendvp.plotting.dynamic_histogram#
- opendvp.plotting.dynamic_histogram(df, column, bins=100)#
Plot a dynamic histogram with a threshold slider and count annotations.
This function creates an interactive histogram using Plotly, allowing the user to adjust a threshold slider. Counts of values to the left and right of the threshold are displayed as annotations. The threshold can be interactively moved, and the counts update accordingly.
- Return type:
Parameters#
- dfpd.DataFrame
The input DataFrame containing the data to plot.
- columnstr
The name of the column in
df
to plot as a histogram.- binsint, optional
Number of bins for the histogram (default is 100).
Returns:#
- None
Displays the interactive histogram in the default browser or notebook output.
Raises:#
- ValueError
If the specified column is not in the DataFrame or contains no valid data.