[R] error using pvcm() on unbalanced panel data

Liviu Andronic landronimirc at gmail.com
Thu Feb 25 16:37:01 CET 2010


On 2/25/10, Liviu Andronic <landronimirc at gmail.com> wrote:
>  I can reproduce the error on a modified example from the vignette:
>  > require(plm)
>  > data("Hedonic")
>  > Hed <- pvcm(mv ~ crim + zn + indus + chas + nox + rm + age + dis +rad + tax + ptratio + blacks + lstat, Hedonic, model = "within",index = "townid")
>  Error in FUN(X[[1L]], ...) : insufficient number of observations
>  > ##it fails for both FE and RE cases
>  > Hed <- pvcm(mv ~ crim + zn + indus + chas + nox + rm + age + dis +rad + tax + ptratio + blacks + lstat, Hedonic, model = "random",index = "townid")
>  Error in FUN(X[[1L]], ...) : insufficient number of observations
>

A quick update, the function pooltest() used via its formula interface
fails in a similar way:
> pooltest(mv ~ crim + zn + indus + chas + nox + rm + age + dis +rad + tax + ptratio + blacks + lstat, Hedonic, model = "within",index = "townid")
Error in FUN(X[[1L]], ...) : insufficient number of observations
> pooltest(mv ~ crim + zn + indus + chas + nox + rm + age + dis +rad + tax + ptratio + blacks + lstat, Hedonic, model = "pooling",index = "townid")
Error in FUN(X[[1L]], ...) : insufficient number of observations

Liviu



More information about the R-help mailing list