ts_metadata: Extract list with tree sequence metadata saved by SLiM

View source: R/tree-sequences.R

ts_metadataR Documentation

Extract list with tree sequence metadata saved by SLiM

Description

Extract list with tree sequence metadata saved by SLiM

Usage

ts_metadata(ts)

Arguments

ts

Tree sequence object of the class slendr_ts

Value

List of metadata fields extracted from the tree-sequence object

Examples


init_env()

# load an example model with an already simulated tree sequence
slendr_ts <- system.file("extdata/models/introgression_slim.trees", package = "slendr")
model <- read_model(path = system.file("extdata/models/introgression", package = "slendr"))

# load the tree-sequence object from disk
ts <- ts_load(slendr_ts, model)

# extract the list of metadata information from the tree sequence
ts_metadata(ts)

slendr documentation built on June 22, 2024, 6:56 p.m.