Next Article in Journal
The Lightweight Fracture Segmentation Algorithm for Logging Images Based on Fully 3D Attention Mechanism and Deformable Convolution
Previous Article in Journal
Ocean Acidification and Sea Temperature Rise Affect the Queen Scallop Aequipecten opercularis (Linnaeus, 1758) in Captivity
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Prediction of Intraday Electricity Supply Curves

by
Guillermo Vivó
1 and
Andrés M. Alonso
2,*
1
Campus Puerta de Toledo, Universidad Carlos III de Madrid, 28005 Madrid, Spain
2
Department of Statistics and Institute Flores de Lemus, Universidad Carlos III de Madrid, 28903 Getafe, Spain
*
Author to whom correspondence should be addressed.
Appl. Sci. 2024, 14(22), 10663; https://doi.org/10.3390/app142210663
Submission received: 8 October 2024 / Revised: 28 October 2024 / Accepted: 13 November 2024 / Published: 18 November 2024
(This article belongs to the Special Issue Artificial Intelligence for Smart Infrastructure Solutions)

Abstract

:
The electricity market in Spain, as in many European countries, is organized into daily, intraday, and reserve markets. This project aims to predict the supply curves in the Spanish intraday market that have six sessions with different horizons of application, using information from the market itself. To achieve this, we approximate these curves using a non-uniform grid of points and evaluate the quality of these approximations with a weighted distance, both based on empirical market data. We employ neural network models, including multilayer perceptrons (MLPs), convolutional neural networks (CNNs), long short-term memory (LSTM), bidirectional LSTM (BiLSTM), and a Transformer network alongside a naive model for benchmarking. The MLP and CNN models demonstrated significant improvements in predicting these supply curves for the six market sessions.

1. Introduction

Having reliable predictions of future electricity transaction volumes and prices is valuable information for both generators and consumers, as well as for the system operator. For the generators and consumers, this data provides an advantage when planning and optimizing their processes and finances. For system operators, it allows them to anticipate issues related to the physical reality of electricity (such as potential overloads) and prevent them. One potentially accurate approach is to forecast these prices indirectly by intersecting supply and demand curves. As we will see in the next subsection, the electricity market is organized into different submarkets that occur at different times of the day, the offers of which have different application horizons. In each of these submarkets, the supply curves are obtained from the production proposals (energy and price) made by the participating companies.
The objective of this paper is to obtain a reliable prediction of the supply curves of the intraday market, which is a less studied market than the daily market that has a single session. The intraday market has six sessions during the period analyzed. In the next section, we will describe the Spanish electricity market structure, and we will show the motivations for the approach that we followed in predicting the supply curves for the intraday market.

Spanish Electricity Market

The enactment of Law 54/1997 on 27 November 1997 initiated a progressive liberalization of the Spanish electricity sector [1]. This reform involved allowing third-party access to networks, creating a structured energy trading market, and minimizing government control over system management. Currently [2], electricity generation and commercialization are liberalized activities in the market, while high-voltage transmission (which remains a monopoly controlled by the government) and low-voltage distribution are regulated activities. Figure 1 shows a representation of the structure of the Spanish electricity sector (see [3,4]) (In Figure 1: Audax Energía, Comisión Nacional de los Mercados y de la Competencia, Endesa, EDP HC Energía, Iberdrola, Gas Natural Fenosa, Nexus, Red Eléctrica de España and Viesgo are official names of companies and regulatory institutions).
The Spanish electricity market is actually a set of interconnected markets designed to meet the changing needs of electricity supply and demand. In addition to electricity transactions planned for weeks, months, or years ahead, many trades are conducted with only hours or even minutes of notice before the actual generation of the energy. Given that electrical energy is difficult to store, production at each moment must match the demand. Supply and demand have a volatile nature due to weather conditions, socioeconomic factors, and other variables, highlighting the need to constantly review negotiations in line with current forecasts. Additionally, the energy transmission network must be physically capable of executing what has been agreed upon.
Following the 2007 integration of the Spanish electricity market with the Portuguese one in the so-called MIBEL (Iberian Electricity Market), the resulting market was coupled with Europe progressively from 2013, establishing a single price in the connected regions when the system allows it.
In the daily market [6], which is organized by OMIE (Iberian Energy Market Operator), energy transactions between generators and consumers are conducted for each of the 24 h of the following day (which is referred to as the ‘dispatch day’ and is denoted by D). Once the bids from producers for each hour of the next day are submitted, they are arranged in ascending order, forming the market supply curve for each hour. The bids from buyers are ordered in descending order of price, forming the market demand curve. Finally, the market price for the following day is set by the intersection point of the supply and demand curves. It follows a pay-as-clear system, meaning that all participants, both buyers and sellers, pay the market price established for that period.
Following the daily market, participants have the opportunity to buy and sell electricity again in the intraday market, held a few hours before real-time operations, or in the continuous intraday market, which operates under a European crossborder framework [7]. Intraday markets, also organized by OMIE, provide a crucial mechanism for market players to fine-tune their schedules from the daily market to better align with real-time energy demands.
Lastly, there are reserve markets through which the system operator, Red Eléctrica de España, ensures the physical feasibility of the previously negotiated generation and distribution of energy, making adjustments to the agreements.
In this paper, we focus our attention on the intraday markets, with our goal being to forecast the supply curves of these markets, specifically using information from the market itself and its predecessor. In the period of interest for this project (see Section 3.1), these markets were organized into six auction sessions, which are carried out sequentially, each with its own application horizon. Table 1 shows the schedules and market horizons for these sessions.
In Table 1, we can see that the times at which the programs and results of a session are published allow that information to be used to predict the curve of the following session. For example, the results and trading programs of the first session are published at 16:20 at the latest on day D-1, and the second session occurs between 17:00 and 17:50 on the same day. Similarly, the results of the daily market are known before the first session of the intraday market, and, therefore, their information can be used to predict the supply curve of the first session. This is the predictive modeling proposal that we will use in this project, using data from the previous market session to predict the next session. We, therefore, pose the following research questions that will be addressed in this project:
  • Q1: Is it possible to predict supply curves more accurately than using the curves from the previous day?
  • Q2: Is it useful to incorporate information from the previous market to predict curves from intraday market sessions?
The prediction of supply curves in the electricity market is not a new topic in the literature, but, as we will see in the next section, previous research has focused on the prediction of the day-ahead market or the reserve market, which are markets that occur once a day. Our research aims to close the gap in terms of a type of market structure in several daily sessions.
The rest of the paper is organized into four sections. Section 2 presents the state of the art regarding the prediction of supply curves. Section 3 develops the proposed methodology and describes the considered models. The results are presented in Section 4. Finally, the conclusions and possible extensions are discussed in Section 5.

2. State of the Art for Supply Curve Prediction

