statapush
statapush copied to clipboard
bug report for syntax including "ci" command
The below syntax works well in Stata, however, if I use statapush to monitor it, it will report error
example.do
sysuse auto,clear
set seed 10000
capture program drop ModMed
program define ModMed, rclass
summarize gear_ratio
return scalar m=r(mean)
return scalar sd=r(sd)
reg price mpg c.length##c.gear_ratio
return scalar IV = rnormal(_b[c.length],_se[c.length])
return scalar Mod = rnormal(_b[c.length#c.gear_ratio],_se[c.length#c.gear_ratio])
reg weight price mpg c.length
return scalar Med = rnormal(_b[price],_se[price])
end
simulate indL=(((r(IV)+r(Mod)*(r(m)-r(sd))))*(r(Med))) indM=(((r(IV)+r(Mod)*(r(m))))*(r(Med))) indH=(((r(IV)+r(Mod)*(r(m)+r(sd))))*(r(Med))), reps(50) seed(1234): ModMed
ci means indL indM indH
statapush using "example.do", message(Congratulations! ) token(...) provider(ifttt)
The error is :
. ci means indL indM indH
variable means not found
r(111);