Canary tomato export prices: comparison and relationships between daily seasonal patterns

Statistical procedures are proposed to describe, compare and forecast the behaviour of seasonal variations in two daily price series of Canary tomato exported to German and British markets, respectively, over the last decade. These seasonal patterns are pseudo-periodic as the length of the seasonal period changes frequently in dependence of market conditions. Seasonal effect at a day in the harvesting period is defined as a spline function of the proportion of the length of such a period elapsed up to such a day. Then, seasonal patterns for the two series are compared in terms of the area between the corresponding spline functions. The ability of these models to capture the dynamic process of change in the seasonal pattern is useful to forecasting purpose. Furthermore, an analytical tool is also proposed to obtain forecasts of the seasonal pattern in one of these two series from the forecasts of the seasonal pattern in the other one. These procedures are useful for farmers in developing strategies related to the seasonal distribution of tomato production exported to each market.

supply and demand.Demand may be not so seasonal in some cases.However, when production is affected by climatic factors and storage is costly, prices tend to exhibit strong seasonal variations.This is especially the case for perishable commodities such as fruits and vegetables in low-income countries (Amikuzuno & Von Cramon-Taubadel, 2012), but also in the European countries2 .
On the other hand, such variability increases as data are more frequently sampled.Therefore, the shape of the seasonal pattern in daily series becomes more relevant than the values of the seasonal effects at different days.In that sense, smooth functions such as splines (Poirier, 1976;Eubank, 1988) are a suitable tool to deal with this type of seasonal patterns.
As Martín-Rodríguez & Cáceres-Hernández (2010, 2012) pointed out, spline functions are a useful tool to capture the pseudo-periodic movements in high frequency time series.Prices of the vegetables traded on the European markets over the year are only available for few days in those weeks in which the product is on the market, but the marketing period may change from year to year depending on factors such as weather or market dynamics.To forecast this type of data, conventional approaches3 have serious difficulties4 .However, if the seasonal pattern is regular, such that the seasonal effect at a point in time is assumed to depend on the proportion of the whole seasonal period at this point in time, the seasonal component can be formulated as a function of such a proportion, that takes values into the continuous interval (0,1).Then, a parametric formulation such as the so called Restricted Evolving Spline Model (RESM), developed by Martín-Rodríguez & Cáceres-Hernández (2012), is a useful tool to model and forecast pseudo-periodic seasonal patterns.
The heterogeneity of the seasonal patterns in daily series is less pronounced in weekly data and goes unnoticed when lower frequency data are analyzed.To the best of authors' knowledge, as well as the paper by Martín-Rodríguez & Cáceres-Hernández (2012), few papers have explicitly dealt with seasonal effects in weekly agricultural prices (Steen & Gjolberg, 1999;Sorensen, 2002).Miller & Hayenga (2001), Campenhout (2007), Cruz & Ameneiro (2007), Motamed et al. (2008), Bakucs et al. (2012), Emmanouilides & Fousekis (2012) and Esposti & Listorti (2013) investigate weekly agricultural price transmission, but seasonal variation is assumed to be fixed, removed or ignored.The analysis of the law of one price by Rumánková (2012) is based on biweekly data, but seasonal movements are omitted.Amikuzuno & von Cramon-Taubadel (2012) and Stephens et al. (2012) apply vector error correction models to semiweekly wholesale tomato prices.In both of these two papers, the analysis is performed under two regimes corresponding to different periods into the year, but the seasonal pattern is not taken into account.The complexity of these seasonal patterns is the key factor in the scarcity of papers on this issue.
Following the RESM framework, the goal of this paper is to develop statistical procedures to compare and forecast seasonal patterns in daily price series of Canary tomatoes.To this aim, analytical tools are provided to: a) show the evolution of the seasonal patterns in agricultural prices over time and compare seasonal patterns for a series in different harvesting periods or, also, for different series in the same harvesting period, and b) identify linear relationships between the parameters driving changes in the seasonal patterns for two different series and forecast the seasonal pattern in one of this two series from the forecasting of the seasonal pattern in the other one.

