def get_grouped_snapshots(snapshot, mode):
    """ Get grouped snapshots per opf mode
    
    Parameters
    ----------
    snapshot : datetime
    mode : str
        [day, week, month]
    """
    periods = {'day': snapshot.groupby(snapshot.day).values(), 'week':
        snapshot.groupby(snapshot.week).values(), 'month': snapshot.groupby
        (snapshot.month).values()}
    return periods[mode]
