How to add value in total rows of script report?

In my script report I need to show previous result in total rows. That value doesn’t exist in report rows. I’m calculating it and like place it in total row. Any way around?