Most of the published works in this field focus on directly predicting the energy price and demand or other scalar variables. Three recent reviews on the techniques used for such purposes can be found in [8,9,10].
Our objective is to predict an offer curve, which is a more complex task. Nonetheless, obtaining this prediction is, indirectly, a prediction of the energy price, which is achieved by obtaining the intersection point of the forecasts of the supply and demand curves, as proposed by [11]. The two main challenges in predicting a supply curve are that it is not a prediction of a scalar quantity and it is not a continuous function.
An approach that addresses the first challenge is the procedure proposed by [12], which uses functional data nonparametric techniques to model residual demand curves. Since they use nonparametric kernel-type estimators, they are limited by the problem known as the curse of dimension and, therefore, only consider a single functional regressor. These authors assume that the curves are sufficiently smooth with up to two derivatives, which contradicts the second challenge.
In [11], LASSO regression is used to forecast a short number of bid classes obtained from the supply and demand curves in the EPEX market. This paper used the term “X-model” to denote the process of obtaining the price as a result of crossing the supply and demand curves. This is the first work that addresses both challenges since it takes into account the fact that the functions to be predicted are stepwise. In [13], a modification of the X-model is proposed, where transformed versions of the curves are used by assuming a perfectly inelastic demand. Both methods use a small number (only 16) of bid classes, which makes their approximation of the curves imprecise. In fact, as the motivation of [11,13] is price prediction, the authors do not study the behavior of the procedure as a curve predictor.
Parametric and nonparametric functional autoregressive models were used in [14] to model the supply and demand curves of the Italian electricity market. Again, the techniques used assume smoothness conditions that are not satisfied by step functions.
Another approach is to approximate the curves using others from a parametric family and predict the relevant parameters. In the literature, various procedures of this kind can be found, such as using radial basis functions in [15] or using polynomials and sigmoid functions [16]. In [15], univariate autoregressive models were used for each of the parameters, and weekly seasonality was modeled using dummy variables. The authors of [16] used vector autoregressive models with seasonal harmonic component periods of 24 and 168. This approach has the attraction that the number of parameters to be predicted is small, but it does not solve the challenge regarding the non-continuity of the curves.
In [17], a continuous piecewise version of the supply curve is used to approximate it with great precision. This approach has the disadvantage that it increases the number of nodes to approximate the curves.
The authors of [18] followed the approach of using a grid of points to generate stepwise functions for the supply curves at the Spanish secondary market, which is one of the reserve markets managed by Red Eléctrica de España. The authors consider random forest, gradient bootsting, dense neural networks, and long short-term memory models to predict supply curves assumed to be observed on a fixed grid with 50 nodes.
In [19], a distance learning procedure is proposed to forecast the day-ahead curves for the daily market. This approach does not need to approximate the curves because it relies on the distances between them. It proposes the prediction of the distances between the curves on day D+1 and the curves in the training set based on the distances between the curves on day D and those curves in the training set. The procedure is highly computationally intensive and it is not clear how other scalar covariates will be incorporated.
All the papers mentioned focus on daily markets, with the exception of [18], which studies a secondary reserve market. None of them have studied the intraday market with its respective sessions. It should be noted that this structure of the electricity market, which is subdivided into daily markets, reserve markets, and intraday markets, is common in many European countries (see [20,21]). Prediction in the intraday market has the added difficulty of several sessions being carried out on the same day and different prediction horizons, as shown in Table 1. In this project, we turn this difficulty into an advantage because we can use the information from the previous session to predict the session that follows. As we can see in Table 1, the publication times of the session results make this approach feasible.

3. Methodology

We now present the methodology followed in this paper in detail, dividing it into four parts: the source of the raw data and its format, the preprocessing performed once the data was obtained, the error metrics and the subsequent construction of the models, and the generation of the predictions. The Python 3.1 code implemented for this article is available upon request to the authors.

3.1. Raw Data

The raw data were obtained from the OMIE website, https://www.omie.es, accessed on 25 April 2024. The information is organized in files with a .1 extension (which can be read as .csv). Each file corresponds to the data of a specific market on a given day. The naming convention for these files works as follows:
  • For the daily market, the names follow the format curva_pbc_uof_yyyymmdd.1, where yyyy refers to the year, mm to the month, and dd to the day the file refers to (to the date being negotiated, not the date the negotiation took place).
  • For the intraday markets, the structure is similar, curva_pibc_uof_yyyymmddxx.1, where xx refers to the number of the market, going from 01 to 06. For instance, the file curva_pibc_uof_2021032704.1 contains data related to the fourth intraday market on 27 March 2021.
Each file starts with a block of metadata, followed by the relevant information. The information is presented in Table 2.
  • Hour. This refers to the hour for which offers and demands are made. The number represents the position of that hour in the day, regardless of what the clock shows. For example, on a day when the clock is moved forward, the period from 03:00 to 04:00 corresponds to the third hour of the day, whereas, on a normal day, it would correspond to the fourth hour of the day.
  • Date. This refers to the day for which offers and demands are made. It is given in the dd/mm/yyyy format.
  • Country. This refers to the market to which the offer to buy or sell is presented. The codes are as follows: MI (Iberian Market: both Portugal and Spain), ES (Spain), or PT (Portugal).
  • Unit. An alphanumeric code that is used to identify the current offer or demand.
  • Offer type. This refers to whether the offer is for buying (C) or selling (V).
  • Buy/Sell Energy. The amount of energy offered or demanded, expressed in MWh and in the Spanish number format.
  • Buy/Sell Price. The bid or ask price for the respective energy, expressed in EUR/MWh and in the Spanish number format.
  • Offered/Matched. This indicates whether the energy–price pair corresponds to the offers curve (O) or the resulting matching program (C).
  • Choice of Date Range
For the development of this work, we used only the information from 2022 and 2023. The reason for using only these two years (despite having data from a longer period) is due to changes in market regulations. In particular, the price ranges of the markets have varied substantially over the years. Although we normalized the prices to standardize the limits, the density of their distribution varies depending on the original price range, and this affects the models’ performance. The two most recent changes are
  • 20 May 2021 [22]. Maximum and minimum offer price limits were set at −500 EUR/MWh and 3000 EUR/MWh for the daily market and −9999 EUR/MWh and 9999 EUR/MWh for the intraday market.
  • 11 May 2022 [23]. The price range from −500 EUR/MWh to 3000 EUR/MWh of the daily market was changed to the new one from −500 EUR/MWh to 4000 EUR/MWh. Despite this change, there are few offers above the previous limit of 3000 EUR/MWh. Therefore, we decided, instead of normalizing, to divide by the previous legal range (which remains, in practice, as the current range).

3.2. Preprocessing

3.2.1. Train-Test Split

The data were split into training and testing sets, with the training set covering the dates from 1 January 2022 to 31 December 2022 (both dates inclusive) and the testing set covering the remaining dates. Regarding the partition of the training set into train-train and train-validation, the first one covers from 1 January 2022 to 31 October 2022 (both dates inclusive), while the second one covers the rest of 2022.

3.2.2. Data Preprocessing

