Always free. For everyone.
Project lab
Energy · Intermediate

Forecast a solar-powered tomorrow

Explore a small solar installation and estimate daily energy output.

Open in the Learning Lab
THE CHALLENGE

How much energy could this system produce tomorrow?

A fictional campus wants to understand its solar generation. Explore 60 synthetic daily readings. First calculate an engineering estimate from sunlight hours, then compare a simple regression model using a final time-based test set.

Build it, step by step

  1. 01

    Load the data and check units: sunlight is in hours, temperature in degrees Celsius, and generation in kWh. Inspect missing values and plot generation over day.

  2. 02

    Use rated capacity × sunlight hours × 0.8 as a simple baseline. The installation has a rated capacity of 4.2 kW. Calculate its mean absolute error.

  3. 03

    Use days 1–36 to train and days 37–48 to compare a regression model with the baseline. Use sunlight hours and temperature as features.

  4. 04

    Choose your model before evaluating once on days 49–60. Report test mean absolute error in kWh. Compare residuals across temperature ranges.

  5. 05

    Explain that sunlight and temperature must be forecasts at prediction time. Write down three reasons synthetic performance may not transfer to a real site.

WHAT GOOD WORK LOOKS LIKE

Your project checklist

  • A plot with labelled axes and units.
  • A baseline and a regression model compared using the same split.
  • A final test score reported in kWh, with the test period untouched during model choice.
  • A short report about weather forecast error, data limits, and next data to collect.
ABOUT THE LEARNING LAB

Free, open and run by a nonprofit.

This page is part of Python to AI, a free course of 20 modules and 60 lessons in the engineering.fit( ) Learning Lab. The Learning Lab is built and run by engineering.fit( ), a nonprofit founded by Abdullateef Opeyemi Bakare that helps African engineering students gain research experience. You do not need an account or pay a fee to learn.

Course outline · Project lab · Visit engineering-fit.org