turicreate.Sketch.element_length_summary

Sketch.element_length_summary()

Returns the sketch summary for the element length. This is only valid for a sketch constructed SArray of type list/array/dict, raises Runtime exception otherwise.

Returns:
out : Sketch

An new sketch object regarding the element length of the current SArray

Examples

>>> sa = turicreate.SArray([[j for j in range(i)] for i in range(1,1000)])
>>> sa.summary().element_length_summary()
+--------------------+---------------+----------+
|        item        |     value     | is exact |
+--------------------+---------------+----------+
|       Length       |      999      |   Yes    |
|        Min         |      1.0      |   Yes    |
|        Max         |     999.0     |   Yes    |
|        Mean        |     500.0     |   Yes    |
|        Sum         |    499500.0   |   Yes    |
|      Variance      | 83166.6666667 |   Yes    |
| Standard Deviation | 288.386314978 |   Yes    |
|  # Missing Values  |       0       |   Yes    |
|  # unique values   |      992      |    No    |
+--------------------+---------------+----------+
Most frequent items:
+-------+---+---+---+---+---+---+---+---+---+----+
| value | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 |
+-------+---+---+---+---+---+---+---+---+---+----+
| count | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1  |
+-------+---+---+---+---+---+---+---+---+---+----+
Quantiles:
+-----+------+------+-------+-------+-------+-------+-------+-------+
|  0% |  1%  |  5%  |  25%  |  50%  |  75%  |  95%  |  99%  |  100% |
+-----+------+------+-------+-------+-------+-------+-------+-------+
| 1.0 | 10.0 | 50.0 | 250.0 | 500.0 | 750.0 | 950.0 | 990.0 | 999.0 |
+-----+------+------+-------+-------+-------+-------+-------+-------+