Created variable for average

I created the missing variable