File size: 326 Bytes
09283ec
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
# utils/plot.py
import matplotlib.pyplot as plt

def plot_forecast(y_true, y_pred, title="Forecast"):
    fig = plt.figure()
    plt.plot(y_true, label="Actual")
    plt.plot(y_pred, label="Forecast", linestyle="dashed")
    plt.title(title)
    plt.xlabel("Time Step")
    plt.ylabel("Value")
    plt.legend()
    return fig