Skip to content

Commit

Permalink
move initialization of stat_values list to inside 'if'
Browse files Browse the repository at this point in the history
  • Loading branch information
bikegeek committed Jan 6, 2025
1 parent acfdb8c commit fdd7a92
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion metcalcpy/agg_stat_bootstrap.py
Original file line number Diff line number Diff line change
Expand Up @@ -305,8 +305,8 @@ def _calc_stats(self, cases):
values = self.series_data[np.in1d(data_cases, flat_cases)].to_numpy()
safe_log(logger, "debug", f"Number of values selected for single case: {len(values)}")
# Calculate the statistic for each bootstrap iteration
stat_values = []
try:
stat_values = []
stat_value = globals()[func_name](values, self.column_names, logger=logger)
stat_values.append(stat_value)
safe_log(logger, "info", f"Statistic calculated for bootstrap iteration: {stat_value}")
Expand Down

0 comments on commit fdd7a92

Please sign in to comment.