Skip to content

Loading daily data

Hi @vagudets,

I've identified an issue with the Loading of daily data at seasonal timescales. For example, if I ask for the February start date and forecast times from 1 to 3, I load the data for these dates:

 data$fcst$attrs$Dates
 [1] "2025-02-02 UTC" "2025-02-03 UTC" "2025-02-04 UTC" "2025-02-05 UTC"
 [5] "2025-02-06 UTC" "2025-02-07 UTC" "2025-02-08 UTC" "2025-02-09 UTC"
 [9] "2025-02-10 UTC" "2025-02-11 UTC" "2025-02-12 UTC" "2025-02-13 UTC"
[13] "2025-02-14 UTC" "2025-02-15 UTC" "2025-02-16 UTC" "2025-02-17 UTC"
[17] "2025-02-18 UTC" "2025-02-19 UTC" "2025-02-20 UTC" "2025-02-21 UTC"
[21] "2025-02-22 UTC" "2025-02-23 UTC" "2025-02-24 UTC" "2025-02-25 UTC"
[25] "2025-02-26 UTC" "2025-02-27 UTC" "2025-02-28 UTC" "2025-03-01 UTC"
[29] "2025-03-02 UTC" "2025-03-03 UTC" "2025-03-04 UTC" "2025-03-05 UTC"
[33] "2025-03-06 UTC" "2025-03-07 UTC" "2025-03-08 UTC" "2025-03-09 UTC"
[37] "2025-03-10 UTC" "2025-03-11 UTC" "2025-03-12 UTC" "2025-03-13 UTC"
[41] "2025-03-14 UTC" "2025-03-15 UTC" "2025-03-16 UTC" "2025-03-17 UTC"
[45] "2025-03-18 UTC" "2025-03-19 UTC" "2025-03-20 UTC" "2025-03-21 UTC"
[49] "2025-03-22 UTC" "2025-03-23 UTC" "2025-03-24 UTC" "2025-03-25 UTC"
[53] "2025-03-26 UTC" "2025-03-27 UTC" "2025-03-28 UTC" "2025-03-29 UTC"
[57] "2025-03-30 UTC" "2025-03-31 UTC" "2025-04-01 UTC" "2025-04-02 UTC"
[61] "2025-04-03 UTC" "2025-04-04 UTC" "2025-04-05 UTC" "2025-04-06 UTC"
[65] "2025-04-07 UTC" "2025-04-08 UTC" "2025-04-09 UTC" "2025-04-10 UTC"
[69] "2025-04-11 UTC" "2025-04-12 UTC" "2025-04-13 UTC" "2025-04-14 UTC"
[73] "2025-04-15 UTC" "2025-04-16 UTC" "2025-04-17 UTC" "2025-04-18 UTC"
[77] "2025-04-19 UTC" "2025-04-20 UTC" "2025-04-21 UTC" "2025-04-22 UTC"
[81] "2025-04-23 UTC" "2025-04-24 UTC" "2025-04-25 UTC" "2025-04-26 UTC"
[85] "2025-04-27 UTC" "2025-04-28 UTC" "2025-04-29 UTC" "2025-04-30 UTC"
[89] "2025-05-01 UTC"

These are the dates that appear in the files, but I need them to compute monthly indicators (I'm adding the specific code in the dev-aspect branch).

If I want to do the monthly aggregation, I will use this code to select which days belong to each month:

months <- month(data$fcst$attrs$Dates)
> months
 [1] 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 3 3 3 3 3 3 3 3 3 3 3
[39] 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4
[77] 4 4 4 4 4 4 4 4 4 4 4 4 5

This will lead to an indicator that will be based on only one value for the last time step, which does not make any sense.

I don't know if the solution is to adjust the Loading in SUNSET or to shift the dates in the files, but I think this approach could lead to some problems.

Please, let me know if you want to discuss this further.

Cheers,

Verónica

@pabretonniere @nperez

Edited by Verónica Torralba-Fernández