create_lambda_list {secsse} | R Documentation |
Helper function to automatically create lambda matrices, based on input
Description
Helper function to automatically create lambda matrices, based on input
Usage
create_lambda_list(
state_names = c(0, 1),
num_concealed_states = 2,
transition_matrix,
model = "ETD",
concealed_spec_rates = NULL
)
Arguments
state_names |
vector of names of all observed states. |
num_concealed_states |
number of concealed states, generally equivalent to the number of examined states in the dataset. |
transition_matrix |
a matrix containing a description of all speciation
events, where the first column indicates the source state, the second and
third column indicate the two daughter states, and the fourth column gives
the rate indicator used. E.g.: |
model |
used model, choice of |
concealed_spec_rates |
vector specifying the rate indicators for each
concealed state, length should be identical to |
Examples
trans_matrix <- c(0, 0, 0, 1)
trans_matrix <- rbind(trans_matrix, c(1, 1, 1, 2))
lambda_list <- create_lambda_list(state_names = c(0, 1),
num_concealed_states = 2,
transition_matrix = trans_matrix,
model = "ETD")