The first step taken before preprocessing was to verify that all the files in our interest existed and that these files were in the correct format (for example, not empty); we did not find any errors.
Once that was carried out, the following process was carried out for each of the files. Once the file was read as a .csv file, we filtered the data to retain only the sell offers from the original offer curve (not the resulting matching program). Then, the numerical values were changed from the Spanish number format to the English one. Moreover, the numerical data were formatted into Python’s float type, and the names of some variables were shortened.
Then, the offers were grouped by day and hour, grouping them again into larger 24-h blocks (day by day). However, this poses a problem. In Spain, the clocks are set forward 1 h in the spring and set back 1 h in the fall [24]. Therefore, the affected dates have a different number of hours, which may conflict with our desired homogeneous data format. The specifics are as follows:
  • The markets with a 24 h application horizon (the daily market and the first and third intraday markets) are affected by these time changes. Some days have 23 h, while others have 25. Since these represent a tiny percentage of the total dates, we chose to remove the last hour on 25 h days and duplicate the last hour on 23 h days, ensuring we always had 24 h.
  • The second daily market, with its 28 h application period spread over 2 days, required a more detailed examination. Its application horizon covers an entire day and the last 4 h of the previous day. This market is only affected by time changes when they impact the 24 h day it applies to, resulting in markets with either 27 or 29 sessions. We handled this full day in the same way as the 24 h horizon markets.
  • The offers and demands in the intraday markets with a horizon of less than 24 h (the fourth, fifth, and sixth) pertain to the respective last hours of the day, and therefore, these markets are not affected by the time changes. However, on 10 October 2022 (the clocks were set back on this date [24]), the fourth intraday market conducted 21 h instead of 20. Given the minor nature of the issue, we addressed it by removing the first hour and keeping the last 20, which is in line with the market structure and the format of our data.
Another potential issue is that, due to anomalous situations, technical complications, or regulatory changes, a day might have an abnormal number of sessions. Fortunately, there were no such problems in our date range.
Once the issues related to temporal homogeneity had been assessed, each hourly block was sorted in ascending order by offer price. Next, we normalized the price values and summed the energies corresponding to these prices cumulatively, replacing the original energy value and finally obtaining the offers curve. We merged the hourly blocks into a larger dataframe of 24 h and attached this block to all the previous ones, creating a single dataframe for all prices and another for all energies (logically, this process is carried out once for each market).
It should be noticed that the dimensions of these dataframes are not homogeneous since they vary depending on how many different prices are present in the corresponding session. Structural homogeneity in our data is addressed in Section 3.2.4.

3.2.3. Representation of Curves

Regarding the energy-price relationship, we can represent it using either the P-Q representation (with prices on the x-axis and energy on the y-axis) or the Q-P representation (where the axes are reversed). We opted for the first option because, in this way, the curves always have the same domain (the range of prices is the same). This approach provided a more uniform framework.

3.2.4. Approximation Procedures for Curves

Since our goal was to predict a curve, we needed a method to synthesize its information and work with this synthesis as input and output for our models. Two straightforward approaches are to approximate it with curves from a parametric family (and work with these parameters) or to approximate it using a grid of points (and work with them), interpolating the intermediate values. We chose the second option since the use of a parametric family usually requires assumptions about the smoothness of the functions, and we know that the supply functions are step functions.
There are three issues to consider:
  • Interpolation technique. Since we were working with nondecreasing step functions, it was reasonable to interpolate consistently with this property, using right-side constant interpolation (i.e., the interpolated values are equal to the largest grid point value smaller than them).
  • Uniformity of the grid. Despite the broad price ranges presented by the markets, in reality, most offers occur within a more limited range. Given our interest in accurately representing this subinterval, it made more sense to use a non-uniform grid, allocating more density to these empirically observed regions. In Figure 2 and Figure 3, we observe that, although both interpolations generally fit the original curve well, the non-uniform interpolation captures the section of the curve with a higher density of transactions much better.
  • Grid size. There is a trade-off between precise representation and the informational weight of the grid (which we wanted to reduce compared to the raw data). We opted for a grid of 150 points.

3.3. Error Metrics

To define an approximation error, we needed to establish when two curves are considered similar. We took the Euclidean distance, d 2 , which is commonly used in functional data analysis, which is defined as
d 2 ( f , g ) = ( f g ) 2 ,
where f and g are curves. The d 2 distance in (1) measures how that separation varies across the entire domain. Although it is generally a good tool, in our case, it presented two problems.
  • Integrals are a continuous operation, whereas we only had a grid of points. The accuracy of our approximation to the true value of the integral would be better if we used a more dense grid of points. Therefore, we calculate the approximation
    x f ( x ) g ( x ) 2 Δ x
    by not using the non-uniform grid previously discussed but by reconstructing a more dense curve. The value of Δ x in (2) was set to 0.0001. Note that by scaling the prices we have, the integral is performed on the interval [0, 1].
  • As mentioned, almost all offers and demands occur within a price range that does not cover everything considered by the regulations. See, for instance, Figure 2 and Figure 3, where the scaled prices are concentrated in the interval [0.4, 0.6]. When using the interpolation we just mentioned, the non-uniformity introduced in the grid is lost. To bring it back, we modified the d 2 distance formula. The idea is to use a density factor, K, that gives more weight to the more typical price ranges:
    d K ( f , g ) = ( f g ) 2 K .
    The K factor in (3) is obtained as an estimate of the density of the bid prices for each session. This means that if, in a session, the majority of bids have their (scaled) prices in the interval [0.4, 0.6], then the differences in that interval have a greater weight than outside that interval. Each session has or can have a different K factor since it depends on the prices of its offers.
Given that we had a huge number of predictions, we calculated statistical metrics to summarize the errors made: the mean, median, standard deviation (SD), and mean absolute deviation (MAD).

3.4. Models and Predictions

3.4.1. Input and Output Format

We opted for a direct multi-output approach. Particularly, for predicting a specific market, we incorporated all data from the preceding market on the same day as well as all data from the previous day of the target market. For the first intraday market, we used the daily market as its predecessor. Therefore, the inputs had a dimension of ( H s + H p ) × 150 , where H s is the number of horizon hours of the market we were trying to predict, and H p is the length of the horizon for the preceding market. Consequently, the output had dimensions of H s × 150 .

3.4.2. Correction of Predictions

The neural networks we used to predict the curves, which are reconstructed from the predicted grid values using the interpolation discussed in Section 3.2.4, successfully captured their shape. However, they failed to generate curves satisfying the assumption of being nondecreasing. To address this, we opted for the following procedure to produce a corrected curve:
t ( x ) = c ( x ) if c ( x ) > t ( y ) for all y < x , t ( z ) if there exists z < x such that t ( z ) t ( y ) for all y < x and t ( z ) c ( x ) ,
where c is the predicted curve and t is the corrected curve. An example of the subtle but crucial effect of the transformation defined in (4) can be observed in Figure 4.

3.4.3. Selection of Hyperparameters

