The difference between GASF (Gramian Angular Summation Field) and GADF (Gramian Angular Difference Field) lies in the way they encode the time series data into images. GASF is based on the cosine of the sum of angles, which captures the temporal correlation by considering the trigonometric sum between each point to identify the temporal correlation within different time intervals1. On the other hand, GADF is based on the sine of the difference of angles, which captures the changes in the time series data2.
Neither GASF nor GADF inherently loses more information than the other; they simply represent the time series data in different ways. GASF tends to preserve the trend of the time series, while GADF emphasizes the changes or differences. The choice between GASF and GADF depends on the specific application and what features of the time series are most important for the task at hand.
Regarding your question about X = np.array([x, y])
, this line of code is creating a two-dimensional NumPy array where x
and y
are individual time series data arrays. If x
and y
represent two different measurements over the same time intervals, then X
becomes a multivariate time series array. In this context, the X-axis of X
would still represent time, but now you have a two-dimensional array where each row corresponds to a different variable or measurement taken over time. Essentially, X
is a collection of time series, and each element X[i]
is a separate time series data set. This allows for the analysis of multivariate time series data, where you can observe and analyze the behavior of multiple variables over the same time period.