Depends on how much power you put out, how many hard holes you ride over, if you crash it etc. Then with everything, sometimes there's a small defect that magnifies over time. Of course some will ride the frame every day for 2 hours or 6 hours and some will not touch it for months.
Then there's the construction of the walls and joins on the frames. Some steel and aluminum frames are incredibly thin, while some cf frames are noticeably thicker. I have a friend that is still putting thousands of miles a year on his Giant CFR Two from 1994, I have another friend that broke an aluminum frame each year for three years in a row (and then switched to cf). It's all relative.