Improvements to the average functionality
- Removed scale negative check
- Unified loops