Description Usage Arguments Value Note Examples
Standard deviation independent of mean
1 2 3 | cmp_sdim_coefs(bp_mean, bp_sd)
cmp_sdim_values(bp_mean, bp_sd)
|
bp_mean |
a numeric vector of mean blood pressure values. |
bp_sd |
a numeric vector of standard deviations corresponding to the mean blood pressure values. |
cmp_sdim_coefs returns the regression coefficients from
a linear model fitted to the log-transformed values of bp_mean
and bp_sd
(i.e., coef(lm(log_sd ~ log_mean))
). cmp_sdim_values
uses the regression coefficients form cmp_sdim_coefs to compute
the standard deviation of blood pressure independent from the mean.
SDIM (standard deviation independent of the mean) is cohort-specific. So, if you remove a participant from the study, it will result in a new value of SDIM for everyone else.
1 2 3 4 | mean_bps = runif(n = 100, min = 80, max = 190)
sd_bps = runif(n = 100, min = 1, max = 3)
cmp_sdim_coefs(mean_bps, sd_bps)
cmp_sdim_values(mean_bps, sd_bps)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.