[asking for help] R studio regression problems

Hi, welcome to the forum.
I have never used the plm package and I don't work with panel data but I think we need more of your code and a bit of sample data. It looks like you have library(openxlsx); library(plm) loaded. Any others?

Can you some sample data, I think the "cleaned" panel data is sufficient.

Use the dput() function. Do dput(mydata) where "mydata" is the name of your dataset. For really large datasets probably dput(head(mydata, 100)) will do. Paste the output between
```

```

Your code starts off with

for (pge_var in pge_variables) {

It is hard to do much start any checking when we don't even know what *pge_variables * are.

You probably do not want to do a full reprex with that many lines of code but there may be some useful hints.
You may also find this helpful.