Add linear regression residual plot function