macrobase
macrobase copied to clipboard
SQL: counts should be integers
Output for counts in SQL (outlier_count
, total_count
) are formatted as floats, but counts should always be integer-valued (I think).
e.g.,
macrobase-sql> SELECT * FROM DIFF(SPLIT (SELECT *, percentile(battery_drain) AS percentile from mobile) WHERE percentile > .99) ON *;
67156 [main] INFO QueryEngine - Using user_id, state, hw_make, firmware_version, app_version as candidate attributes for explanation
67265 [main] INFO APLSummarizer - Encoded in: 109 ms
67265 [main] INFO APLSummarizer - Encoded Categories: 2
67299 [main] INFO APLSummarizer - Number of results: 2
2 rows
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
| app_version | user_id | hw_make | state | firmware_version | support | global_ratio | outlier_count | total_count |
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
| v50 | - | - | - | - | .873185 | 89.883198 | 902.0 | 1003.0 |
| - | - | Emdoor | - | - | .873185 | 89.883198 | 902.0 | 1003.0 |
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Related: Is there a reason why we have outlier_count
versus a more generic population_A_cnt
and population_B_cnt
?