Skip to content

Commit

Permalink
Bugfix for percentage capture (#207)
Browse files Browse the repository at this point in the history
## Description

Casting `n_throw_out` to `int` to be used as index in `datavar_check =
datavar[n_throw_out:-n_throw_out]`.
  • Loading branch information
asewnath authored Aug 12, 2024
1 parent 008d04a commit cab65a4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/eva/plotting/batch/base/plot_tools/dynamic_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ def vminvmaxcmap(logger, option_dict, plots_dict, data_collections):
n_throw_out = ((100-percentage_capture) * n / 100) / 2

# The value needs to be an integer
n_throw_out = np.floor(n_throw_out)
n_throw_out = np.floor(n_throw_out).astype(int)

# Create new array with only the data to consider
if n_throw_out == 0:
Expand Down

0 comments on commit cab65a4

Please sign in to comment.