def summarize_reduced_data(data):
    """
    Take a list of LMT data sets and return summaries of each relevant key
    """
    totals = {'n': 0, 'sum_bytes_read': 0, 'sum_bytes_write': 0, 'oss_ave':
        -0.0, 'oss_max': -0.0, 'mds_ave': -0.0, 'mds_max': -0.0,
        'missing_ost_read': 0, 'missing_ost_write': 0, 'missing_oss_cpu': 0,
        'missing_mds_cpu': 0, 'num_ost_read': 0, 'num_ost_write': 0,
        'num_oss_cpu': 0, 'num_mds_cpu': 0}
    for timestamp in sorted(data.keys()):
        datum = data[timestamp]
        points_in_bin = datum['indexf'] - datum['index0']
        totals['sum_bytes_read'] += datum['sum_ost_read']
        totals['sum_bytes_write'] += datum['sum_ost_write']
        totals['n'] += points_in_bin
        if 'ave_oss_cpu' in datum:
            totals['oss_ave'] += datum['ave_oss_cpu'] * points_in_bin
        if 'ave_mds_cpu' in datum:
            totals['mds_ave'] += datum['ave_mds_cpu'] * points_in_bin
        if 'max_oss_cpu' in datum:
            if datum['max_oss_cpu'] > totals['oss_max']:
                totals['oss_max'] = datum['max_oss_cpu']
            else:
                totals['oss_max'] = totals['oss_max']
        if 'max_mds_cpu' in datum:
            if datum['max_mds_cpu'] > totals['mds_max']:
                totals['mds_max'] = datum['max_mds_cpu']
            else:
                totals['mds_max'] = totals['mds_max']
        totals['missing_ost_read'] += datum.get('missing_ost_read', 0)
        totals['missing_ost_write'] += datum.get('missing_ost_write', 0)
        totals['missing_oss_cpu'] += datum.get('missing_oss_cpu', 0)
        totals['missing_mds_cpu'] += datum.get('missing_mds_cpu', 0)
        totals['num_ost_read'] += datum.get('num_ost_read', 0)
        totals['num_ost_write'] += datum.get('num_ost_write', 0)
        totals['num_oss_cpu'] += datum.get('num_oss_cpu', 0)
        totals['num_mds_cpu'] += datum.get('num_mds_cpu', 0)
    totals['ave_bytes_read_per_dt'] = totals['sum_bytes_read'] / totals['n']
    totals['ave_bytes_write_per_dt'] = totals['sum_bytes_write'] / totals['n']
    totals['sum_kibs_read'] = totals['sum_bytes_read'] / 1024.0
    totals['sum_kibs_write'] = totals['sum_bytes_write'] / 1024.0
    totals['sum_mibs_read'] = totals['sum_kibs_read'] / 1024.0
    totals['sum_mibs_write'] = totals['sum_kibs_write'] / 1024.0
    totals['sum_gibs_read'] = totals['sum_mibs_read'] / 1024.0
    totals['sum_gibs_write'] = totals['sum_mibs_write'] / 1024.0
    totals['sum_tibs_read'] = totals['sum_gibs_read'] / 1024.0
    totals['sum_tibs_write'] = totals['sum_gibs_write'] / 1024.0
    totals['ave_gibs_read_per_dt'] = totals['sum_gibs_read'] / totals['n']
    totals['ave_gibs_write_per_dt'] = totals['sum_gibs_write'] / totals['n']
    totals['oss_ave'] = totals['oss_ave'] / totals['n']
    totals['mds_ave'] = totals['mds_ave'] / totals['n']
    for base in ['ost_read', 'ost_write', 'oss_cpu', 'mds_cpu']:
        if totals['num_%s' % base] > 0:
            totals['frac_missing_%s' % base] = float(totals['missing_%s' %
                base]) / totals['num_%s' % base]
    totals['ave_tibs_read_per_dt'] = totals['sum_gibs_read'] / totals['n']
    totals['ave_tibs_write_per_dt'] = totals['sum_gibs_write'] / totals['n']
    return totals
