Hello
Does anyone have simple code to create a cost-effectiveness acceptability curve?
I have a dataset that has 2 columns - one columne (inc_dep_cci) with 1000 bootstrapped estimates of incremental effect and the other column (inc_cost_cci) with 1000 bootstrapped estimates of incremental costs between two care environments.
When I use the below code, the estimates of probability cost-effective keeps coming up 0.
capture postutil clear
postfile ceac n probce using "ceac.dta", replace // Set-up 'postfile' to store results
use "P:\Omar Projects\Paloma\OSCAR Aim 3\Aim 3 Data Files\bootstrap_mnar.dta", clear
gen n = _n in 1/1000
count if ~missing(inc_dep_cci)
local denom = r(N)
forvalues n=1/1000 {
count if (inc_dep_cci*`n' - inc_cost_cci) > 0
post ceac (`n') ( r(N)/`denom' ) // Proportion of cost-effective BS replicates
}
postclose ceac
Any help is greatly appreciated.
Thank you,
Marta
Related Posts with Code for Cost-Effectiveness Acceptability Curve
stata graph and equationsif i have xt = 1.004 * xt-1 + ut and yt = 1.04 * yt-1 + vt where ut and vt are normally distributed…
Median per group for every year (panel data)Hello! For my thesis I want to test a specific hypothesis that requires me to generate a variable U…
Using Binary Explanatory Variables in Panel Dataset Regression AnalysisHello, I am using Stata 15.1 on Windows 10. I have an Unbalanced Panel Data set on crime rate (con…
How to change the 'levelsof' a panel variable?Hello All, I am trying to create a synthetic control group using Stata's 'synth' package but when I…
How can I count the number of elements in a numlist?Is there a command or function that counts the number of elements in a numlist? …
Subscribe to:
Post Comments (Atom)
0 Response to Code for Cost-Effectiveness Acceptability Curve
Post a Comment