All the models (except for the naive one) have hyperparameters to be tuned. To do this, we used the partitioning of the training set into the train-train and train-validation sets mentioned earlier. The hyperparameter selection that performed best in this partition was used for the final prediction in the train-test partition.
Given the scale of our models, testing a large number of hyperparameters entailed an unmanageable computational cost. Therefore, we opted for the following approach: for models with 300 or fewer hyperparameter combinations, we tested all of them. If the number of possibilities exceeded this value, we randomly selected 300 combinations (always using the same seed). In all models, this value never accounted for less than 40% of the total possible combinations, providing greater confidence that the selected set is close to the optimal in terms of performance.

3.4.4. Model Comparison

Finally, we needed a tool that allowed us to determine whether one model was statistically significantly better than another. We used the Diebold-Mariano test [25] (see also [26]), which compares whether the two forecasts { a i } i = 1 n and { b i } i = 1 n of a series of real numbers, { x i } i = 1 n , are significantly different. The null and alternative hypotheses of this test are
  • H 0 . Both forecasts have the same accuracy, meaning that the observed differences are likely due to randomness;
  • H 1 . One forecast has better accuracy than the other, meaning that the predictive difference between the models is unlikely to be due to randomness.
To calculate the statistics, we obtain the series of the differences in losses.
d i = ( x i a i ) 2 ( x i b i ) 2 ,
as well as their mean and autocovariance, which are, respectively,
d = 1 n i = 1 n d i and γ k = 1 n i = k + 1 n ( d i d ) ( d i k d ) .
Finally, the value of the statistic is obtained from the expression
DM = d 1 n ( γ 0 + 2 k = 1 h 1 γ k ) ,
where it is generally adequate to use the value h = n 3 + 1 . Under the null hypothesis, the DM statistic distributes as an N ( 0 , 1 ) . In the case of rejecting the null hypothesis, it follows that the first model has better predictions if DM has a negative value; if DM has a positive value, then the second model is the one with the best performance.
The problem we faced was that, as we have seen, the Diebold-Mariano test is designed to compare two time series of real numbers as predictions of another real number series, but the objects in our time series are curves. We addressed this issue by considering not the time series of curves but the sequence of errors (which are real numbers), meaning we substitute x i a i and x i b i in (5) with the prediction errors of the two curves’ prediction methods. That is, instead of x i a i and x i b i , we use d k ( x i , a i ) and d k ( x i , b i ) , respectively. We have used the db.test function included in the forecast package in R 4.2.2 [27].

3.4.5. Naive Model

The naive model assumes that the offer curve for a given day is exactly the same as that of the previous day. Obviously, this model is computationally inexpensive and served as a benchmark to determine whether the other models were significantly better.

3.4.6. Multilayer Perceptron Model

The multilayer perceptron [28] (MLP) is the simplest neural network. For an application of MLP in energy forecasting, see [29]. It consists of several layers of neurons (computational unit that processes inputs to produce an output, contributing to the network’s overall task), with each neuron being fully connected to all neurons in the previous and subsequent layers. By adjusting the weights and biases (parameters) using a back-propagation algorithm and a cost function, the network learns the patterns in the training data. The considered hyperparameters were the following:
  • epoch. The number of complete passes of the training dataset (epochs). The assessed values were 5, 10, and 20;
  • n. The number of layers besides the input and output layers. We considered one, two, three, and four layers;
  • neuron. The number of neurons in each layer. The tested values were 5, 10, 20, 50, 100, 200, and 400;
  • act. The activation function, which is a mathematical function applied to each node, introduces nonlinearity into the network and allows it to learn complex patterns. We tried two different functions: ReLU and tanh;
  • batch. The number of training examples used in one forward and backward pass of the training process. The tested values were 3, 10, and 30.
The selected hyperparameters for the MLP model are available in Table A1 in Appendix A.

3.4.7. CNN Model

Convolutional neural network (CNN) [30] models are primarily used for visual data analysis (for example, image classification or object detection). For an application of a CNN in energy demand forecasting, see [31]. The main features of these networks are convolutional layers (where convolutional filters are applied, producing feature maps), pooling layers (which reduce the spatial dimensions of the feature maps), and fully connected layers (used to make final predictions). The considered hyperparameters were the following:
  • epoch. The number of complete passes of the training dataset (epochs). The assessed values are 50 and 100;
  • n_dense. The number of fully connected layers besides the output layer. We studied one, two, and three layers;
  • n_conv. The number of convolutional and pooling layers (we always introduce a pooling layer after each convolutional layer). We considered one, two, and three layers;
  • neuron. The number of neurons in each fully connected layer. The tested values are 5, 10, 20, 50, and 100;
  • fil. The number of filters in each convolutional layer. We considered eight and 16 filter cases;
  • kernel. The dimensions of the kernel matrix in each convolutional layer. The values studied are 3 × 3 , 5 × 5 , and 7 × 7 .
The selected hyperparameters for the CNN model are available in Table A2 in Appendix A.

3.4.8. LSTM Model

Long short-term memory (LSTM) models [32] are recurrent neural networks used for time-series data and natural language processing. For an application of LSTM in energy consumption forecasting, see [33]. This model successfully addresses the vanishing or exploding gradient problem that other recurrent networks face, thus understanding long-range dependencies in sequence data. Instead of regular nodes, such as in MLP, LSTM networks have cells (arranged in layers), which are more complex structures that can update the information they store by using mechanisms such as the forget gate or the cell state. In our model, we also added fully connected layers after the LSTM layers. The considered hyperparameters were the following:
  • n_LSTM. The number of LSTM layers. We tested one and two layers;
  • n_dense. The number of fully connected layers besides the output layer. The values studied are one, two, three, and four;
  • unit. The number of cells per LSTM layer. The assessed values are 5, 10, 15, 20, and 50;
  • neuron. The number of neurons in each fully connected layer. We tried 10, 40, 50, and 100 neurons;
  • dropout. The random deactivation of some input units to reduce overfitting. The studied values are 0, 0.1, and 0.2.
The selected hyperparameters for the LSTM model are available in Table A3 in Appendix A.

3.4.9. BiLSTM Model

Bidirectional long short-term memory (BiLSTM) [32] networks consist of two LSTM networks, processing sequential data both forwards and backward. This allows the model to capture information from both past and future contexts in a sequence. For an application of BiLSTM in power consumption prediction, see [34]. Once again, this structure is followed by fully connected layers in our model design. The considered hyperparameters were the following:
  • n_LSTM. The number of LSTM layers. We tested one and two layers;
  • n_dense. The number of fully connected layers besides the output layer. The considered values are one, two, three, and four;
  • unit. The number of cells per LSTM layer. We tried 10, 20, 50 and 100 units;
  • neuron. The number of neurons in each fully connected layer. The assessed values are 10, 40, 50, and 100;
  • dropout. The random deactivation of some input units to reduce overfitting. The studied values are 0, 0.1, and 0.2.
The selected hyperparameters for the BiLSTM model are available in Table A4 in Appendix A.

3.4.10. CNN+LSTM Model

