Update slope calculation...not working yet