I have trouble with IFF in SciDB 14.3. This is my array:
But when I try to do something like this:
apply(MODIS_AMZ_EVI2, myField, iff(time_id > 270, 1, 0));
I get this error:
UserQueryException in file: src/query/Expression.cpp function: internalCompile line: 577 Error id: scidb::SCIDB_SE_QPROC::SCIDB_LE_FUNCTION_NOT_FOUND Error description: Query processor error. Function 'iff(bool, int64, int64)' not found. apply(MODIS_AMZ_EVI2, quarter, iff(time_id > 274, 1, 0)) ^^^^^^^^^^^^^^^^^^^^^^^^^ Failed query id: 1101184747159
I’m sure IFF is installed since it appears in the results of this query:
What I want to achieve is to populate a field depending on intervals over a single dimension: For example,
if 0 <= myDimension < 43 then myField = 1
if 43 <= myDimension < 200 then myField = 2
and so on. I’d like to know:
What am I doing wrong regarding IFF?
Can I include AND or && inside the IFF clause?
What is the best way to evaluate many intervals in a single AFL expression?