This model consists of CNN layers, followed by LSTM layers, and finally, fully connected layers. The considered hyperparameters were the following:
  • n_CNN. The number of convolutional and pooling layers (we always introduce a pooling layer after each convolutional one). We considered one and two layers;
  • n_LSTM. The number of LSTM layers. The considered values are one and two;
  • n_dense. The Number of fully connected layers besides the output layer. We tried one, two, three, and four layers;
  • filter. The number of filters in each convolutional layer. We considered eight and 16 filters;
  • kernel. The dimensions of the kernel matrix in each convolutional layer. The assessed values are 3 × 3 , 5 × 5 , and 7 × 7 ;
  • unit. Number of cells per LSTM layer. We tried 10, 20, 50, and 100 units;
  • dropout. The random deactivation of some input units to reduce overfitting. The studied values are 0, 0.1, and 0.2 (ranging from 0 to 1);
  • neurons. The number of neurons in each fully connected layer: 5, 10, 20, 50, and 100 neurons were considered.
The selected hyperparameters for the CNN+LSTM model are available in Table A5 in Appendix A.

3.4.11. Transformer Model

Transformers are a relatively new neural network architecture [35] and have revolutionized natural language processing. The Transformer model was used for electricity load forecasting in [36]. Unlike previous frameworks (such as recurrent neural networks), Transformers do not process information sequentially. Instead, they use a self-attention mechanism that allows them to capture the relationships between words in a sequence regardless of their position. The considered hyperparameters were the following:
  • epoch. The number of complete passes of the training dataset (epochs). The assessed values are 20 and 50;
  • n_dense. The number of fully connected layers besides the output layer. One, two, and three layers were considered;
  • n_trans. The number of Transformer blocks. We tried one, two, and three layers;
  • head. The number of parallel attention mechanisms. The tested values are eight and 16;
  • dim. The size of the query, key, and value vectors used in the attention mechanism. The assessed values are 10, 20, 50, and 75;
  • dropout. The random deactivation of some input units to reduce overfitting. The studied values are 0, 0.1, and 0.2;
  • neuron. The number of neurons in each fully connected layer. We considered 20, 50, 100, and 200 neurons.
The selected hyperparameters for this model are available in Table A6 in Appendix A.

4. Results

4.1. Error Metrics

We now present the error metrics for the seven considered models. Table 3, Table 4, Table 5, Table 6, Table 7, Table 8 and Table 9 show the summary statistics of the prediction error using the d K measure. We see that the MLP and CNN models (Table 4 and Table 5, respectively) generally obtain good results when compared to the naive model (Table 3). This is not only observed in the centrality measures (mean and median) but also in the dispersion measures (SD and MAD). This is relevant because it implies that the errors with MLP and CNN are smaller and also more concentrated. LSTM-type models, i.e., LSTM, BiLSTM, and CNN+LSTM, do not perform well since their mean and median values are generally much higher than those obtained using the naive procedure. The Transformer model (Table 9) has mixed behavior.
We now group the mean prediction errors using the d K distance to facilitate the comparison of the models. In Table 10, the top three models for each market are colored red, green, and blue. We see that the CNN model obtains the best results in the first five sessions and is the second best in the sixth. In the sixth session, the best model is MLP, although the difference with CNN is small. We also see that the Naive model obtains good results, which indicates that, despite its simplicity, it is a good benchmark. It can be seen that the naive method is the second best in the first session market, only surpassed by the CNN procedure. The Transformer model improves the naive model in the fourth and fifth sessions.
Clearly, the best results are obtained for the second to sixth sessions using the MLP and CNN models. The percentage reduction in the error means with the MLP model compared to the naive procedure is between 22.6% in the third session and 63.8% in the fifth session. The reductions with the CNN model are between 35.2% and 69.6% in those sessions. In the fourth and fifth sessions, where the Transformer model is better than the naive procedure, the reductions are 4.0% and 18.6%, respectively. Therefore, they are lower than with MLP and CNN.

4.2. Model Comparison

The pairwise results of the Diebold–Mariano test between the top three models (which are mainly the naive model, the MLP model, and the CNN model, based on the previous results) are presented in Table 11, Table 12 and Table 13. It should be noticed that the obtained p-values are, with the exception of only one, much less than α = 0.005 , which is the value recommended in [37] in order to provide solid evidence, to reduce the rate of false positives, and improve the reproducibility of the research.
Table 11 and Table 12 present the results of the Diebold–Mariano test (7) for the comparison of the naive model versus our proposals, MLP, and the CNN models. It is observed that the MLP model significantly improves the benchmark in five of the intraday market sessions but is outperformed in the first session. For its part, the CNN model significantly improves the naive model in all sessions. The results in these two tables answer affirmatively to the two research questions (Q1 and Q2) that we posed in the introduction since we achieved better prediction results than the naive procedure using information from the market and from the session preceding the session to be predicted.
Finally, Table 13 shows the Diebold-Mariano test for the comparison of the MLP and CNN models. We find that the CNN model significantly improves the MLP in the first five market sessions. In the sixth session, although it is true that the mean error of the MLP is lower, the differences are not significant using α = 0.005 .
In Figure 5, boxplots of the prediction errors using the naive, MLP, and CNN models are shown. The improvements of MLP and CNN are evident in the second to sixth markets, where the boxes of the proposed models are below the median of the naive model. In the case of the first market, the naive model is better than MLP and slightly (but significantly) worse than CNN. We also see that the interquartile range for the MLP and CNN models is smaller than for the naive procedure. Therefore, their predictions have less dispersion. This is particularly clear in the second to sixth sessions.

5. Conclusions and Extensions

We have concluded that the MLP and CNN models are significantly better than the naive model when it comes to predicting energy curves, broadly reducing the error incurred in some cases. These models use information from the same session from the previous day and information from the previous session on the same day. By improving the naive procedure in this way, we have responded positively to the two research questions posed. Between these two models, at the α = 0.005 significance level, it is concluded that CNN performs better in the first five markets, while in the last one, the performances are similar. On the other hand, we observe that the LSTM and BiLSTM models give, by far, the worst results. The CNN+LSTM composite model, again, improves the results thanks to the inclusion of the convolutional layers. The Transformer model does not manage to improve on the naive model, except in a couple of markets.
Non-uniform point grids as an approximation to supply curves have proven effective in obtaining accurate predictions, thereby reducing the size of the objects handled as well as the computational time required. However, this aspect is one of the limitations of our study in the sense that the size of the grid implies a high dimension of the input tensor of the neural network models. Therefore, it would be interesting to study procedures that allow for reducing this dimension.
Another limitation that also relates to the dimensionality of the input features is that we have not taken into account meteorological variables that influence the availability of electricity produced through solar or wind technologies. Therefore, a possible extension of this work (maintaining the techniques used) could be to increase the amount of market information used for predictions, for example, meteorological variables such as temperature, solar radiation, precipitation, wind, etc., which affect both generators and consumers, could also be included.
Although this project has focused on predicting supply curves, both the preprocessing and predictive models can be used for demand curves as well. By doing so, an estimate of the energy price would be obtained by intersecting both curves. This will be the subject of future research.

Author Contributions

