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

Extra simulations for Parameter Sensitivity Analysis (PSA) plots #3

Open
stevechoy opened this issue Oct 15, 2024 · 2 comments
Open
Labels
bug Something isn't working

Comments

@stevechoy
Copy link
Contributor

Whenever a new parameter is selected from the drop-down list, the PSA simulations are conducted twice (the plot refreshes twice).
The final plot shows the correct parameter values, while the intermediate plot shows the previous parameter's values (e.g. if previous parameter was CL and its associated values was 1, 2, 3, and the new parameter is V, the intermediate plot first shows 1, 2, 3, before updating to the final values of 10, 20, 30).

@stevechoy stevechoy added the bug Something isn't working label Oct 15, 2024
@stevechoy stevechoy changed the title Duplicate simulations are Parameter Sensitivity Analysis (PSA) plots Extra simulations for Parameter Sensitivity Analysis (PSA) plots Oct 15, 2024
@stevechoy
Copy link
Contributor Author

This behavior is now corrected by introducing a reactive dependency for new_sim_min_model_1, new_sim_mid_model_1, new_sim_max_model_1 to input$param_min_id_model_1, input$param_mid_id_model_1, and input$param_max_id_model_1, respectively, i.e. adding %>% bindEvent(input$param_min_id_model_1) at the end of the reactive. (ditto for model 2)

This is fixed for next release (v0.2.9).

@stevechoy stevechoy reopened this Oct 17, 2024
@stevechoy
Copy link
Contributor Author

Turns out it is not enough to just introduce a single reactive dependency as other arguments such as sampling_options() would not be updated when changed. A deeper look into the reactive dependency is required to fix this.

@stevechoy stevechoy reopened this Oct 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant