The program below does the trick. It returns as a default the variable list without the indicator that the variable needs to be omitted. It cannot handle other baseline categories than "0".
As I said, a stable Stata solution would be nice too.
Code:
program define fvexpand2 , rclass syntax [anything] , [VARLISTOmitted] fvexpand `anything' if "`varlistomitted'" == "" { if "`r(varlist)'" != "" return local varlisto "`r(varlist)'" local tmp = subinstr("`r(varlist)'","0b.","0.",.) if "`tmp'" != "" return local varlist "`tmp'" } else { if "`r(varlist)'" != "" return local varlist "`r(varlist)'" } if "`r(fvops)'" != "" return local fvops "`r(fvops)'" if "`r(tsops)'" != "" return local tsops "`r(tsops)'" end
Comment