A naive attempt to implement linear regression