Package: secsse 3.7.0

Rampal S. Etienne

secsse: Several Examined and Concealed States-Dependent Speciation and Extinction

Simultaneously infers state-dependent diversification across two or more states of a single or multiple traits while accounting for the role of a possible concealed trait. See Herrera-Alsina et al. (2019) <doi:10.1093/sysbio/syy057>.

Authors:Leonel Herrera Alsina [aut], Paul van Els [aut], Thijs Janzen [ctb], Hanno Hildenbrandt [ctb], Pedro Santos Neves [ctb], Rampal S. Etienne [cre, aut]

secsse_3.7.0.tar.gz
secsse_3.7.0.zip(r-4.7)secsse_3.7.0.zip(r-4.6)secsse_3.7.0.zip(r-4.5)
secsse_3.7.0.tgz(r-4.6-x86_64)secsse_3.7.0.tgz(r-4.6-arm64)secsse_3.7.0.tgz(r-4.5-x86_64)secsse_3.7.0.tgz(r-4.5-arm64)
secsse_3.7.0.tar.gz(r-4.7-arm64)secsse_3.7.0.tar.gz(r-4.7-x86_64)secsse_3.7.0.tar.gz(r-4.6-arm64)secsse_3.7.0.tar.gz(r-4.6-x86_64)
secsse_3.7.0.tgz(r-4.6-emscripten)
manual.pdf |manual.html
card.svg |card.png
secsse/json (API)
NEWS

# Install 'secsse' in R:
install.packages('secsse', repos = c('https://phylotastic.r-universe.dev', 'https://cloud.r-project.org'))

Bug tracker:https://github.com/rsetienne/secsse/issues

Pkgdown/docs site:https://rsetienne.github.io

Uses libs:
  • c++– GNU Standard C++ Library v3
Datasets:

On CRAN:

Conda:

cpp

6.43 score 1 stars 34 scripts 289 downloads 26 exports 77 dependencies

Last updated from:925a70cf59. Checks:13 OK. Indexed: no.

TargetResultTimeFilesSyslog
linux-devel-arm64OK194
linux-devel-x86_64OK210
source / vignettesOK391
linux-release-arm64OK199
linux-release-x86_64OK222
macos-release-arm64OK113
macos-release-x86_64OK250
macos-oldrel-arm64OK123
macos-oldrel-x86_64OK418
windows-develOK152
windows-releaseOK315
windows-oldrelOK185
wasm-releaseOK155

Exports:cla_id_paramPoscla_secsse_loglikcla_secsse_mlcla_secsse_ml_func_def_parscreate_default_lambda_transition_matrixcreate_default_shift_matrixcreate_lambda_listcreate_mu_vectorcreate_q_matrixdefault_params_docevent_timesexpand_q_matrixextract_par_valsfill_inid_paramPosplot_idparslistplot_state_exactprepare_full_lambdasq_doubletranssecsse_logliksecsse_loglik_evalsecsse_mlsecsse_ml_func_def_parssecsse_simsecsse_single_branch_logliksortingtraits

Dependencies:apebackportsBHcachemcheckmatecliclusterGenerationcodacodetoolscolorspacecombinatcpp11DDDDEoptimdeSolvedigestdoParallelexpmfarverfastmapforeachfuturefuture.applygeigergenericsggplot2globalsgluegmpgtableigraphisobanditeratorslabelinglatticelifecyclelistenvmagrittrmapsMASSMatrixmemoisemnormtmvtnormncbitnlmenloptrnumDerivoptimParallelosqpparallellyphangornphytoolspillarpkgconfigpracmaprogressrpsoR6RColorBrewerRcppRcppArmadilloRcppEigenRcppParallelrlangS7scalesscatterplot3dSparseMsubplextibbletreebalancetreestatsutf8vctrsviridisLitewithr

Plotting probabilities

Rendered fromplotting_states.Rmdusingknitr::rmarkdownon May 15 2026.

Last update: 2026-05-15
Started: 2023-04-26

Simulating with secsse

Rendered fromsim_with_secsse.Rmdusingknitr::rmarkdownon May 15 2026.

Last update: 2023-07-27
Started: 2023-07-27

Starting secsse

Rendered fromstarting_secsse.Rmdusingknitr::rmarkdownon May 15 2026.

Last update: 2026-05-04
Started: 2023-07-27

Using secsse with complete phylogenies (with extinction)

Rendered fromcomplete_tree.Rmdusingknitr::rmarkdownon May 15 2026.

Last update: 2026-05-15
Started: 2023-07-27

Readme and manuals

Help Manual

Help pageTopics
Parameter structure setting for cla_secsse It sets the parameters (speciation, extinction and transition) IDs. Needed for ML calculation with cladogenetic options (cla_secsse_ml)cla_id_paramPos
Likelihood for SecSSE model, using Rcpp Loglikelihood calculation for the cla_SecSSE model given a set of parameters and data using Rcppcla_secsse_loglik
Maximum likehood estimation for (SecSSE)cla_secsse_ml
Maximum likehood estimation for (SecSSE) with parameter as complex functions. Cladogenetic versioncla_secsse_ml_func_def_pars
Helper function to create a default lambda listcreate_default_lambda_transition_matrix
Helper function to create a default 'shift_matrix' listcreate_default_shift_matrix
Helper function to automatically create lambda matrices, based on input. When choosing the CTD model, rates associated with observed states are now re-distributed to concealed states. This implicitly assumes that the number of observed and concealed states is identical.create_lambda_list
Generate mus vectorcreate_mu_vector
Helper function to neatly setup a Q matrix, without transitions to concealed states (only observed transitions shown)create_q_matrix
Event times of a (possibly non-ultrametric) phylogenetic treeevent_times
A phylogeny with traits at the tipsexample_phy_GeoSSE
Function to expand an existing q_matrix to a number of concealed statesexpand_q_matrix
Extract parameter values out of the result of a maximum likelihood inference runextract_par_vals
Helper function to enter parameter value on their right placefill_in
Parameter structure setting Sets the parameters (speciation, extinction and transition) ids. Needed for ML calculation ('secsse_ml()').id_paramPos
A phylogenetic reconstuction to run the vignettephylo_vignette
function to visualize the structure of the idparslistplot_idparslist
Plot the local probability along a treeplot_state_exact
Prepares the entire set of lambda matrices for cla_secsse. It provides the set of matrices containing all the speciation ratesprepare_full_lambdas
Basic Qmatrix Sets a Q matrix where double transitions are not allowedq_doubletrans
Likelihood for SecSSE model Loglikelihood calculation for the SecSSE model given a set of parameters and datasecsse_loglik
Likelihood for SecSSE model Logikelihood calculation for the SecSSE model given a set of parameters and data, returning also the likelihoods along the branchessecsse_loglik_eval
Maximum likehood estimation for (SecSSE)secsse_ml
Maximum likehood estimation for (SecSSE) complex functions as parametersecsse_ml_func_def_pars
Function to simulate a tree, conditional on observing all states.secsse_sim
Likelihood for SecSSE model Loglikelihood calculation for the SecSSE model given a set of parameters and data, calculated for a single branchsecsse_single_branch_loglik
Data checking and trait sorting In preparation for likelihood calculation, it orders trait data according the tree tipssortingtraits
A table with trait info to run the vignettetraits