If we knew the answer to that we could patent it and sell it to Everlast.
There are various popular adages in boxing, one of which is that the toughest boxers come from the streets. That was true in the cases of Danny "Little Red" Lopez and Roberto Duran. But it didn't seem to be true for Mike Tyson, who caved in under pressure.
Carlos Monzon's trainer said the toughest fighters didn't come from the streets; they came from prison. Again, that's been true of some champs, while others seem to have been hindered rather than toughened by the experience.
There are just as many cases to indicate that a perfectly normal lower class or middle class background made for tough fighters.
I like to parody Teddy Atlas, who's a good guy but tends to rant almost like John Madden and Yogi Berra: "75% of boxing is 90% mental."