Package: phyr 1.1.0

Daijiang Li

phyr: Model Based Phylogenetic Analysis

A collection of functions to do model-based phylogenetic analysis. It includes functions to calculate community phylogenetic diversity, to estimate correlations among functional traits while accounting for phylogenetic relationships, and to fit phylogenetic generalized linear mixed models. The Bayesian phylogenetic generalized linear mixed models are fitted with the 'INLA' package (<https://www.r-inla.org>).

Authors:Anthony Ives [aut], Russell Dinnage [aut], Lucas A. Nell [aut], Matthew Helmus [aut], Daijiang Li [aut, cre]

phyr_1.1.0.tar.gz
phyr_1.1.0.tar.gz(r-4.5-noble)phyr_1.1.0.tar.gz(r-4.4-noble)
phyr_1.1.0.tgz(r-4.4-emscripten)phyr_1.1.0.tgz(r-4.3-emscripten)
phyr.pdf |phyr.html
phyr/json (API)
NEWS

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

Peer review:

Bug tracker:https://github.com/daijiang/phyr/issues

Pkgdown:https://daijiang.github.io

Uses libs:
  • openblas– Optimized BLAS
  • c++– GNU Standard C++ Library v3
Datasets:
  • comm_a - Example community data
  • comm_b - Example community data
  • envi - Example environmental data
  • oldfield - Phylogeny and community data from an Oldfield ecosystem in Southern Ontario, Canada
  • phylotree - Example phylogeny
  • traits - Example species traits data

5.52 score 2 packages 111 scripts 3.3k downloads 36 exports 43 dependencies

Last updated 4 years agofrom:a4cc0a4ca9. Checks:OK: 2. Indexed: no.

TargetResultDate
Doc / VignettesOKNov 22 2024
R-4.5-linux-x86_64OKNov 22 2024

Exports:%nin%align_comm_Vboot_cicommunityPGLMMcommunityPGLMM.matrix.structurecommunityPGLMM.plot.recommunityPGLMM.predicted.valuescommunityPGLMM.profile.LRTcommunityPGLMM.show.recor_phylofixefget_design_matrixmatch_comm_treepcdpcd_predpglmmpglmm_comparepglmm_matrix_structurepglmm_plot_ranefpglmm_plot_repglmm_predicted_valuespglmm_profile_LRTplot_bayesplot_dataprep_dat_pglmmpscpsdpsepsrpsvpsv.sppranefrefit_bootsrm_site_noobsrm_sp_noobsvcv2

Dependencies:apebootclicpp11deldirdigestdplyrfansigenericsgluegridExtragtableinterpjpeglatticelatticeExtralifecyclelme4magrittrMASSMatrixminqamvtnormnlmenloptrpillarpkgconfigpngpurrrR6RColorBrewerRcppRcppArmadilloRcppEigenrlangstringistringrtibbletidyrtidyselectutf8vctrswithr

Performance benchmark

Rendered frombenchmarks.Rmdusingknitr::rmarkdownon Nov 22 2024.

Last update: 2019-10-24
Started: 2019-10-24

Plot random terms of communityPGLMM

Rendered fromplot-re.Rmdusingknitr::rmarkdownon Nov 22 2024.

Last update: 2020-12-18
Started: 2019-10-24

Usage of pglmm()

Rendered frompglmm.Rmdusingknitr::rmarkdownon Nov 22 2024.

Last update: 2020-12-18
Started: 2019-10-24

Readme and manuals

Help Manual

Help pageTopics
Not in%nin%
Create phylogenetic var-cov matrix based on phylogeny and community dataalign_comm_V
Generic method to output bootstrap confidence intervals from an object.boot_ci
Example community datacomm_a
Example community datacomm_b
Correlations among multiple variates with phylogenetic signalboot_ci.cor_phylo cor_phylo print.cor_phylo
Example environmental dataenvi
Family Objects for communityPGLMM objectsfamily.communityPGLMM
Fitted values for communityPGLMMfitted.communityPGLMM
Extract fixed-effects estimatesfixed.effects fixef fixef.communityPGLMM
'get_design_matrix' gets design matrix for gaussian, binomial, and poisson modelsget_design_matrix
Match phylogeny with community datamatch_comm_tree
Extracting the Model Frame from a communityPGLMM Model objectmodel.frame.communityPGLMM
Number of Observation in a communityPGLMM Modelnobs.communityPGLMM
Phylogeny and community data from an Oldfield ecosystem in Southern Ontario, Canadaoldfield
pairwise site phylogenetic community dissimilarity (PCD) within a communitypcd
Predicted PCD with species poolpcd_pred
Phylogenetic Generalized Linear Mixed Model for Community DatacommunityPGLMM pglmm
Phylogenetic Generalized Linear Mixed Model for Comparative Datapglmm_compare
'pglmm_matrix_structure' produces the entire covariance matrix structure (V) when you specify random effects.communityPGLMM.matrix.structure pglmm_matrix_structure
Visualize random terms of communityPGLMMscommunityPGLMM.plot.re communityPGLMM.show.re pglmm_plot_ranef pglmm_plot_re
Predicted values of PGLMMcommunityPGLMM.predicted.values pglmm_predicted_values
'pglmm_profile_LRT' tests statistical significance of the phylogenetic random effect of binomial models on species slopes using a likelihood ratio test.communityPGLMM.profile.LRT pglmm_profile_LRT
Example phylogenyphylotree
plot_bayes genericplot_bayes
Plot the original dataset and predicted values (optional)plot_bayes.communityPGLMM plot_data
Predict Function for communityPGLMM Model Objectspredict.communityPGLMM
Prepare data for 'pglmm'prep_dat_pglmm
Print summary information of fitted modelprint.communityPGLMM
Print summary information of fitted modelprint.pglmm_compare
Phylogenetic Species Diversity Metricspsc psd pse psr psv psv.spp
Extract random-effects estimatesrandom.effects ranef ranef.communityPGLMM
Refit bootstrap replicates that failed to converge in a call to 'cor_phylo'print.cp_refits refit_boots
Residuals of communityPGLMM objectsresiduals.communityPGLMM
Remove site that has no observations of any speciesrm_site_noobs
Remove species that not observed in any siterm_sp_noobs
Simulate from a communityPGLMM objectsimulate.communityPGLMM
Summary information of fitted modelsummary.communityPGLMM
Summary information of fitted pglmm_compare modelsummary.pglmm_compare
Example species traits datatraits
Create phylogenetic var-cov matrixvcv2