Statistical analysis of archaeological dates and groups of dates. ArchaeoPhases allows to post-process Markov Chain Monte Carlo (MCMC) simulations from ChronoModel (Lanos et al. 2020), Oxcal (Bronk Ramsey 2009) or BCal (Buck, Christen, and James 1999). This package provides functions for the study of rhythms of the long term from the posterior distribution of a series of dates (tempo and activity plot). It also allows the estimation and visualization of time ranges from the posterior distribution of groups of dates (e.g. duration, transition and hiatus between successive phases).
ArchaeoPhases v2.0 brings a comprehensive package rewrite,
resulting in the renaming of nearly all functions. For more information,
please refer to
news(Version >= "2.0", package = "ArchaeoPhases")
.
To cite ArchaeoPhases in publications use:
Philippe A, Vibet M (2020). "Analysis of Archaeological Phases Using
the R Package ArchaeoPhases." _Journal of Statistical Software, Code
Snippets_, *93*(1). doi:10.18637/jss.v093.c01
<https://doi.org/10.18637/jss.v093.c01>.
Philippe A, Vibet M, Frerebeau N, Dye T (2025). _ArchaeoPhases:
Post-Processing of Markov Chain Monte Carlo Simulations for
Chronological Modelling_. Université de Nantes, Nantes, France.
doi:10.5281/zenodo.8087121 <https://doi.org/10.5281/zenodo.8087121>,
R package version 2.1.0,
<https://ArchaeoStat.github.io/ArchaeoPhases/>.
You can install the released version of ArchaeoPhases from CRAN with:
install.packages("ArchaeoPhases")
And the development version from GitHub with:
# install.packages("remotes")
::install_github("ArchaeoStat/ArchaeoPhases") remotes
You can install the 1.x releases from the CRAN archives:
# install.packages("remotes")
::install_version("ArchaeoPhases", version = "1.8") remotes
ArchaeoPhases v2.0 uses aion for
internal date representation. Look at
vignette("aion", package = "aion")
before you start.
These examples use data available through the ArchaeoData package which is available in a separate repository. ArchaeoData provides MCMC outputs from ChronoModel, OxCal and BCal.
## Install the data package
install.packages("ArchaeoData", repos = "https://archaeostat.r-universe.dev")
## Load
library(ArchaeoPhases)
Import a CSV file containing a sample from the posterior distribution:
## Construct the paths to the data
<- file.path("chronomodel", "ksarakil")
path <- system.file(path, "Chain_all_Events.csv", package = "ArchaeoData")
path_event <- system.file(path, "Chain_all_Phases.csv", package = "ArchaeoData")
path_phase
## Read events from ChronoModel
<- read_chronomodel_events(path_event))
(chrono_events #> <EventsMCMC>
#> - Number of events: 16
#> - Number of MCMC samples: 30000
## Read phases from ChronoModel
<- read_chronomodel_phases(path_phase))
(chrono_phases #> <PhasesMCMC>
#> - Number of phases: 4
#> - Number of MCMC samples: 30000
## Plot the first event
plot(chrono_events[, 1], interval = "hdr")
## Plot all events
plot(chrono_events)
## Tempo plot
<- tempo(chrono_events, level = 0.95)
tp plot(tp)
## Activity plot
<- activity(chrono_events)
ac plot(ac)
<- boundaries(chrono_phases, level = 0.95)
bound as.data.frame(bound)
#> label start end duration
#> 1 EPI -28978.53 -26969.82 2008.712
#> 2 UP -38570.37 -29368.75 9201.622
#> 3 Ahmarian -42168.47 -37433.31 4735.159
#> 4 IUP -43240.37 -41161.00 2079.372
## Plot all phases
plot(chrono_phases)
plot(chrono_phases[, c("UP", "EPI"), ], succession = "hiatus")
plot(chrono_phases[, c("UP", "EPI"), ], succession = "transition")
This package provides translations of user-facing communications,
like messages, warnings and errors, and graphical elements (axis
labels). The preferred language is by default taken from the locale.
This can be overridden by setting of the environment variable
LANGUAGE
(you only need to do this once per session):
Sys.setenv(LANGUAGE = "<language code>")
Languages currently available are English (en
) and
French (fr
).