Skip to content

Commit

Permalink
Change confidence_intervals to confidence_percentiles
Browse files Browse the repository at this point in the history
  • Loading branch information
dekuenstle committed Sep 20, 2024
1 parent 33768eb commit 037eefa
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion psignifit/_configuration.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ class Configuration:
"""
beta_prior: int = 10
CI_method: str = 'project'
confidence_intervals: Tuple[float, float, float] = (.95, .9, .68)
confidence_percentiles: Tuple[float, float, float] = (.95, .9, .68)
estimate_type: str = 'MAP'
experiment_type: str = ExperimentType.YES_NO.value
experiment_choices: Optional[int] = None
Expand Down
2 changes: 1 addition & 1 deletion psignifit/psignifit.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ def psignifit(data: np.ndarray, conf: Optional[Configuration] = None,
grid_none_ix = tuple(ix for ix, (param, value) in enumerate(sorted(grid.items())) if value is None)
grid_params = [param for param, value in grid.items() if value is not None]
grid_values = [grid[param] for param in grid_params]
intervals = confidence_intervals(np.squeeze(posteriors, axis=grid_none_ix), grid_values, conf.confidence_intervals, conf.CI_method)
intervals = confidence_intervals(np.squeeze(posteriors, axis=grid_none_ix), grid_values, conf.confidence_percentiles, conf.CI_method)
intervals_dict = {param: intervals[ix].tolist() for ix, param in enumerate(grid_params)}
marginals = marginalize_posterior(grid, posteriors)

Expand Down

0 comments on commit 037eefa

Please sign in to comment.