def min_max(buf):
    data = filter(lambda x: x <> None, buf)
    smallest = min(map(min, data))
    largest = max(map(max, data))
    return (smallest, largest)
Gets the smallest and largest value from the tuples in the ring buffer
dataset/ETHPy150Open rm-hull/pcd8544/examples/plotter.py/min_max