def calc_integration_time(num_groups, frame_time, frames_per_group, num_skips):
    """Calculates the integration time.

    Parameters
    ----------
    num_groups : int
        Groups per integration.]
    frame_time : float
        Frame time (in seconds)
    frames_per_group : int
        Frames per group -- always 1 except maybe brown dwarves
    num_skips : int
        Skips per integration -- always 0 except maybe brown dwarves

    Returns
    -------
    integration_time : float
        Integration time (in seconds)
    """

    integration_time = (num_groups * (frames_per_group + num_skips) - num_skips) * frame_time

    return integration_time