I found this interesting statistical analysis on /r/CFB someone did for punting when past mid field.
|team TDs||team FGs||team safeties||opponent TDs||opponent FGs||half/game ends||balls back|
|going for it||26.75%||9.4%||0%||15.88%||5.85%||13.17%||28.94 %|
TLDR: Teams who go for it on 4th down instead of punting in opposing territory are MUCH more likely to score (36% to 3.5%) and slightly less likely to get scored on on the succeeding drive (22% to 27%). Going for it on fourth down is in general not as much of a risk as it sometimes seems, with 2016 teams ranging from a blistering 70% on 4th and 1 to a still-healthy 34% on 4th and 10. The field position advantage given as the reason for punting in this situation doesn’t really have much of an effect, with an only 18 yard field position difference for teams who punt compared to teams which go for it.