def get_subplot_size(lenx, i):
    """
    Gets the subplot size as a tuple depending on the number of datasets passed.
    This is used for creating henry regime subplots.

    :param lenx: int
        Number of datasets

    :param i:
        Iterator

    :return: tuple of shape (x, y, z)
    """
    if lenx <= 4:
        return 2, 2, i + 1
    if 9 >= lenx > 4:
        return 3, 3, i + 1
    if 16 >= lenx > 9:
        return 4, 4, i + 1