Material and methods
This section is organized into two parts.In the first, singularities in daily price series of Canary tomato are emphasized to show that conventional approaches are not suitable to deal with them.In the second part, the elements of the statistical methodology proposed in this paper are presented.

Daily series of Canary tomato prices
Daily price series of Canary tomato in British and German wholesale markets between 1999/2000 and 2010/2011 harvests are analyzed in order to discover essential features in seasonal variations.Daily data have been calculated as averages of daily prices for the 6 kg box of round tomato in different wholesale markets provided by the national organism Secretaría General de Comercio Exterior del Ministerio de Industria, Turismo y Comercio del Gobierno de España.Tomato prices in 2011/2012 harvest are employed to test the forecasting performance of the models.
As commented, tomatoes are not usually exported for some weeks, especially during the summer period.However, the length of the harvest has evolved over time.Since the relevant seasonal variation is defined during the marketing period, missing values located in the summer period have been deleted.Furthermore, prices are available for only one of the markets in some periods, but it is hard to believe that Canary tomatoes are not exported to both of the two markets during these weeks.Because of that, a common export period is assumed for the two series in the same harvest.
For each week inside the export period, prices are only available for some days from Monday to Friday.So, missing data are always present.However, whatever the number of observations, the length of the seasonal period s c in harvest c has been calculated by assuming that there are five seasons (days) per week.Thus, two price series are obtained and are referred to as {p t AL } t=1,…,2020 and {p t RU } t=1,…,2020 for Germany and the UK, respectively (Fig. 1).
Noticeable parallel movements are observed for both of the series in the long term behaviour, as shown in the respective series of moving averages with period corresponding to observations at a seasonal period whose length is s c (Fig. 1).Such moving averages tend to be higher in German markets, as expected to compensate for the difference in transportation costs5 .According to the long term movement, there is not a tendency for an increase in prices, but noticeable oscillations are observed in the short time.As shown in Table 1, minimum prices are usually observed near the beginning or the end of the harvest, although the lowest price in some harvests is located in weeks near the end or the beginning of the year.Maximum prices are registered in the same week or in weeks near each other in both markets for most of the harvests.On the other hand, the sign of deviations from moving averages seems to be always the same for both of the series.In spite of that, the noisy behaviour in price series makes hard to find interesting analogies in seasonal variations.Furthermore, as shown in Table 1, the length of the seasonal period does not remain the same over the sample and the number of observations makes clear that prices are sparsely and irregularly observed.Therefore, the methodology proposed in the following section is more suitable than conventional approaches.

Comparison and forecasting of seasonal patterns
Statistical procedures to compare and forecast seasonal patterns in agricultural price series are proposed in this section inside the RESM framework adapted to the daily case.The seasonal variation in a daily price series, γ t , is assumed to be completed in each one of the m harvests over the sample.Let s c be the number  of days of harvest c, c = 1,…,m, and let γ t be defined as γ t = γ c,w if the observation at time t and harvest c corresponds to day j c in such a way that the proportion of the seasonal period elapsed up to day j c is , Then, the RESM formulation is built in four phases.
Firstly, an evolving periodic cubic spline is formulated to capture changes in the shape of the seasonal pattern over time, in such a way that , [1] where , c = 1,…,m, and ξ t is a residual term.If the observation at time t and harvest c corresponds to day j c in such a way that , the seasonal effect at this proportion of the seasonal period can be defined as a periodic cubic spline g c (w) expressed as , [2] where X γ c,0,w ,…,X γ c,k,w are functions of the proportion w and the break points wi, i = 0,…,k, of the spline that describes the seasonal pattern in harvest c, and γ c,w 0 ,…,γ c,w k are free parameters to be estimated 6 .Secondly, the estimates {γ c,w i } c=1,…,m , i = 0,…,k, can be expressed as a non periodic cubic spline defined as , [3] where Y γ i,0,c ,…,Y γ i,r,c are functions of harvest c and break points c i,j = c j , j = 0,1,…,r, and γ i,0 ,…,γ i,r are free parameters to be estimated, which represent the seasonal effects at the proportion w i of the seasonal period in harvests c 0 ,c 1 ,…,c r .Thirdly, the seasonal pattern can be modelled as a function of parameters {γ i,0 ,…,γ i,r } i=0,…,k-1 , as follows: where , i = 0,…,k, j = 0,…,r, and η t is a residual term.Finally, the parametric formulation developed in the second phase provides forecasts of seasonal effects at the break points, {γ m+h,w i } h=1 ,…, i = 0,…,k.Then, the forecasts of the seasonal pattern h harvests ahead are obtained as where X γ m+h,0,w ,…,X γ m+h,k,w are regressors def ined as indicated in first phase.Note that the model captures the dynamic process of change in the shape of the seasonal pattern.Therefore the procedure is reliable to make forecasts of such changes in coming harvests.
Once the basic procedure has been explained, the following sections deal with the proposal of statistical indicators to compare and forecast seasonal patterns in daily agricultural prices.

