NI/Total shareholder investment vs. NI/Total shareholder equity

Hi everybody, I read some financial books- financial ratio part and see that there are two ways to computer ROE. 1/ ROE = NI/Shareholder equity 2/ ROE= NI/Total shareholder investment And the books also explain that analyst can select method of calculating depend on their analyst purposes. I just wonder if there is any regulation for this. As your practical experience, could you pls kindly give me some examples of selecting between methods for analyst purpose? Thanks you very much for your time sharing your opinion.