Skip to contents

Landing page

mrgsim.ds-package mrgsim.ds
mrgsim.ds: 'Apache' 'Arrow' Dataset-Backed Simulation Outputs for 'mrgsolve'

Read or load models

Functions to read models configured for use with mrgsim_ds().

mread_ds() mcode_ds() modlib_ds() house_ds() mread_cache_ds()
Load an mrgsolve model for Arrow-backed simulation

Generate Apache Arrow dataset-backed simulation outputs

Simulate and write output to disk.

mrgsim_ds()
Simulate from a model object, returning an 'Apache' 'Arrow'-backed output object
as_mrgsim_ds()
Coerce an mrgsims object to 'Apache' 'Arrow'-backed mrgsimsds object

S3 Methods

Work with mrgsim_ds() output.

Move, rename, or save outputs

move_ds() rename_ds() combine_ds()
Move, rename, combine files in mrgsimsds objects
save_ds() read_ds()
Save and restore an mrgsimsds object
write_parquet_ds() write_dataset_ds()
Write simulations to a parquet file or partitioned dataset
files_ds()
Get names of backing files
current_location()
Get the current location of mrgsimsds object files

Manage or query ownership

This applies to ownership parquet files holding simulation outputs for the duration of the working R session.

ownership() list_ownership() check_ownership() disown() take_ownership()
Ownership of simulation files
copy_ds()
Copy an mrgsimsds object

Work with lists of mrgsimsds objects

Commonly needed after batch simulation in parallel

reduce_ds()
Reduce a list of mrgsimsds objects into a single object
refresh_ds()
Refresh 'Arrow' dataset pointers
gc_ds()
Set garbage collection behavior for mrgsimsds objects
prune_ds()
Prune a list of mrgsimsds objects

Manage simulation outputs in tempdir()

list_temp() purge_temp()
Manage simulated outputs in the per-session temporary directory

Utility functions

save_process_info()
Save information about the R process that loaded a model
is_mrgsimsds()
Check if object inherits mrgsimsds

Coerce output to an R object

as_tibble(<mrgsimsds>) collect(<mrgsimsds>) as.data.frame(<mrgsimsds>)
Coerce an mrgsimsds object to a tbl
as_arrow_ds()
Coerce an mrgsimsds object to an arrow data set
as_arrow_table(<mrgsimsds>)
Coerce an mrgsimsds object to an arrow table
as_duckdb_ds()
Coerce an mrgsimsds object to a DuckDB table