pypet/trajectory.py
def f_merge_many(self, other_trajectories,
                ignore_data=(),
                move_data=False,
                delete_other_trajectory=False,
                keep_info=True,
                keep_other_trajectory_info=True,
                merge_config=True,
                backup=True):
        """Can be used to merge several `other_trajectories` into your current one.

        IMPORTANT `backup=True` only backs up the current trajectory not any of
        the `other_trajectories`. If you need a backup of these, do it manually.

        Parameters as for :func:`~pypet.trajectory.Trajectory.f_merge`.

        """
        other_length = len(other_trajectories)
        self._logger.info('Merging %d trajectories into the current one.' % other_length)
        self.f_load_skeleton()

        if backup:
            self.f_backup()

        for idx, other in enumerate(other_trajectories):
            self.f_merge(other, ignore_data=ignore_data,
                         move_data=move_data,
                         delete_other_trajectory=delete_other_trajectory,
                         keep_info=keep_info,
                         keep_other_trajectory_info=keep_other_trajectory_info,
                         merge_config=merge_config,
                         backup=False,
                         consecutive_merge=True)
            self._logger.log(21,'Merged %d out of %d' % (idx + 1, other_length))
        self._logger.info('Storing data to disk')
        self._reversed_wildcards = {}
        self.f_store()
        self._logger.info('Finished final storage')
def f_merge_many(self, other_trajectories,
                ignore_data=(),
                move_data=False,
                delete_other_trajectory=False,
                keep_info=True,
                keep_other_trajectory_info=True,
                merge_config=True,
                backup=True):
        """Can be used to merge several `other_trajectories` into your current one.

        IMPORTANT `backup=True` only backs up the current trajectory not any of
        the `other_trajectories`. If you need a backup of these, do it manually.

        Parameters as for :func:`~pypet.trajectory.Trajectory.f_merge`.

        """
        other_length = len(other_trajectories)
        self._logger.info('Merging %d trajectories into the current one.' % other_length)
        self.f_load_skeleton()

        if backup:
            self.f_backup()

        for idx, other in enumerate(other_trajectories):
            self.f_merge(other, ignore_data=ignore_data,
                         move_data=move_data,
                         delete_other_trajectory=delete_other_trajectory,
                         keep_info=keep_info,
                         keep_other_trajectory_info=keep_other_trajectory_info,
                         merge_config=merge_config,
                         backup=False,
                         consecutive_merge=True)
            self._logger.log(21,'Merged %d out of %d' % (idx + 1, other_length))
        self._logger.info('Storing data to disk')
        self._reversed_wildcards = {}
        self.f_store()
        self._logger.info('Finished final storage')
Can be used to merge several `other_trajectories` into your current one.

        IMPORTANT `backup=True` only backs up the current trajectory not any of
        the `other_trajectories`. If you need a backup of these, do it manually.

        Parameters as for :func:`~pypet.trajectory.Trajectory.f_merge`.