I would like to test if serial correlation is present in my model. I have a large panel data set and I run the regression with felm and let's call the model felmmodel.
I know there are several ways to test for serial correlation. For instance, pdwtest , pwfdtest or pbgtest .
However, when I try to run these tests with felmmodel, I always get an error saying I cannot use these tests with felm. Is there another function in R where I can test for serial correlation with felm?
The reason I use felm and not plm for my regression is that I would like to cluster my standard errors based on a specific variable in my dataset. I can specificy that when using felm. With plm, I have to use coeftest(plmmodel, vcov. = vcovHC(plmmodel, cluster="group")) . I can only choose beteen cluster="group" or cluster="time" but nothing else.