如下图所示建立回归模型,分别建立控制年份——进口国——产品的固定效应 是混合截面数据
命定输入如下: reg lnx lnp i.year i.jkg i.spdm (分别是年份 进口国 产品的虚拟变量)
保留残差 predict e,resid
想问下这样命令是否正确? 控制了三个固定效应怎么做?
加入了产品的虚拟变量之后出现了如下的错误信息。
matsize too small
You have attempted to create a matrix with too many rows or columns or
attempted to fit a model with too many variables. You need to increase
matsize; it is currently 400. Use set matsize; see help matsize.
If you are using factor variables and included an interaction that has
lots of missing cells, either increase matsize or set emptycells drop to
reduce the required matrix size; see help set emptycells.
If you are using factor variables, you might have accidentally treated a
continuous variable as a categorical, resulting in lots of categories.
Use the c. operator on such variables.