Conceptualization and methodology, G.V. and A.M.A.; software, validation, data curation and writing—original draft preparation, G.V.; writing—review and editing, supervision and project administration, A.M.A. All authors have read and agreed to the published version of the manuscript.

Funding

The second author acknowledges the partial funding of Ministerio de Ciencia e Innovación by Grants PID2022-138114NB-I00 and PID2023-151013NB-I00 funded by MCIN/AEI/10.13039/501100011033 and by FEDER/UE.

Institutional Review Board Statement

Not applicable.

Informed Consent Statement

Not applicable.

Data Availability Statement

The data used in this paper are available at https://www.omie.es/en/file-access-list and was accessed on 25 April 2024.

Acknowledgments

The authors thank www.energiaysociedad.es for allowing them to use and translate Figure 1 accessed on 6 September 2024. Of course, any errors that may exist are our responsibility, and www.energiaysociedad.es has no financial interest or personal relationship that could have influenced the work reported in this paper.

Conflicts of Interest

The authors declare no conflicts of interest. The funders had no role in the design of the study; in the collection, analyses, or interpretation of data; in the writing of the manuscript; or in the decision to publish the results.

Abbreviations

The following abbreviations are used in this manuscript:
BiLSTMBidirectional long short-term memory
CNNConvolutional neural network
EPEXEuropean power exchange
LSTMLong short-term memory
MADMedian absolute deviation
MIBELMercado Iberico de Electricidad (Iberian Electricity Market)
MLPMultilayer perceptron
OMIEOperador del Mercado Ibérico de Energía (Iberian Energy Market Operator)
SDStandard deviation

Appendix A. Selected Hyperparameters

In this appendix, we present the selected combinations of hyperparameters for each combination of market and model, as well as the average error using the d K distance on the validation set for each selection.
Table A1. Selected hyperparameters for the MLP model.
Table A1. Selected hyperparameters for the MLP model.
Marketbest_meanbest_epochbest_nbest_neuronbest_actbest_batch
1st153,721.7203200relu3
2nd121,656.5203400relu3
3rd107,365.2203200relu3
4th97,758.4201100relu3
5th66,961.5204100relu3
6th67,873.2203100relu3
Table A2. Selected hyperparameters for the CNN model.
Table A2. Selected hyperparameters for the CNN model.
Marketbest_meanbest_epochbest_n_densebest_n_convbest_filbest_kernelbest_neuron
1st159,051502116750
2nd117,692502185100
3rd95,489.61001385100
4th89,170.11001383100
5th58,594.21002185100
6th65,483.350338750
Table A3. Selected hyperparameters for the LSTM model.
Table A3. Selected hyperparameters for the LSTM model.
Marketbest_meanbest_n_LSTMbest_n_densebest_unitbest_neuronbest_dropout
1st163,6481420400.2
2nd147,15312101000.2
3rd133,2671120500
4th125,86513101000
5th102,703111001000
6th101,21212100400
Table A4. Selected hyperparameters for the BiLSTM model.
Table A4. Selected hyperparameters for the BiLSTM model.
Marketbest_meanbest_n_LSTMbest_n_densebest_unitbest_neuronbest_dropout
1st168,03614501000
2nd137,0461310400.1
3rd134,9131320400
4th120,81912101000.1
5th93,953.114501000
6th93,598.414101000.1
Table A5. Selected hyperparameters for the CNN+LSTM model.
Table A5. Selected hyperparameters for the CNN+LSTM model.
Marketbest_meanbest_n_CNNbest_n_LSTMbest_n_densebest_filterbest_kernelbest_unitbest_dropoutbest_neuron
1st214,79521283200.250
2nd194,5542248510005
3rd187,18121487200.110
4th164,05622483200.210
5th138,093113165200.220
6th125,49511416310010
Table A6. Selected hyperparameters for the Transformer model.
Table A6. Selected hyperparameters for the Transformer model.
Marketbest_meanbest_epochbest_n_densebest_n_transbest_headbest_dimbest_dropoutbest_neuron
1st210,97850318100.1200
2nd196,38450338200200
3rd185,16750338100.2200
4th163,81950328500200
5th139,12150338500.1200
6th126,29550318100200

