Hello All,
I'm running a regression with quadratic terms, and I'd like to graphically see the marginal effects that the explanatory variables have on my dependent variable. The code looks like this:
An excerpt of the data is found below, where the car is the dependent variable and the next two columns are the explanatory variables:
I basically need the graphs to illustrate the type of relationship between the variables.
I'd appreciate any help.
Best wishes,
Henry
I'm running a regression with quadratic terms, and I'd like to graphically see the marginal effects that the explanatory variables have on my dependent variable. The code looks like this:
Code:
xtreg DepVar c.Var1##c.Var1 c.Var2##c.Var2 controls, re robust
Code:
* Example generated by -dataex-. To install: ssc install dataex clear input float(car dcci dgei) .006094572 -.04854369 -.04368925 .012289982 -.6504854 -.38349515 .06451058 .014563024 -.02912617 -.020245453 .04368925 .009708762 .027952485 -.12440193 -.019138753 .15572175 .54761904 .354067 -.0610842 -.0333333 -.05263162 .0403212 .06161141 .03317535 .03867084 .028436065 .04265404 .015166337 -.7535545 -.4739337 -.017820526 .3744075 .28436017 -.037084136 -.004739404 .014217973 -.002426952 -.05687201 .004739404 .03104728 -.08653843 -.10576928 .018293347 .014423072 .01923084 .000480968 -.2259615 -.11057699 .014685898 -.024038434 -.06730765 .0000147832 -.10576928 -.07692307 .007311615 .033653915 .019230783 -.06690646 -.04326928 -.0625 end
I basically need the graphs to illustrate the type of relationship between the variables.
I'd appreciate any help.
Best wishes,
Henry
Comment