phylobase

An R package that provides a base S4 class for comparative methods, incorporating one or more trees and trait data

https://github.com/fmichonneau/phylobase

Science Score: 23.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
  • DOI references
  • Academic publication links
  • Committers with academic emails
    5 of 13 committers (38.5%) from academic institutions
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (18.7%) to scientific vocabulary

Keywords

phylogenetics r

Keywords from Contributors

novice carpentries lesson data-carpentry data-wrangling ecology english open-educational-resources stable beta
Last synced: 9 months ago · JSON representation

Repository

An R package that provides a base S4 class for comparative methods, incorporating one or more trees and trait data

Basic Info
  • Host: GitHub
  • Owner: fmichonneau
  • Language: R
  • Default Branch: master
  • Homepage:
  • Size: 5.91 MB
Statistics
  • Stars: 19
  • Watchers: 3
  • Forks: 0
  • Open Issues: 6
  • Releases: 7
Topics
phylogenetics r
Created almost 12 years ago · Last pushed over 2 years ago
Metadata Files
Readme

README.Rmd

---
output: github_document
---



```{r, include = FALSE}
knitr::opts_chunk$set(
  collapse = TRUE,
  comment = "#>",
  fig.path = "man/figures/README-",
  out.width = "100%"
)
```

# phylobase


