Can you go more into detail, what you expect the output to look like? When you use identical models (variables) with different datasets, I don't see misplaced output.
library("plm")
library("stargazer")
data("Produc", package = "plm")
model1 <- plm(log(gsp) ~ log(pcap) + log(pc) + log(emp) + unemp,
data = Produc,
index = c("state","year"),
method="pooling")
model2 <- plm(log(gsp) ~ log(pcap) + log(pc) + log(emp) + unemp,
data = Produc,
index = c("state","year"),
method="between")
model3 <- plm(log(gsp) ~ log(pcap) + log(pc) + log(emp) + unemp,
data = Produc,
index = c("state","year"),
method="within")
stargazer(model1,model2,model3,type="text",keep.stat = "all",align = TRUE)
stargazer(model1,model2,model3,type="latex",keep.stat = "all",align = TRUE, out="output.tex")

Notice that the align
option only works in latex output and only if you have loaded the package dcolumn
. Latex, with and without the dcolumn
:
