- formatting changes.. swapped date variable for inplace calculations