def val_check(array, resolution):
    """Check the resolution of the x and y dimensions of the scans

    Parameters
    ==========
    array (nd.array)
        array of all the scan x or y dimensions

    resolution (float)
        a numbers in microns that sets the resolution check of the x and y dimensions

    Returns
    =======
    bool (True or False) on whether or not the scan dimensions are within the set resolution
    """
    min_res = array[0] - resolution
    max_res = array[0] + resolution
    output = []
    for value in array:
        if min_res <= value <= max_res:
            output.append(True)
        else:
            output.append(False)
    return all(output)
