Detailed description |
the first line creates an aidsEst object without deltas (and adjusted vcov)
the second line should calculate the elasticities.
but for some goods the standard errors are missing.
inspecting the marshallVcov reveals that the variance (diagonal) is negative for some.
this may be due to some error in my adjusting the vcov in aidsSetShifters ... but aidsElas could (and maybe should) check that its not returning a covariance matrix with negative variances...
conditional_aidsmodel=aidsSetShifters(aidsmodel_shift, shiftervalues,hide=TRUE)
aidselas_shift2009=aidsElas(coef(conditional_aidsmodel),prices=conditional_aidsmodel$pMeans,totExp=conditional_aidsmodel$xtMean,
coefCov=conditional_aidsmodel$coef$allcov,df=df.residual(conditional_aidsmodel))
table(diag(aidselas_shift2009$marshallVcov)<0)
|
|