Skip to contents

Run LibBi and analyse results

LibBi operations

Functions for running LibBi.

filter(<libbi>) filter(<bi_model>)
Using the LibBi wrapper to filter
generate_dataset()
Generate Dataset
optimise(<libbi>) optimise(<bi_model>)
Using the LibBi wrapper to optimise
libbi()
LibBi Wrapper
predict(<libbi>)
Using the LibBi wrapper to predict
run(<libbi>)
Using the LibBi wrapper to launch LibBi
sample(<libbi>) sample(<bi_model>)
Using the LibBi wrapper to sample
sample_obs()
Sample observations from a LibBi model that has been run
simulate(<libbi>) simulate(<bi_model>)
Using the LibBi wrapper to simulate

Read and write LibBi inputs/outputs

Functions for interacting with the NetCDF files used by LibBi.

bi_contents()
Bi contents
bi_file_summary()
NetCDF File Summary
bi_read()
Bi Read
bi_write()
Create (e.g., init or observation) files for LibBi

Analyse LibBi outputs

Functions for analysing LibBi results.

extract_sample()
Extract a sample from a LibBi run.
get_traces()
Get the parameter traces
summary(<libbi>)
Print summary information about a libbi object
logLik(<libbi>)
Using the LibBi wrapper to logLik

Manipulate LibBi inputs/outputs

Functions for updating and saving LibBi objects.

attach_data(<libbi>)
Attach a new file or data set to a libbi object
join(<libbi>)
Join multiple libbi objects
read_libbi()
Read results of a LibBi run from an RDS file or from a folder. This completely reconstructs the saved LibBi object
save_libbi(<libbi>)
Write results of a LibBi run to an RDS file
update(<libbi>)
Update a libbi object

Construct, show and manipulate LibBi models

Create a model

Function for creating a LibBi model.

bi_model()
Bi Model

Show models

Functions for getting information from LibBi models.

get_block(<bi_model>)
Get the contents of a block in a LibBi model
get_const()
Get constants in a LibBi model
get_dims()
Get dimensions in a LibBi model
get_name(<bi_model>)
Get the name of a bi model
rewrite(<libbi>) rewrite(<bi_model>)
Using the LibBi wrapper to rewrite
var_names()
Get variable names in a LibBi model

Manipulate models

Functions for manipulating LibBi models.

add_block(<bi_model>)
Add a block to a LibBi model
enable_outputs()
Enable outputting variables in a bi_model
fix(<bi_model>)
Fix noise term, state or parameter of a libbi model
insert_lines(<bi_model>)
Insert lines in a LibBi model
remove_lines(<bi_model>)
Remove line(s) and/or block(s) in a libbi model
remove_vars()
Remove variables
replace_all(<bi_model>)
Replace all instances of a string with another in a model
set_name(<bi_model>)
Set the name of a bi model
write_model(<bi_model>) write_model(<libbi>)
Writes a bi model to a file.

Model operators

Operators for LibBi models

`==`(<bi_model>)
Check if two models are equal
`[`(<bi_model>)
Subset model lines
`[<-`(<bi_model>)
Subset and replace model lines
`!=`(<bi_model>)
Check if two models are unequal

Other functions

Utility functions

Useful additional functions.

flatten()
Flatten list of data frames This function takes a list of data frames (such as, for example, returned by bi_read) and converts it to a flat data frame
print_log()
Print the log file a libbi object

Deprecated functions

To be removed in the next version of rbi.

bi_generate_dataset()
Bi Generate Dataset