def get_field_type(values):
    type_freq  = collections.defaultdict(int)

    # count occurances of each type:
    for key in values:
        i = _get_type(key)
        if i != 'unknown':                   # NOTE: unknown is filtered out
            try:                             # values is a dict
                type_freq[i] += values[key]
            except TypeError:                # values is a list
                type_freq[i] += 1
    type_list = type_freq.keys()

    # try simple rules:
    result = _get_field_type_rule(type_list)
    if result:
        return result

    # try probabilities:
    result = _get_field_type_probability(type_freq)
    return (result or 'unknown')
Determines the type of every item in the value list or dictionary,
dataset/ETHPy150Open kenfar/DataGristle/gristle/field_type.py/get_field_type