Writes the plan's source binding, metadata, and operation nodes to a JSON
file. Matrices (including Matrix objects) are stored as numeric data with
their dimensions; map families and map_linear objects are stored as ASCII
R serializations (the same encoding used for alignments in GDS HDF5 stores).
Function-valued components that cannot be represented faithfully, such as a
custom MaskPolicy() function or a covariance provider, cause an error at
save time rather than being silently dropped.
Arguments
- plan
Plan or object coercible via
as_plan()- file
Path to JSON file
Value
Invisibly returns file, the path of the written JSON file. The
file contains the plan's source, metadata, operation nodes and digest
and can be restored with load_plan().
Details
The file records a digest of the serialized plan, which load_plan()
verifies.