added code to compute change in gap ratio and return a new dataframe, let's see if it is modular enough to be useful