Calculate difference between multiple changing columns in R I have a dataframe (df) in R with 7 columns