so have seen questions regarding error code before, suggested troubleshooting worked authors didn't me diagnose. i'm self-learning r , new stackoverflow, please give me constructive feedback on how better ask question, , best provide necessary information. i've seen many, similar questions put on hold want me. i'm sure error stems lack of experience in data prep.
i'm trying run panel data model, loaded .csv , error returns when model run
fixed = plm(y ~ x, data=pdata, model = "within") error in `colnames<-`(`*tmp*`, value = "1") : length of 'dimnames' [2] not equal array extent
running str() on dataset returns id , time factors 162 levels , 7 levels, respectively.
str(pdata) classes ‘plm.dim’ , 'data.frame': 1127 obs. of 11 variables: $ id : factor w/ 162 levels "1","2","3","4",..: 1 1 1 1 1 1 1 2 2 2 ... $ time : factor w/ 7 levels "1","2","3","4",..: 1 2 3 4 5 6 7 1 2 3 ... $ online.service.index : num 0.083 0.131 0.177 0.268 0.232 ... $ eparticipation : num 0.0345 0.0328 0.0159 0.0454 0.0571 ... $ cpi : num 2.5 2.6 2.5 1.5 1.4 0.8 1.2 2.5 2.5 2.4 ... $ ge.est : num -1.178 -0.883 -1.227 -1.478 -1.466 ... $ rl.est : num -1.67 -1.71 -1.72 -1.95 -1.9 ... $ ln.pop : num 16.9 17 17 17.1 17.1 ... $ ln.gdp.cap : num 5.32 5.42 5.55 5.95 6.35 ... $ human.capital.index : num 0.268 0.268 0.268 0.329 0.364 ... $ telecommunication.infrastructure.index: num 0.0016 0.00173 0.00202 0.01576 0.03278 ...
still, don't see how create error. i've tried transforming data frame or matrix, same result (i got desperate , worked people)
dim() yields [1] 1127 11
i have na values, understand these shouldn't cause problem. again, i'm self-taught , new here, please take easy on me! hope explained problem well.
Comments
Post a Comment