Improved code quality and updated daylight plot