@staticmethod
def isjoinable(sub1, sub2, include_split=False):
    """ Check if sub1 and sub2 can be joined. """
    if include_split:
        c0 = True
    else:
        c0 = '.' not in sub1.key and '.' not in sub2.key
    c1 = sub1.rz == sub2.rz
    c2 = sub1.ix[1] == sub2.ix[0] - 1 or sub2.ix[1] == sub1.ix[0] - 1
    c3 = sub1.rx == sub2.rx
    c4 = sub1.iz[1] == sub2.iz[0] - 1 or sub2.iz[1] == sub1.iz[0] - 1
    c5 = sub1.axis == sub2.axis
    condition0 = c0 and c5
    condition1 = c1 and c2
    condition2 = c3 and c4
    if condition0 and condition1 or condition0 and condition2:
        return True
    return False
