Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Startpoint sampling for a subset of parameters #230

Merged
merged 3 commits into from
Nov 6, 2023
Merged

Conversation

dweindl
Copy link
Member

@dweindl dweindl commented Nov 1, 2023

Allow passing a list of parameter IDs to startpoint sampling for subsetting/reordering parameters.

@codecov-commenter
Copy link

codecov-commenter commented Nov 1, 2023

Codecov Report

Merging #230 (830d428) into develop (e678dd7) will increase coverage by 0.04%.
The diff coverage is 100.00%.

@@             Coverage Diff             @@
##           develop     #230      +/-   ##
===========================================
+ Coverage    76.24%   76.28%   +0.04%     
===========================================
  Files           34       34              
  Lines         3182     3188       +6     
  Branches       773      774       +1     
===========================================
+ Hits          2426     2432       +6     
  Misses         555      555              
  Partials       201      201              
Files Coverage Δ
petab/parameters.py 85.02% <100.00%> (+0.49%) ⬆️
petab/problem.py 64.89% <100.00%> (ø)
petab/sampling.py 85.00% <100.00%> (ø)

Allow passing a list of parameter IDs to startpoint sampling for subsetting/reordering parameters.
@dweindl dweindl marked this pull request as ready for review November 1, 2023 12:46
@dweindl dweindl requested a review from a team as a code owner November 1, 2023 12:46
# get types and parameters of priors from dataframe
par_to_estimate = parameter_df.loc[parameter_df[ESTIMATE] == 1]

if parameter_ids:
par_to_estimate = par_to_estimate.loc[parameter_ids, :]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe add an error message for the case when provided parameter_ids list contains an id that is not there.

@dweindl dweindl merged commit c0158ba into develop Nov 6, 2023
6 checks passed
@dweindl dweindl deleted the startpoints_by_id branch November 6, 2023 08:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants