Skip to content

Commit

Permalink
Merge pull request #4 from MindTheGap-ERC/dev
Browse files Browse the repository at this point in the history
Dev
  • Loading branch information
NiklasHohmann authored Jul 19, 2024
2 parents b2f3013 + 366fff6 commit 6b7e484
Show file tree
Hide file tree
Showing 4 changed files with 38 additions and 21 deletions.
8 changes: 6 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ R package for stratigraphic paleobiology modeling pipelines.

__Niklas Hohmann__
Utrecht University
email: n.hohmann [at] uu.nl
email: n.h.hohmann [at] uu.nl
Web page: [uu.nl/staff/NHohmann](https://www.uu.nl/staff/NHHohmann)
Orcid: [0000-0003-1559-1838](https://orcid.org/0000-0003-1559-1838)

Expand All @@ -35,7 +35,7 @@ remotes::install_github(repo = "MindTheGap-ERC/StratPal",
dependencies = TRUE)
```

to install the lastest stable version of the package.
to install the latest stable version of the package.

## Usage

Expand All @@ -53,6 +53,10 @@ browseVignettes(package = "StratPal")

to view the available vignettes (long form documentation) with use cases or visit the package webpage ([mindthegap-erc.github.io/StratPal](https://mindthegap-erc.github.io/StratPal/)) to get started.

## Contribution

For contribution guidelines see the CONTRIBUTING.md file

## License

Apache 2.0, see LICENSE file for license text.
Expand Down
43 changes: 28 additions & 15 deletions vignettes/StratPal.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -21,49 +21,62 @@ library(admtools)

## Overview

Welcome to the `StratPal` package. This vignette provides an overview of the structure of the package and preliminaries needed to efficiently use it. We go through _dependencies_, _piping_, and working with _age-depth models_.
Welcome to the `StratPal` package. This vignette provides an overview of the structure of the package and preliminaries needed to efficiently use it. We go through _installation_, _dependencies_, provide an overview of the available _example data_, _piping_, and working with _age-depth models_.

If you want to skip the introduction, go to

```{r, eval=FALSE}
vignette("fossil_occ")
vignette("phenotypic_evolution")
```

for details on how to model stratigraphic paleobiology of events such as fossil occurrences and first/last occurrences. Go to
for details on how to model stratigraphic paleobiology of phenotypic evolution. Go to

```{r, eval=FALSE}
vignette("trait_evolution")
vignette("event_data")
```

for details on how to model stratigraphic paleobiology of trait evolution.
for details on how to model stratigraphic paleobiology of event data such as individual fossils and first/last occurrences of taxa.

## Dependencies
## Installation

The `StratPal` heavily relies on the age-depth modelling tools provided by the `admtools` package. To make sure you have the latest version of the package installed, first install the `remotes` package by running
To install the `StratPal` package, first install the `remotes` package by running

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

in your console. Then you can install the latest version of `admtools` from _GitHub_ by running
in the R console. Then, run

```{r, eval=FALSE}
remotes::install_github(repo = "MindTheGap-ERC/admtools",
```R
remotes::install_github(repo = "MindTheGap-ERC/StratPal",
build_vignettes = TRUE,
ref = "HEAD",
dependencies = TRUE)
```

This will also ask you to update all dependent packages.
to install the latest stable version of the package and all its dependencies.

## Dependencies

The `StratPal` heavily relies on the age-depth modelling tools provided by the `admtools` package, which is _automatically_ installed when you install `StratPal`.

Below we provide a brief overview of the functionality of the `admtools` package we need. If you want more information, you can browse through the package vignettes using
To use its functionality, you need to run

```{r}
library(admtools)
```


before running any of the provided examples. Below we provide a brief overview of the functionality of the `admtools` package we need. If you want more information, you can browse through the package vignettes using

```{r, eval=FALSE}
browseVignettes(package = "admtools") # opens in Browser
```

or by visiting the package website at https://mindthegap-erc.github.io/admtools/.

## Example data

## Piping

In the `StratPal` package and its vignettes, we make heavy use of the base R _pipe_ operator `|>`. While this is not required to run the package, it simplifies the code and makes the underlying logic of a modeling _pipeline_ clearer.
Expand Down Expand Up @@ -182,13 +195,13 @@ In `admtools`, the transformation of data is done by the functions `time_to_stra
With the preliminaries out of the way, you can go to go to

```{r, eval=FALSE}
vignette("fossil_occ")
vignette("event_data")
```

for details on how to model stratigraphic paleobiology of events such as fossil occurrences and first/last occurrences. Go to

```{r, eval=FALSE}
vignette("trait_evolution")
vignette("phenotypic_evolution")
```

for details on how to model stratigraphic paleobiology of trait evolution.
4 changes: 2 additions & 2 deletions vignettes/fossil_occ.Rmd → vignettes/event_data.Rmd
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
title: "Stratigraphic Paleobiology for fossil occurrences"
title: "Stratigraphic Paleobiology for Event Data"
output: rmarkdown::html_vignette
vignette: >
%\VignetteIndexEntry{Stratigraphic Paleobiology for fossil occurrences}
%\VignetteIndexEntry{Stratigraphic Paleobiology for Event Data}
%\VignetteEngine{knitr::rmarkdown}
%\VignetteEncoding{UTF-8}
---
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
title: "trait_evolution"
title: "Stratigraphic Paleobiology for Phenotypic Evolution"
output: rmarkdown::html_vignette
vignette: >
%\VignetteIndexEntry{trait_evolution}
%\VignetteIndexEntry{Stratigraphic Paleobiology for Phenotypic Evolution}
%\VignetteEngine{knitr::rmarkdown}
%\VignetteEncoding{UTF-8}
---
Expand Down

0 comments on commit 6b7e484

Please sign in to comment.