[![R-CMD-check](https://github.com/fmichonneau/phylobase/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/fmichonneau/phylobase/actions/workflows/R-CMD-check.yaml)
[![codecov.io][(https://app.codecov.io/github/fmichonneau/phylobase?branch=master)](https://app.codecov.io/github/fmichonneau/phylobase?branch=master)
![](https://cranlogs.r-pkg.org/badges/phylobase)
[![CRAN version](https://www.r-pkg.org/badges/version/phylobase)](https://cran.r-project.org/package=phylobase)


## About this package

`phylobase` provides classes and methods to easily associate, manipulate,
explore, and plot phylogenetic trees and data about the species they
include. The goal of this package is to provide a base set of tools likely to be
shared by all packages designed for phylogenetic analysis. This standardization
will benefit both *end-users* by allowing them to move results across packages
and keep data associated with the phylogenetic trees; and *developers* by
focusing on method development instead of having to rewrite the base functions.

- Authors: R Hackathon et al. (alphabetically: Ben Bolker, Marguerite Butler,
  Peter Cowan, Damien de Vienne, Dirk Eddelbuettel, Mark Holder, Thibaut
  Jombart, Steve Kembel, Francois Michonneau, David Orme, Brian O'Meara,
  Emmanuel Paradis, Jim Regetz, Derrick Zwickl)
- Maintainer: Francois Michonneau
- Licence: GPL (>= 2)
- Issues, bug reports, feature requests, discussion:
  https://github.com/fmichonneau/phylobase/issues

## Installation

### Stable version

The stable version (the minor and patch version numbers are even, e.g., 0.6.8)
can be downloaded from CRAN.

```{r, eval=FALSE}
install.packages("phylobase")
```

### Development version

The development version (the patch version number is odd, e.g., 0.6.9) is
available on GitHub (https://github.com/fmichonneau/phylobase), and can be
installed using the [`devtools`](https://cran.r-project.org/package=devtools)
package.

```{r, eval=FALSE}
pak::install_github("fmichonneau/phylobase")
library(phylobase)
```

### Getting started

```{r, echo=FALSE}
library(phylobase)
```

`phylobase` comes with example data sets `geospiza` and `geospiza_raw`.

- `geospiza` is a `phylo4d` object (the `phylobase` class that holds together a
  phylogenetic tree and associated data, the `phylo4` class is for phylogenetic
  trees only).
- `geospiza_raw` is a list that contains the tree `geospiza_raw$tree` (as an
  `ape::phylo` object) and the data `geospiza_raw$data` (as a `data.frame`) that
  were used to build the `geospiza` object.

Now we'll take the \emph{Geospiza} data from \verb+geospiza_raw$data+ and merge
it with the tree. However, since \emph{G. olivacea} is included in the tree but
not in the data set, we will initially run into some trouble:

```{r, error=TRUE}
data(geospiza_raw)
g1 <- as(geospiza_raw$tree, "phylo4")
geodata <- geospiza_raw$data
g2 <- phylo4d(g1, geodata)
```

To deal with _G. olivacea_ missing from the data, we have a few choices. The
easiest is to use `missing.data="warn"` to allow `R` to create the new object
with a warning (you can also use `missing.data="OK"` to proceed without
warnings):

```{r, warn=TRUE}
g2 <- phylo4d(g1, geodata, missing.data="warn")
head(g2)
```

### Importing data

#### From NEXUS files

`phylobase` has a robust parser for NEXUS files (it uses the NEXUS Class Library
from Paul Lewis and Mark Holder,
[NCL](https://sourceforge.net/projects/ncl/files/)). It can be used to import
simultaneously tree and species data.

```{r}
myrmeFile <- system.file("nexusfiles/treeWithDiscreteData.nex", package="phylobase")
myrme <- readNexus(file=myrmeFile)
head(myrme)
```

#### From NeXML

```{r}
library(RNeXML)
nxmlFile <- system.file("nexmlfiles/comp_analysis.xml", package="phylobase")
nxml <- nexml_read(nxmlFile)
nxmlEx <- phylo4(nxml)
```

Owner

  • Name: François Michonneau
  • Login: fmichonneau
  • Kind: user
  • Company: Solutions Engineer @posit-dev

Solutions Engineer @posit-dev

GitHub Events

Total
  • Watch event: 2
Last Year
  • Watch event: 2

Committers

Last synced: 10 months ago

All Time
  • Total Commits: 931
  • Total Committers: 13
  • Avg Commits per committer: 71.615
  • Development Distribution Score (DDS): 0.534
Past Year
  • Commits: 0
  • Committers: 0
  • Avg Commits per committer: 0.0
  • Development Distribution Score (DDS): 0.0
Top Committers
Name Email Commits
Francois Michonneau f****u@g****m 434
Peter Cowan r****e@p****m 159
Ben Bolker b****r@g****m 139
Jim Regetz r****z@n****u 79
Thibaut Jombart t****t@i****k 50
Steven Kembel s****l@g****m 20
Dirk Eddelbuettel e****d@d****g 19
Marguerite Butler m****r@h****u 12
Brian O'Meara o****n@g****m 12
David Orme d****e@i****k 3
Mark Holder m****r@k****u 2
Stefan Theussl s****l@R****g 1
Hilmar Lapp h****p@d****t 1
Committer Domains (Top 20 + Academic)

Issues and Pull Requests

Last synced: 10 months ago

All Time
  • Total issues: 15
  • Total pull requests: 1
  • Average time to close issues: 7 months
  • Average time to close pull requests: 1 minute
  • Total issue authors: 11
  • Total pull request authors: 1
  • Average comments per issue: 1.0
  • Average comments per pull request: 0.0
  • Merged pull requests: 1
  • Bot issues: 0
  • Bot pull requests: 0
Past Year
  • Issues: 0
  • Pull requests: 0
  • Average time to close issues: N/A
  • Average time to close pull requests: N/A
  • Issue authors: 0
  • Pull request authors: 0
  • Average comments per issue: 0
  • Average comments per pull request: 0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 0
Top Authors
Issue Authors
  • fmichonneau (5)
  • nphavill (1)
  • HedvigS (1)
  • JaydenM-C (1)
  • cboettig (1)
  • joanam (1)
  • RominaSSBatista (1)
  • epurdom (1)
  • hadley (1)
  • wcornwell (1)
  • codingbutstillalive (1)
Pull Request Authors
  • fmichonneau (1)
Top Labels
Issue Labels
bug (2) enhancement (2)
Pull Request Labels

Packages

  • Total packages: 2
  • Total downloads:
    • cran 6,876 last-month
  • Total docker downloads: 132,196
  • Total dependent packages: 22
    (may contain duplicates)
  • Total dependent repositories: 51
    (may contain duplicates)
  • Total versions: 19
  • Total maintainers: 1
cran.r-project.org: phylobase

Base Package for Phylogenetic Structures and Comparative Data

  • Versions: 16
  • Dependent Packages: 19
  • Dependent Repositories: 51
  • Downloads: 6,876 Last month
  • Docker Downloads: 132,196
Rankings
Dependent repos count: 3.5%
Dependent packages count: 3.6%
Downloads: 7.4%
Stargazers count: 13.3%
Average: 13.4%
Docker downloads count: 24.7%
Forks count: 27.7%
Last synced: 9 months ago
conda-forge.org: r-phylobase
  • Versions: 3
  • Dependent Packages: 3
  • Dependent Repositories: 0
Rankings
Dependent packages count: 19.5%
Dependent repos count: 34.0%
Average: 40.6%
Stargazers count: 47.8%
Forks count: 61.1%
Last synced: 9 months ago

Dependencies

.github/workflows/R-CMD-check.yaml actions
  • actions/checkout v3 composite
  • r-lib/actions/check-r-package v2 composite
  • r-lib/actions/setup-pandoc v2 composite
  • r-lib/actions/setup-r v2 composite
  • r-lib/actions/setup-r-dependencies v2 composite
  • r-lib/actions/setup-tinytex v2 composite
DESCRIPTION cran
  • RNeXML * imports
  • Rcpp >= 0.11.0 imports
  • ade4 * imports
  • ape >= 3.0 imports
  • grid * imports
  • methods * imports
  • rncl >= 0.6.0 imports
  • stats * imports
  • MASS * suggests
  • knitr * suggests
  • rmarkdown * suggests
  • testthat >= 0.8.1 suggests