maci.yamldump
dumps data to a file as yaml
dumping a file
Dumps the corresponding python data types to a file formatted as YAML. Nothing is returned. Creates a new or overwrites an existing file by default (See append parameter to change mode).
Basic Example of dumping data to a file using default positional parameters
In this example, we simply dump data to a file using the yamldump function and pass a string of the filepath to the file as the first argument to the function, then pass the data as the second argument to the function. Note: This function dumps a single yaml document to the file. If looking to dump multiple yaml documents to a file, use the yamldumpall function.
parameters & arguments
Describes all parameter functionality and accepted data types
This function uses the PyYAML framework installed as a dependency from pypi for its underlying functionality. It is only using the "safe_dump" method, which only supports standard YAML tags and cannot represent an arbitrary Python object. For more information on PyYAML, visit: https://pypi.org/project/PyYAML/
Last updated