Clarification on Calibration time step in gamma_parameters for SPEI Computation #571
pramodadhikari
started this conversation in
General
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello,
I am currently using climate_indices module to compute the Standardized Precipitation-Evapotranspiration Index (SPEI) with downscaled GCM outputs for year 1980-2099.
While working with the module, I came across the gamma_parameters function in compute.py and had a question regarding the usage of calibration_start_year and calibration_end_year. Specifically, I wanted clarification on the calculation of calibration_values.
To provide context, I am working with a dataset formatted as (time, lat, lon) where the time axis contains monthly values for 119 years, resulting in 1428 time steps. My calibration period is 30 years (1980–2009). Based on this setup, my understanding is that since I have monthly data, the calibration_values should include 360-time steps (30 years × 12 months). This would imply that the slicing for calibration_values should be:
calibration_values = values[calibration_begin_index:calibration_end_index * 12, :]
However, I noticed in your code the slicing is defined as:
calibration_values = values[calibration_begin_index:calibration_end_index, :]
This seems to only account for 30-time steps instead of 360 (i.e. 12*30 years) in my case. Could you please clarify whether the current implementation is correct or if there may have been a misunderstanding on my part?
I greatly appreciate your insights and would be happy to provide further details about my dataset or approach if needed.
Beta Was this translation helpful? Give feedback.
All reactions