Yelling is not productive and it does not promote anything more than resentment especially when the person on the receiving in either does not know or does not understand why. Just because someone is not learning in a manner the sensei perceives is adequate to that individual does not mean it needs the disruption and negative emanations of yelling.
Command presence along with proper body language that includes specifically facial language, tone and intonation of words and voice tend to say a lot more than yelling.
Command presence can be achieved by deeds, actions and example. If you lack any of these then you tend to drop into the easiest form of disruptive and ineffective communications, yelling.
I know this because even today at fifty-nine years young when confronted by something that touches on certain emotional issues in my life I tend to lean toward frustration that sometimes leads to yelling - not good.
Yelling in the Marines is used in the first phase of boot camp but not as a teaching tool but rather as a means to disorient, confuse and create a model of indecision so they can take training to a model that one acts without thought and acts quickly but I stress that often after only a short time the yelling is lessened for more productive teaching methods and the use of command presence to achieve obedience, etc. to orders and certain processes that are all life and death oriented.
I have command presence that I learned from the Marines. I have a strong voice that when the timber and tone take a certain note along with facial expressions and body language convey meaning that is meant to teach quickly.
Now, as to the dojo, there is no need for any of this. There are no time limits on budo. There are not time constraints on either the dojo as a group or on individuals as budo is meant to be learned over time and at the pace and ability levels of each individual. The modern dojo with its emphasis on students, classes and lesson plans with time and requirements set in stone tend to lean toward larger groups that have limited time to learn or they lose money, etc.
In a traditionally formed dojo environment that is closer to the cultural systems of martial arts tend to have no such restrictions or requirements. Then the individual learns at their own pace and the teachings are adjusted accordingly.
Yelling in the military as I might add is caught up in the time constraint, i.e. make a Marine combat ready in as short a time as nine weeks - a huge responsibility and a very small window that must be met to achieve war readiness. This model came about from WWII and Korea and Viet Nam, etc. but in peace time it was adjusted to thirteen weeks which is still, for some, a short turn-a-round.
I digress, in today's modern training facilities yelling is not necessary and a throw back to the military influences of folks who brought martial systems to our country in the late fifties and early sixties. It is not necessary even for shugyo.
In testing, if used, shugyo can and is achieved in daily training and can be achieved in a short intense test environment without debasing and denigrating an human being with yelling and screaming no matter how you justify it by saying it puts the kind of pressure needed for a shugyo type environment.