When creating a summary statistic (avg, median, etc) from a metric, need to be able to specify the ensemble number.
The metrics tables have an 'ensemble' column to use, which is a string/character column with leading zeros, same as the file name from Dr. Kounta's matlab files. the ensemble column has strings like 001, 002, ...010
when creating SQL in duckdb to limit to select ensembles (1, 3, 5, etc) add a new optional WHERE clause, connect with and
send, as a paramter, a list of ensembles as they are stored, as characters like this '001,003,005' the separator here is a comma but could be anything. If the parameters ensembles = '001,003,005' then the sql would be something like
"select * etc
FROM mhw_table
WHERE ... and contains('001,003,005', ensemble)"
For the template function, add parameter ...,ensemble_list = '001,003,005') and then in the sql template
"select * etc
FROM mhw_table
WHERE ... and contains('{ensemble_list}', ensemble)"
When creating a summary statistic (avg, median, etc) from a metric, need to be able to specify the ensemble number.
The metrics tables have an 'ensemble' column to use, which is a string/character column with leading zeros, same as the file name from Dr. Kounta's matlab files. the
ensemble
column has strings like001
,002
, ...010
when creating SQL in duckdb to limit to select ensembles (1, 3, 5, etc) add a new optional
WHERE
clause, connect withand
send, as a paramter, a list of ensembles as they are stored, as characters like this
'001,003,005'
the separator here is a comma but could be anything. If the parametersensembles = '001,003,005'
then the sql would be something likeFor the template function, add parameter
...,ensemble_list = '001,003,005')
and then in the sql templatesee contains function