Comparison of seasonal patterns
One of the most interesting topics in the analysis of this type of series is to assess if seasonal effects are an increasing part of the variation in the series.However, when the observed seasonal effects correspond to different seasons in different harvests, conventional models are too rigid to this assessment.The comparison of seasonal effects at the same day of the year in different harvests is not always possible and, above all, conclusions about similarities between seasonal patterns in different harvests should not be based only on sesonal effects at days in which such a comparison can be done.From this point of view, the definition of seasonal effect at a day as a function of the proportion of the seasonal period overcomes this drawback as the length of the seasonal period for each harvest is rescaled to be the unit interval.Let the curved line in Fig. 2a be seasonal pattern in harvest c modelled by a spline function.Then, the magnitude of seasonal variations in this harvest is measured as the shadow area M under the spline, computed as the sum of the absolute values of the integrals of the spline function for each interval between two consecutive intersections of the spline with the horizontal axis at proportions L q-1 and L q .That is to say, , [5] where L 0 = w 0 = 0, L l = w k = 1 and g c (L q ) = 0, q = 1,…,l -1.In a similar sense, seasonal patterns can be compared for two prices series at the same harvest.Let the curved lines in Fig. 2b be the seasonal patterns in harvest c modelled by respective spline functions for two time series {x t } and {y t }.Then, the divergence between seasonal patterns for these two time series is calculated as the shadow area M * between the splines, computed as the sum of the absolute values of the integrals of the difference between splines for each interval between two consecutive intersections between them at proportions L * q-1 and L * q .That is to say, , where L * 0 = w0 = 0, L * l = w k = 1 and g e X (L * q ) = g c Y (L * q ), q = = 1,…,l * -1.In this way, the convergence or divergence between the seasonal patterns for two series can be observed from the evolution of such an area.

