def _calculate_reverse_inference_vectors_binary(mrtable, p_in, p_out,
    in_count, out_count):
    """Internal function to return two strings of probabilities: one for 
       probabilities from likelihood table derived from images relevant to a 
       contrast, and the other from a likelihood table from images not relevant 
       - both are limited to voxels with activation for the image, defined as 
       above/below the threshold defined in the columns of the likelihood table.
       This will be use for reverse inference calculation of a single image 
       based on an absolute threshold to define activation. 
    """
    stat_map_abs = mrtable.abs()
    if p_in.columns[0] != p_out.columns[0]:
        raise ValueError(
            "ERROR: threshold defined in likelihood 'in' and likelihood 'out' tables is different (%s vs %s)"
             % (p_in.columns[0], p_out.columns[0]))
    else:
        threshold = p_out.columns[0]
    bin_df = stat_map_abs[0] >= threshold
    p_in_vector = p_in[bin_df == True][threshold].tolist()
    p_out_vector = p_out[bin_df == True][threshold].tolist()
    return p_in_vector, p_out_vector
