As with many things in these sitches, there are those polar thoughts of staying together "for the kids" and the kids should not be a reason to stay in an unhappy M.
My opinion is you are asking the right question.
Regardless of what you do, what example are you setting for the kids...
A person could leave an abusive M and still set a bad example, just as a person staying in a good M and setting a bad example.
Creating a positive context and showing positive behaviour regardless of the sitch is an awesome path.