Relationships between seasonal patterns and conditioned forecasts
The RESM formulation provides forecasts of the seasonal pattern in a time series from its past behaviour.However, it might be also useful to obtain forecasts of the seasonal pattern in a time series from the past behaviour of the seasonal pattern observed in another time series.Let {x t } and {y t } be two time series, and let {γ X c,w i X } c=1,…,m and {γ Y c,w i Y } c=1,…,m be the estimates of corresponding seasonal effects at the break points w i X , i = 0,…,k, and w i Y , i = 0,…,k.Note that the number of break points is assumed to be equal for both of the two series, but locations are not enforced to be the same.Following the RESM procedure, forecasts of {γ X m+h,w i X } h=1,… and {γ Y m+h,w i Y } h=1,… can be obtained.However, seasonal patterns in daily price series might be related.Then, the seasonal effect γ Seasonal effect g(w) Seasonal effect g(w) 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 harvest c at the proportion corresponding to the break point w i X , might be assumed to be explained as a linear function of the seasonal effects {γ Y c,w i Y } i=0 ,…,k for series {y t } in the same harvest c at proportions corresponding to the break points {w i Y } i=0,…,k .That is to say, , [8] where ε i,c is a residual term.Therefore, forecasts of seasonal effects {γ X m+h,w i X } h=1,… can be obtained from the forecasts of seasonal effects {γ

Results
In this section, the results of applying the proposed methodology to daily series of Canary tomato prices are shown.An approximation to the seasonal effects needs to be obtained as the first step to model seasonal variations in terms of spline functions.In that sense, the deviations from the corresponding moving averages 7 , {γˆt AL,1 } t=1,…,2020 and {γˆt RU,1 } t=1,…,2020 , are previous estimates from which the number and locations of the break points are selected.The number of break points, assumed to belong to the set , is chosen so that the spline captures the main changes in the shape of the observed seasonal pattern, whereas the set of locations of these points is the one that minimizes the residual sum of squares when the model in Eq.
[1] is fitted to the previous approximation to the seasonal pattern 8 .From the results of estimating a parametric model in terms of Eq. [1] for each one of the series, new approaches to seasonal effects are obtained.Once these estimates are corrected in such a way that the area under the spline function is equal to zero over the unit interval corresponding to each harvest, new estimates {γˆt AL,2 } t=1,…,2020 and {γˆt RU,2 } t=1,…,2020 are obtained (Fig. 3a).Following the methodological section, the evolution of the seasonal effect at each one of the break points in the seasonal period has been modelled by means of a two-segment non-periodic cubic spline.When these constraints are enforced, a new formulation of the original evolving splines, in terms of Eq. [4], is obtained: where γ i,j is the seasonal effect at proportion w i in the seasonal period corresponding to harvest c j .These hypotheses about the seasonal pattern can be introduced into a structural model , [11] where µ t is a stochastic level, which captures the instabilities in the long term component.Note that one of the regressors U i,j,t is deleted to avoid multicollinearity problemas.The estimates of seasonal variations from the structural time series model, {γ ˆtAL,3 } t=1,…,2020 and {γˆt RU,3 } t=1,…,2020 (Fig. 3b), have been corrected in such a way that the area under the spline function over each harvest is equal to zero.The correction applied to the estimates of seasonal variation has been taken into account to correct the estimates of the stochastic level 9 .The estimates in Fig. 3b, γ ˆt 3 , show the direction in which the shape of the whole seasonal pattern is changing.However, when seasonal effects are calculated as functions of the proportion of the seasonal period (Fig. 4), a clearer and homogeneous comparison of seasonal 7 Due to the presence of missing values, and to avoid distortions in the approximation to the long term movement, moving averages have been calculated once missing data have been substituted by linear interpolations between adjacent observations.This criterion is based on the assumption that the seasonal pattern is regular, in such a way that the moving averages take the seasonal effects corresponding to all the days in the seasonal period into account. 8To estimate these models, the decision has been made to delete seasonal effects at days in which price is not observed, except when prices are not available for any day in a week.This being the case, an approximation to the seasonal effect at Wednesday in such a week has been calculated as the difference between the interpolated value employed to calculate the moving average and the resulting moving average at the same day.Note that, in this way, noticeable distortions are avoided in the shape of the seasonal patterns, which might go unnoticed until the final estimates of seasonal effects were obtained.The break points are finally located at the following proportions of the seasonal period: w 1 = 0.260, w 2 = 0.501, w 3 = 0.532, w 4 = 0.651, w 5 = 0.800 for prices in German markets; and w 1 = 0.311, w 2 = 0.553, w 3 = 0.557, w 4 = 0.561, w 5 = 0.788 for prices in the UK. 9 Impulse interventions have been included into the structural model at observations corresponding to wednesdays in weeks in which prices are not available for any day.Other intervention variables have been also useful to capture anomalous observations.patterns corresponding to consecutive harvests, or corresponding to different prices series at the same harvest, is obtained.In the same sense, the measures of the areas M and M * under and between the splines capturing the respective seasonal patterns are shown in Fig. 5.
These behaviours in seasonal patterns can also be explained from the estimates of seasonal effects at the break points into the seasonal period shown in Fig. 6.The parametric formulation of such an evolution of seasonal effects at break points over the sample is useful to forecast these seasonal effects in coming harvests.From these estimates, forecasts of the seasonal effect at each proportion of the seasonal period can be obtained.Fig. 7 shows the forecasts of seasonal effects at each proportion of the unit interval corresponding to the 2011/2012 harvest.For the price series in the UK, there are few observations corresponding to that harvest.In this case, Fig. 7 also shows the forecasting of the seasonal pattern obtained from the forecasting of the seasonal pattern for prices in Germany.
The forecasting of seasonal effects at specific days corresponding to some weeks in a year is conditioned by the assumptions about both the length of the seasonal period and the beginning week of the harvest.In the coming harvest, the beginning week and the length of the seasonal period are assumed to be the same as those observed in the 2010/2011 harvest.On the other hand, predicted values of the trend component are obtained according to the estimates of parameters of the third degree polynomial function for the last segment in a three-segment non-periodic cubic spline fitted to the stochastic level.Then, the price forecasts shown in Fig. 8 are also obtained as sums of trend and seasonal forecasts.

Discussion
The results in previous section highlight some salient features.In Germany and also in the UK, the beginning of harvests is progressively less remunerative, although such a trend seems to be stopped in the British markets for the last harvests.In a similar sense, the noticeable price drops at the end of the harvests at the beginning of the past decade has become much more moderate.Furthermore, the highest prices, located around the beginning of the last third of the harvest, are lower and lower, although these prices seem to be recovering in German markets during the last harvests (Fig. 4).The changes at the beginning and the end of the harvests are clearly driven by the evolution of the estimates of seasonal effects at the break points located at the extreme values of the unit interval, γˆ3 c,w 0 and γ ˆ3 c,w 6 , respectively (Fig. 6).
As regards the forecasting performance, both forecasts for seasonal effects in British markets, from the past behaviour of the own price series or from the frecasts for prices in German markets, are very close.On the other hand, the magnitude of the irregular component is strong in prices observed in the German markets, but forecasts capture the shape of the seasonal pattern over the harvest, whereas the short term variations are not relevant to make decisions such as planting dates or about the weeks in the export period.Unfortunately, the forecasting performance of the model for the prices in British markets can not be evaluated due to the scarcity of observations.However, the forecast based on the past behaviour of the own series is, as expected, very close to the other one conditioned by the forecasting of seasonal effects for prices in German markets.
A reflection about the European fresh tomato market is needed to explain the changes observed in seasonal behaviour of Canary tomato prices.As mentioned, the main destination of Canary tomato supply is the north of Europe.The demand for fresh tomatoes in these countries depends on a number of factors.Colour and taste are important to get high prices.The temperature also influences the attitude of consumers.However, the consumption is regulated by the import of tomatoes.Adverse climatic conditions have traditionally constrained the local production.Therefore, these countries depend heavily on imports to meet the domestic demand, particularly during the winter season.Obviously, tomato prices are conditioned by the local demand, but their variations are mainly related to the movements in a variety of supplies from different origins characterized by changing quantities and qualities.
In accordance, the peaks in Canary tomato prices at the beginning of the export harvest tend to disappear.
European consumers expect value for money and therefore they are willing to pay higher prices for Canary tomatoes when the market becomes short of local or third countries supplies.However, the differences in perceived quality between alternative origins have diminished and, although imports from different sources are imperfect substitutes, the total available supply is perceived as more homogeneous in quality and quantity over the year.Therefore, the magnitude of seasonal variations in tomato prices is expected to be reduced.
However, such seasonal effects have a noticeable impact on profitability due to the downward trend in   real average prices.The increase on the tomato supply from the southeast area in Spain and to a lesser extent from Morocco has brought about prices to stagnate in nominal terms, which means a diminishing of real revenues.On the other hand, the cultivation and marketing costs for Canary fruit are growing faster than revenues because Canary producers have turned from being price makers to price takers.In fact, notwithstanding the public aids, the reduction of profit margins during the last harvests has led to a drop in the cultivation surface and the export levels.Some decades ago, the Canary export level could be assumed as a key factor to determine prices at weeks in which the Canary market share was very relevant (see Cáceres, 2001).Nowadays it is hard to assume that the price behaviour is influenced by the seasonal pattern of Canary exports.However, when the seasonal pattern of tomato prices is taken into account, decisions about planting dates could be highly remunerative.In such a sense, the results about weekly prices obtained in this paper are useful.An association between these results and other published works (Amikuzuno & Von Cramon-Taubadel, 2012;Rumánková, 2012;Stephens et al., 2012) is hard to establish because, as commented, seasonal patterns in daily price series are not usually modelled.However, the description, comparison and forecasting of Canary tomato prices in alternative European markets to which exports are sent, provide a guide for Canary producers to make decisions.The long term movements show a narrow relationship between prices observed in the British market and the ones available for the European continental market.On the other hand, seasonal patterns do not seem to converge, but the highest prices are located around close periods of the harvest for both of the two series.This finding would suggest to make decisions about planting dates in such a way that enough fruit supply be obtained in such periods.However, the location of these periods near the end of the export period makes hard to synchronize highest supply periods and highest price periods.In fact, Canary growers are making decisions about stepped planting dates in some greenhouses in an attempt to take advantages from the most remmunerative price periods.In that sense, the identification of any divergence between highest price periods for both series would be worthwhile to adjust supply to demand in order to increase profitability.To make all of these decisions, there is a need to forecast price behaviour a long time beyond the observed period and the models proposed in this paper are a suitable tool to this aim.
From a methodological point of view, the adaptations to daily series proposed in this paper have shown to be useful to model and forecast seasonal patterns as heterogeneous as present in agricultural prices.Following the proposal by Martín-Rodríguez & Cáceres-Hernández (2010, 2012), the conventional definition of the seasonal effect at a point in time as a function of the season in which data is observed needs to be left aside.To deal with prices irregularly observed at specific days located into a changing period of the year, the seasonal period is defined as the unit interval and the seasonal effect at any point in such an interval is defined as a function of the corresponding proportion of the interval.In this way, seasonal effects at specific proportions corresponding to each one of the seasons can be obtained whatever the number of days in which the seasonal period is completed.
Furthermore, a noisy behaviour in daily prices makes hard to observe long term movements and, above all, seasonal variations, which are key elements in the decision making process of economic agents.From this point of view, spline functions allow the researcher to distinguish noisy variations from more regular seasonal fluctuations, and these parametric formulations are also flexible enough to capture evolving seasonal patterns.In this way, the estimates of the seasonal effects by means of the RESM formulation are not conditioned by the specific days in which data has been observed for each harvest.Notwithstanding, missing data may result in serious bias in estimates of seasonal effects by means of spline functions when a long period inside the harvest is not taken into account in the error criterion of the adjustment procedure.Although such distortions are softened by means of conditions that enforce the seasonal effects at specific break points in the harvest to evolve according to non periodic spline functions.
In spite of the singular characteristics of daily prices series, the analytical instruments developed in the methodological section have shown to be useful to assess both the evolution of pseudoperiodic seasonal patterns and the degree of dissimilarities between seasonal patterns in different daily price series.These tools make also feasible the forecasting of the seasonal pattern in a daily series in dependence of the forecasts of the seasonal pattern in another daily series.Therefore, the results of such procedures are useful to agricultural price analysis aimed to guide farmers in making better decisions on date of planting, seasonal distribution of supply or choice of destination markets.
to grow up slightly from 2006/2007 harvest.The divergencies in the seasonal behaviour of the price series have also reduced along the analyzed period.However, seasonal patterns are closest together in 2003/2004 har-

Figure 6 .
Figure 6.Estimates of seasonal effects at break points, γˆ3 c,w i .

Figure 7 .
Figure 7. Forecasts of seasonal effects at any proportion of the seasonal period (2011/2012 harvest).UK (Germany) denotes the forecasts of seasonal effects for prices in the UK obtained from the forecasting of the seasonal pattern for prices in Germany.

Figure 8 .
Figure 8. Forecasts of daily prices in Germany and the UK (2011/2012 harvest).Labels on the horizontal axis indicate the weeks of the year in which daily forecasts are obtained.Forecasts [UK (Germany)] denote the forecasts of prices in the UK obtained from the forecasting of prices in Germany.

Table 1 .
Exporting period, minimum and maximum prices (euros/box of 6 kg) by harvest