Weiming-Hu / AnalogsEnsemble

The C++ and R packages for parallel ensemble forecasts using Analog Ensemble
https://weiming-hu.github.io/AnalogsEnsemble/
MIT License
18 stars 5 forks source link

Different results from RAnEn when subseting stations #36

Closed Weiming-Hu closed 5 years ago

Weiming-Hu commented 5 years ago

When IS is used, AnEn on stations should be independent of each other. However, when computing a portion of the stations, the results for these stations are not the same from when computing all stations at once.

For example, the left three columns come from computing all stations, and the right 3 columns are from computing partial stations. This might be caused by dealing with NA values.

> cbind(AnEn.all$similarity[5, 2, 3, order(AnEn.all$similarity[5, 2, 3, , 3]), ], AnEn$similarity[5, 2, 3, order(AnEn$similarity[5, 2, 3, ,3]),])[1:20, ]
          [,1] [,2] [,3]     [,4] [,5] [,6]
 [1,]      NaN    5    1      NaN    5    1
 [2,] 7.212896    5    2      NaN    5    2
 [3,] 2.776645    5    3      NaN    5    3
 [4,]      NaN    5    4      NaN    5    4
 [5,] 3.268617    5    5 3.268617    5    5
 [6,] 1.744200    5    6 1.744200    5    6
 [7,] 4.941840    5    7 4.941840    5    7
 [8,] 4.340009    5    8 4.340009    5    8
 [9,]      NaN    5    9 3.855888    5    9
[10,]      NaN    5   10 5.344926    5   10
[11,] 5.490306    5   11 5.490306    5   11
[12,] 3.994862    5   12 3.994862    5   12
[13,] 3.262656    5   13      NaN    5   13
[14,] 3.588668    5   14      NaN    5   14
[15,]      NaN    5   15      NaN    5   15
[16,]      NaN    5   16      NaN    5   16
[17,] 3.961612    5   17      NaN    5   17
[18,] 3.799170    5   18      NaN    5   18
[19,] 3.386876    5   19      NaN    5   19
[20,] 4.393606    5   20      NaN    5   20
Weiming-Hu commented 5 years ago

False alarm. This is caused by a bug in the configuration.

Weiming-Hu commented 5 years ago

But I still wonder why RAnEn behavers like this.

Weiming-Hu commented 5 years ago

This has been resolved in the commit b0375d0af940fe0dc51e2e5329313e76fa7c5ce3. The observation stations are assumed to be the same with search forecast station which creates problems.