pypet/naturalnaming.py
def f_store_child(self, name, recursive=False, store_data=pypetconstants.STORE_DATA,
                      max_depth=None):
        """Stores a child or recursively a subtree to disk.

        :param name:

            Name of child to store. If grouped ('groupA.groupB.childC') the path along the way
            to last node in the chain is stored. Shortcuts are NOT allowed!

        :param recursive:

            Whether recursively all children's children should be stored too.

        :param store_data:

            For how to choose 'store_data' see :ref:`more-on-storing`.

        :param max_depth:

            In case `recursive` is `True`, you can specify the maximum depth to store
            data relative from current node. Leave `None` if you don't want to limit
            the depth.

        :raises: ValueError if the child does not exist.

        """
        if not self.f_contains(name, shortcuts=False):
            raise ValueError('Your group `%s` does not (directly) contain the child `%s`. '
                             'Please not that shortcuts are not allowed for `f_store_child`.' %
                             (self.v_full_name, name))

        traj = self._nn_interface._root_instance
        storage_service = traj.v_storage_service

        storage_service.store(pypetconstants.TREE, self, name,
                              trajectory_name=traj.v_name,
                              recursive=recursive,
                              store_data=store_data,
                              max_depth=max_depth)
def f_store_child(self, name, recursive=False, store_data=pypetconstants.STORE_DATA,
                      max_depth=None):
        """Stores a child or recursively a subtree to disk.

        :param name:

            Name of child to store. If grouped ('groupA.groupB.childC') the path along the way
            to last node in the chain is stored. Shortcuts are NOT allowed!

        :param recursive:

            Whether recursively all children's children should be stored too.

        :param store_data:

            For how to choose 'store_data' see :ref:`more-on-storing`.

        :param max_depth:

            In case `recursive` is `True`, you can specify the maximum depth to store
            data relative from current node. Leave `None` if you don't want to limit
            the depth.

        :raises: ValueError if the child does not exist.

        """
        if not self.f_contains(name, shortcuts=False):
            raise ValueError('Your group `%s` does not (directly) contain the child `%s`. '
                             'Please not that shortcuts are not allowed for `f_store_child`.' %
                             (self.v_full_name, name))

        traj = self._nn_interface._root_instance
        storage_service = traj.v_storage_service

        storage_service.store(pypetconstants.TREE, self, name,
                              trajectory_name=traj.v_name,
                              recursive=recursive,
                              store_data=store_data,
                              max_depth=max_depth)
Stores a child or recursively a subtree to disk.

        :param name:

            Name of child to store. If grouped ('groupA.groupB.childC') the path along the way
            to last node in the chain is stored. Shortcuts are NOT allowed!

        :param recursive:

            Whether recursively all children's children should be stored too.

        :param store_data:

            For how to choose 'store_data' see :ref:`more-on-storing`.

        :param max_depth:

            In case `recursive` is `True`, you can specify the maximum depth to store
            data relative from current node. Leave `None` if you don't want to limit
            the depth.

        :raises: ValueError if the child does not exist.