Package: htna 0.1.0

Sonsoles López-Pernas

htna: Heterogeneous Transition Network Analysis

Implements the Heterogeneous Transition Network Analysis (HTNA) method described by López-Pernas et al. (2026) <doi:10.1002/jcal.70285>. The method is an extension of transition network analysis (TNA) where actions or events belong to two or more distinct actor types (e.g. Human and AI),preserving the actor type partition on the resulting network. Provides a thin, focused API on top of the 'Nestimate' estimation engine and the 'cograph' rendering engine, so downstream bootstrap, permutation, reliability, centrality, and plotting functions treat each actor's codes as a distinct node group.

Authors:Sonsoles López-Pernas [aut, cre, cph], Kamila Misiejuk [aut, cph], Mohammed Saqr [aut, cph]

htna_0.1.0.tar.gz
htna_0.1.0.tar.gz(r-4.7-any)htna_0.1.0.tar.gz(r-4.6-any)
htna_0.1.0.tgz(r-4.6-emscripten)
manual.pdf |manual.html
DESCRIPTION |NEWS
card.svg |card.png
htna/json (API)

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

Bug tracker:https://github.com/sonsoleslp/htna/issues

Pkgdown/docs site:https://sonsoles.me

Datasets:

On CRAN:

Conda:

3.00 score 26 exports 34 dependencies

Last updated from:463bbc750c. Checks:4 OK. Indexed: no.

TargetResultTimeFilesSyslog
linux-devel-x86_64OK168
source / vignettesOK295
linux-release-x86_64OK169
wasm-releaseOK127

Exports:association_rules_htnabootstrapbootstrap_htnabuild_htnacasedrop_reliability_htnacentralities_htnacentrality_stability_htnaedge_betweenness_htnaextract_meta_pathsfrequencies_htnahtna_palettemarkov_order_test_htnamosaic_plot_htnapermutation_htnaplot_centralitiesplot_edge_betweenness_htnaplot_frequencies_htnaplot_htnaplot_htna_bootstrapplot_htna_diffplot_sequencesreliability_htnasequence_compare_htnasequence_plot_htnastate_distribution_htnastate_frequencies_htna

Dependencies:brglm2cliclustercographcpp11data.tableenrichwithfarverggplot2glassogluegtableigraphisobandlabelinglatticelifecyclemagrittrMASSMatrixNestimatenleqslvnnetnumDerivpkgconfigR6RColorBrewerrlangS7scalesstatmodvctrsviridisLitewithr

Getting Started with htna
1. Building a heterogeneous network | 2. Plotting the network | 3. Per-actor sequence plots | 4. Centralities | 5. Bootstrap | 6. Centrality stability | 7. Split-half reliability | 8. Comparing two networks | 9. Permutation test | 10. Path patterns

Last update: 2026-07-06
Started: 2026-07-06

Input formats for build_htna()
Setup | Form 1 — Named list of per-actor frames | Form 2 — Single combined frame with actor_type | Form 3 — Single combined frame with node_groups | 3a. Named list of code vectors | 3b. Two-column data frame (codebook) | All forms produce the same network | Handling code-label collisions with disambiguate = | Splitting into cohorts with group = | Cheat sheet

Last update: 2026-07-06
Started: 2026-07-06

Readme and manuals

Help Manual

Help pageTopics
Simplified AI Interaction Sequences (per-actor frame)ai_simplified
Association Rule Mining over Transitionsassociation_rules_htna
Bootstrap genericbootstrap
Bootstrap an HTNA Networkbootstrap.htna bootstrap_htna
Build a Heterogeneous Transition Network (HTNA)build_htna
Edge-Weight Case-Dropping Stabilitycasedrop_reliability_htna
Compute Centrality Measures for an htna Networkcentralities_htna
Centrality Stability for an htna Networkcentrality_stability_htna
Edge Betweenness Networkedge_betweenness_htna
Extract Path Patterns from a Heterogeneous Transition Networkextract_meta_paths
Tidy Per-Actor Frequency Table for an htna Networkfrequencies_htna
Default HTNA colour palettehtna_palette
Simplified Human + AI Interaction Sequenceshuman_ai
Code → Actor-Type Codebook for 'human_ai'human_ai_codebook
Simplified Human Interaction Sequences (per-actor frame)human_simplified
Markov-Order Adequacy Testmarkov_order_test_htna
Chi-square Mosaic Plot of a Transition Networkmosaic_plot_htna
Permutation Test for Network Differencespermutation_htna
Plot Centrality Measuresplot_centralities
Plot the Edge Betweenness Networkplot_edge_betweenness_htna
Plot State Frequencies (htna-named)plot_frequencies_htna
Plot a Heterogeneous Transition Networkplot.htna plot.htna_group plot_htna
Plot an htna Bootstrap Resultplot.htna_bootstrap plot_htna_bootstrap
Plot the Difference Between Two htna Networksplot_htna_diff
Sequence plot genericplot_sequences
Plot Method for htna Centrality Stability Objectsplot.htna_stability
Plot Method for htna Stability Groupsplot.htna_stability_group
Print Method for htna Centrality Stability Objectsprint.htna_stability
Print Method for htna Stability Groupsprint.htna_stability_group
Network Reliability for an htna Networkreliability_htna
Subsequence Pattern Comparison Across Groupssequence_compare_htna
Plot Per-Actor Sequences From an htna Networkplot_sequences.htna sequence_plot_htna
State Distribution Across Timestate_distribution_htna
Tidy State Frequency Tablestate_frequencies_htna
Summarise a Heterogeneous Transition Networksummary.htna summary.htna_group