Regression simulation function