funcs for regression analysis