This is just as simple as multiplying the CI of EC50 by 19.
The method described above is general one and applicable to more complex cases, e.g. to calculate the credible interval of the concentration that is needed to achieve certain response value (instead of the XX% of Emax). In such case the equation 0.95 = EC95^gamma / (ec50^gamma + EC95^gamma) needs to be replaced
Not sure where is the best place, maybe vignette? Wrap together with instruction on how to extract stanfit objects?
First extract MCMC samples
https://yoshidk6.github.io/rstanemax/articles/emaxmodel.html#set-covariates-1
Calculate EC95 from MCMC samples
From this (https://yoshidk6.github.io/rstanemax/reference/stan_emax.html),![unnamed](https://user-images.githubusercontent.com/2650321/121969279-cd332880-cd28-11eb-8a2b-7b894e24dc56.png)
, one can solve for
0.95 = EC95^gamma / (ec50^gamma + EC95^gamma)
which would beEC95 = EC50 * (19)^(1/gamma)
Calculate credible intervals
Now that you have posterior samples of
EC95
(by default 4000 of them), one can calculate percentiles to obtain credible intervalsCode example
Created on 2021-06-14 by the reprex package (v0.3.0)
Note
This is just as simple as multiplying the CI of EC50 by 19.
The method described above is general one and applicable to more complex cases, e.g. to calculate the credible interval of the concentration that is needed to achieve certain response value (instead of the XX% of Emax). In such case the equation
0.95 = EC95^gamma / (ec50^gamma + EC95^gamma)
needs to be replaced