turicreate.Sketch.dict_key_summary

Sketch.dict_key_summary()

Returns the sketch summary for all dictionary keys. This is only valid for sketch object from an SArray of dict type. Dictionary keys are converted to strings and then do the sketch summary.

Examples

>>> sa = turicreate.SArray([{'I':1, 'love': 2}, {'nature':3, 'beauty':4}])
>>> sa.summary().dict_key_summary()
+------------------+-------+----------+
|       item       | value | is exact |
+------------------+-------+----------+
|      Length      |   4   |   Yes    |
| # Missing Values |   0   |   Yes    |
| # unique values  |   4   |    No    |
+------------------+-------+----------+
Most frequent items:
+-------+---+------+--------+--------+
| value | I | love | beauty | nature |
+-------+---+------+--------+--------+
| count | 1 |  1   |   1    |   1    |
+-------+---+------+--------+--------+