Why does an unpluged egr valve run better then

I am not sure what you mean? My car registerd a P401 code which the sheet says is an ERG issue of some type. My friend said until i get it fixed to just unplug the hose that connects to the top part of the mushroom shaped EGR valve and the knock and pinging would be less and it is. So are saying that by doing this it shows that it is the EGR valve itself that is bad as it must be open all the time?