regression error is calculated