References

  1. Jefatura del Estado. Law 54/1997, of November 27, of the Electrical Sector. 1997. Available online: https://www.boe.es/buscar/pdf/1997/BOE-A-1997-25340-consolidado.pdf (accessed on 7 September 2024). (In Spanish).
  2. Jefatura del Estado. Law 24/2013, of December 26, of the Electric Sector. 2012. Available online: https://www.boe.es/buscar/pdf/2013/BOE-A-2013-13645-consolidado.pdf (accessed on 6 September 2024). (In Spanish).
  3. Agosti, L.; Padilla, A.J.; Requejo, A. El mercado de generación eléctrica en España: Estructura, funcionamiento y resultados. Econ. Ind. 2007, 364, 21–37. [Google Scholar]
  4. The Spanish Electricity Market. Available online: https://www.energigreen.com/mercado-electrico-espanol/ (accessed on 9 September 2024). (In Spanish).
  5. Energía-y-Sociedad. The Process of Liberalization and Separation of Regulated Activities. 2023. Available online: https://www.energiaysociedad.es/manual-de-la-energia/4-1-el-proceso-de-liberalizacion-y-separacion-de-actividades-reguladas/ (accessed on 6 September 2024). (In Spanish).
  6. Operador del Mercado Ibérico de Energía. Daily Market Operation. Available online: https://www.omie.es/sites/default/files/inline-files/mercado_diario.pdf (accessed on 6 September 2024).
  7. Operador del Mercado Ibérico de Energía. Details of How the Intraday Market Works. Available online: https://www.omie.es/sites/default/files/inline-files/mercados_intradiario_y_continuo.pdf (accessed on 6 September 2024). (In Spanish).
  8. Nowotarski, J.; Weron, R. Recent advances in electricity price forecasting: A review of probabilistic forecasting. Renew. Sustain. Energy Rev. 2018, 81, 1548–1568. [Google Scholar] [CrossRef]
  9. Hong, T.; Pinson, P.; Wang, Y.; Weron, R.; Yang, D.; Zareipour, H. Energy Forecasting: A Review and Outlook. IEEE Open Access J. Power Energy 2020, 7, 376–388. [Google Scholar] [CrossRef]
  10. Lago, J.; Marcjasz, G.; De Schutter, B.; Weron, R. Forecasting day-ahead electricity prices: A review of state-of-the-art algorithms, best practices and an open-access benchmark. Appl. Energy 2021, 293, 116983. [Google Scholar] [CrossRef]
  11. Ziel, F.; Steinert, R. Electricity price forecasting using sale and purchase curves: The X-Model. Energy Econ. 2016, 59, 435–454. [Google Scholar] [CrossRef]
  12. Aneiros, G.; Vilar, J.M.; Cao, R.; Muñoz San Roque, A. Functional Prediction for the Residual Demand in Electricity Spot Markets. IEEE Trans. Power Syst. 2013, 28, 4201–4208. [Google Scholar] [CrossRef]
  13. Kulakov, S. X-Model: Further Development and Possible Modifications. Forecasting 2020, 2, 20–35. [Google Scholar] [CrossRef]
  14. Shah, I.; Lisi, F. Forecasting of electricity price through a functional prediction of sale and purchase curves. J. Forecast. 2020, 39, 242–259. [Google Scholar] [CrossRef]
  15. Soloviova, M.; Vargiolu, T. Efficient Representation of Supply and Demand Curves on Day-Ahead Electricity Markets. J. Energy Mark. 2021, 14, 99–126. [Google Scholar] [CrossRef]
  16. Pinhão, M.; Fonseca, M.; Covas, R. Electricity Spot Price Forecast by Modelling Supply and Demand Curve. Mathematics 2022, 10, 2012. [Google Scholar] [CrossRef]
  17. Mestre, G.; Sánchez-Úbeda, E.F.; Muñoz San Roque, A.; Alonso, E. The arithmetic of stepwise offer curves. Energy 2022, 239, 122444. [Google Scholar] [CrossRef]
  18. Foronda-Pascual, D.; Alonso, A.M. Prediction of Matching Prices in Electricity Markets through Curve Representation. Energies 2023, 16, 7812. [Google Scholar] [CrossRef]
  19. Li, Z.; Alonso, A.M.; Elías, A.; Morales, J.M. Clustering and forecasting of day-ahead electricity supply curves using a market-based distance. Int. J. Electr. Power Energy Syst. 2024, 58, 109977. [Google Scholar] [CrossRef]
  20. European Union. Overview of European Electricity Markets. 2016. Available online: https://energy.ec.europa.eu/system/files/2017-08/overview_of_european_electricity_markets_0.pdf (accessed on 1 October 2024).
  21. Liu, J.; Wang, J.; Cardinal, J. Evolution and reform of UK electricity market. Renew. Sustain. Energy Rev. 2022, 161, 112317. [Google Scholar] [CrossRef]
  22. Comisión Nacional de los Mercados y la Competencia. Resolution of May 6, 2021, of the National Commission of Markets and Competition, Approving the Operating Rules of the Daily and Intraday Electricity Markets for Their Adaptation of the Supply Limits to the European Matching Limits. 2021. Available online: https://www.boe.es/boe/dias/2021/05/20/pdfs/BOE-A-2021-8362.pdf (accessed on 6 September 2024). (In Spanish).
  23. Operador del Mercado Ibérico de Energía. Evolution of the Electricity Market. Annual Report. 2023. Available online: https://www.omie.es/sites/default/files/2023-02/Informe Anual 2022 ESP.pdf (accessed on 6 September 2024). (In Spanish).
  24. Real Observatorio de la Armada. Official Time Changes in Spain Since 1918. Available online: https://armada.defensa.gob.es (accessed on 6 September 2024). (In Spanish).
  25. Diebold, F.X.; Mariano, R.S. Comparing predictive accuracy. J. Bus. Econ. Stat. 1995, 20, 253–263. [Google Scholar] [CrossRef]
  26. Harvey, D.; Leybourne, S.; Newbold, P. Testing the equality of prediction mean squared errors. Int. J. Forecast. 1997, 13, 281–291. [Google Scholar] [CrossRef]
  27. Hyndman, R.; Athanasopoulos, G.; Bergmeir, C.; Caceres, G.; Chhay, L.; O’Hara-Wild, M.; Petropoulos, F.; Razbash, S.; Wang, E.; Yasmeen, F. Forecast: Forecasting Functions for Time Series and Linear Models; R Package Version 8.23.0; The R Foundation: Indianapolis, IN, USA, 2024. [Google Scholar]
  28. Alpaydin, E. Multilayer Perceptrons. In Introduction to Machine Learning; MIT Press: Cambridge, MA, USA, 2014; pp. 267–316. [Google Scholar]
  29. Afzal, S.; Ziapour, B.M.; Shokri, A.; Shakibi, H.; Sobhani, B. Building energy consumption prediction using multilayer perceptron neural network-assisted models; comparison of different optimization algorithms. Energy 2023, 282, 128446. [Google Scholar] [CrossRef]
  30. O’Shea, K.; Nash, R. An Introduction to Convolutional Neural Networks. arXiv 2015, arXiv:1511.08458. [Google Scholar]
  31. Hu, H.; Gong, S.; Taheri, B. Energy demand forecasting using convolutional neural network and modified war strategy optimization algorithm. Heliyon 2024, 10, e27353. [Google Scholar] [CrossRef]
  32. Staudemeyer, R.C.; Morris, E.R. Understanding LSTM—A tutorial into Long Short-Term Memory Recurrent Neural Networks. arXiv 2019, arXiv:1909.09586. [Google Scholar]
  33. Peng, L.; Wang, L.; Xia, D.; Gao, Q. Effective energy consumption forecasting using empirical wavelet transform and long short-term memory. Energy 2022, 238, 121756. [Google Scholar] [CrossRef]
  34. da Silva, D.G.; de Moura Meneses, A.A. Comparing Long Short-Term Memory (LSTM) and bidirectional LSTM deep neural networks for power consumption prediction. Energy Rep. 2023, 10, 3315–3334. [Google Scholar] [CrossRef]
  35. Vaswani, A.; Shazeer, N.; Parmar, N.; Uszkoreit, J.; Jones, L.; Gomez, A.N.; Kaiser, L.; Polosukhin, I. Attention Is All You Need. arXiv 2023, arXiv:1706.03762. [Google Scholar]
  36. Chan, J.W.; Yeo, C.K. A Transformer based approach to electricity load forecasting. Electr. J. 2024, 37, 107370. [Google Scholar] [CrossRef]
  37. Benjamin, D.; Berger, J.O.; Johannesson, M.; Nosek, B.A.; Wagenmakers, E.J.; Berk, R.; Bollen, K.A.; Brown, L.; Camerer, C. Redefine statistical significance. Nat. Hum. Behav. 2018, 2, 6–10. [Google Scholar] [CrossRef]
