Hello
I have a series of mortality data for 100 countries.
I have (clumsily) coded the following for the first country:
tssmooth ma Albania_5yrmortality_mean =yearly_mort_Albania, window(0 1 4)
gen ismiss = missing(yearly_mort_Albania)
replace Albania_5yrmean = . if ismiss > (4/5)
drop ismiss
is there a way to repeat this for all countries?
many thanks
Catherine
Related Posts with repeating a smoothing function in a time series
Problem with rename in a loopHello I am trying to rename some variables within a loop, but it returns me error. I have some varia…
ERM model for Endogenous treatment effect with nointeract optionI am trying estimate treatment effect models using ERM command in Stata 15. However, it has been sho…
Ali UbaidI am trying Heckman two-step analysis for remittances and agriculture investment based on survey dat…
optimize_init_technique(S, "nr")Hi, I have a methodological question about how optimize works with the Newton-Raphson algorithm. A…
generating change variables in panel-structureDear all, I would like check whether I can overwrite the missing deprivation variable (dep) with the…
Subscribe to:
Post Comments (Atom)
0 Response to repeating a smoothing function in a time series
Post a Comment