Figure 1. Structure of the Spanish electricity sector. Source: https://www.energiaysociedad.es [5], accessed on 6 September 2024.
Figure 1. Structure of the Spanish electricity sector. Source: https://www.energiaysociedad.es [5], accessed on 6 September 2024.
Applsci 14 10663 g001
Figure 2. Comparison between the uniform (left) and non-uniform (right) grids.
Figure 2. Comparison between the uniform (left) and non-uniform (right) grids.
Applsci 14 10663 g002
Figure 3. Zoomed comparison between the uniform (left) and non-uniform (right) grids.
Figure 3. Zoomed comparison between the uniform (left) and non-uniform (right) grids.
Applsci 14 10663 g003
Figure 4. Comparison between predicted and corrected curves.
Figure 4. Comparison between predicted and corrected curves.
Applsci 14 10663 g004
Figure 5. Boxplot of prediction errors using the naive, MLP, and CNN models.
Figure 5. Boxplot of prediction errors using the naive, MLP, and CNN models.
Applsci 14 10663 g005
Table 1. Schedules and horizons of intraday markets. Information available at: https://www.omies.es [7], accessed on 6 September 2024.
Table 1. Schedules and horizons of intraday markets. Information available at: https://www.omies.es [7], accessed on 6 September 2024.
1st Session2nd Session3rd Session4th Session5th Session6th Session
Market opening14:00 D-117:00 D-121:00 D-11:00 D4:00 D9:00 D
Market close15:00 D-117:50 D-121:50 D-11:50 D4:50 D9:50 D
Matching15:00 D-117:50 D-121:50 D-11:50 D4:50 D9:50 D
PIBCA program publication15:07 D-117:57 D-121:57 D-11:57 D4:57 D9:57 D
PHF publication of the OSs16:20 D-118:20 D-122:20 D-12:20 D5:20 D10:20 D
Market horizon24 h28 h24 h20 h17 h12 h
(Time period)(1–24 D)(21–24 D-1 & 1–24 D)(1–24 D)(5–24 D)(8–24 D)(13–24 D)
Table 2. Example of raw data format. Source: OMIE, accessed on 25 April 2024.
Table 2. Example of raw data format. Source: OMIE, accessed on 25 April 2024.
HourDateCountryUnitOffer TypeBuy/Sell EnergyBuy/Sell PriceOffered/ Matched
101/01/2020MIENDEC04C22.0180.30O
101/01/2020MIENDE01C1237.7180.30O
101/01/2020MIEE21C01C1434.7180.30O
Table 3. Summary statistics of the prediction error with the naive model.
Table 3. Summary statistics of the prediction error with the naive model.
MarketMeanMedianSDMAD
1st161,035119,650144,77257,635
2nd201,648153,984170,17282,586
3rd137,397101,724128,09050,949
4th190,072149,545155,44977,801
5th198,397157,803158,88184,706
6th117,83288,306101,66944,601
Table 4. Summary statistics of the prediction error with the MLP model.
Table 4. Summary statistics of the prediction error with the MLP model.
MarketMeanMedianSDMAD
1st182,371142,978140,95667,747
2nd126,912101,13191,37142,882
3rd106,28185,49774,00331,410
4th99,13679,45269,45730,375
5th71,91357,08454,57222,910
6th75,03061,62350,30524,885
Table 5. Summary statistics of the prediction error with the CNN model.
Table 5. Summary statistics of the prediction error with the CNN model.
MarketMeanMedianSDMAD
1st157,291121,796120,66553,156
2nd119,82797,03388,84739,610
3rd88,95371,18466,07926,554
4th85,01268,36061,34527,868
5th60,33246,47448,76517,705
6th77,02464,68350,50125,960
Table 6. Summary statistics of the prediction error with the LSTM model.
Table 6. Summary statistics of the prediction error with the LSTM model.
MarketMeanMedianSDMAD
1st807,905631,225525,548241,955
2nd454,070438,301207,141115,938
3rd493,333407,004299,729120,577
4th305,885284,560142,27577,029
5th621,313507,990408,766177,791
6th369,563325,991185,80186,222
Table 7. Summary statistics of the prediction error with the BiLSTM model.
Table 7. Summary statistics of the prediction error with the BiLSTM model.
MarketMeanMedianSDMAD
1st9,949,3207,113,8208,181,7403,309,050
2nd1,335,310509,8531,676,470243,729
3rd396,317368,620163,94980,360
4th363,259346,863189,97495,969
5th318,561298,485156,22278,313
6th4,114,8603,600,9202,997,6201,386,870
Table 8. Summary statistics of the prediction error with the CNN+LSTM model.
Table 8. Summary statistics of the prediction error with the CNN+LSTM model.
MarketMeanMedianSDMAD
1st237,219192,560165,77473,009
2nd270,741238,881190,208105,736
3rd224,195187,946153,89874,907
4th199,779164,432142,61867,457
5th178,912144,792132,74061,505
6th180,031158,938129,83674,575
Table 9. Summary statistics of the prediction error with the Transformer Model.
Table 9. Summary statistics of the prediction error with the Transformer Model.
MarketMeanMedianSDMAD
1st202,487157,074146,24047,723
2nd236,436192,165168,99974,396
3rd203,799164,773146,34555,942
4th182,406146,881132,73755,306
5th161,450129,051116,12643,136
6th143,626120,65598,66741,839
Table 10. Comparison of the mean prediction errors using the d K measure.
Table 10. Comparison of the mean prediction errors using the d K measure.
MarketNaiveMLPCNNLSTMBiLSTMCNN+LSTMTransformer
1st161,035182,371157,291807,9059.94932 × 106237,219202,487
2nd201,648126,912119,827454,0701.33531 × 106270,741236,436
3rd137,397106,28188,953.2493,333396,317224,195203,799
4th190,07299,136.685,012.3305,885363,259199,779182,406
5th198,39771,913.860,331.9621,313318,561178,912161,450
6th117,83275,030.577,023.6369,5634.11486 × 106180,031143,626
The cells highlighted in red, green, and blue denote the three best-performing models.
Table 11. The results of the Diebold–Mariano test for the comparison of the naive and MLP models.
Table 11. The results of the Diebold–Mariano test for the comparison of the naive and MLP models.
MarketDMp-Value
1st−4.9711≪0.005
2nd31.9851≪0.005
3rd17.5485≪0.005
4th32.7746≪0.005
5th46.5074≪0.005
6th19.0330≪0.005
Table 12. The results of the Diebold–Mariano test for the comparison of the naive and CNN models.
Table 12. The results of the Diebold–Mariano test for the comparison of the naive and CNN models.
MarketDMp-Value
1st6.1157≪0.005
2nd34.4745≪0.005
3rd21.8768≪0.005
4th34.0464≪0.005
5th47.9174≪0.005
6th18.4540≪0.005
Table 13. The results of the Diebold–Mariano test for the comparison of the MLP and CNN models.
Table 13. The results of the Diebold–Mariano test for the comparison of the MLP and CNN models.
MarketDMp-Value
1st34.2805≪0.005
2nd6.7702≪0.005
3rd12.7954≪0.005
4th16.5296≪0.005
5th22.0421≪0.005
6th−1.98500.0239
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Vivó, G.; Alonso, A.M. Prediction of Intraday Electricity Supply Curves. Appl. Sci. 2024, 14, 10663. https://doi.org/10.3390/app142210663

AMA Style

Vivó G, Alonso AM. Prediction of Intraday Electricity Supply Curves. Applied Sciences. 2024; 14(22):10663. https://doi.org/10.3390/app142210663

Chicago/Turabian Style

Vivó, Guillermo, and Andrés M. Alonso. 2024. "Prediction of Intraday Electricity Supply Curves" Applied Sciences 14, no. 22: 10663. https://doi.org/10.3390/app142210663

APA Style

Vivó, G., & Alonso, A. M. (2024). Prediction of Intraday Electricity Supply Curves. Applied Sciences, 14(22), 10663. https://doi.org/10.3390/app142210663

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop