View source: R/derive_structural_groups.R
| derive_structural_groups | R Documentation |
Derives lightweight structural aggregation metadata from observed relative filesystem paths.
The function identifies recurring structural patterns in directory hierarchies and creates candidate aggregations that can support exploratory analysis, navigation, contextual reconstruction, and later semantic interpretation.
The resulting groupings are derived solely from path structure. They are analytical projections rather than authoritative Record Sets, provenance assertions, or documentary relationships.
derive_structural_groups(rel_path, profile = "folder-depth-2")
rel_path |
Character vector of relative filesystem paths. |
profile |
Character scalar specifying the structural aggregation strategy. Available profiles are:
|
Structural aggregation metadata provides a lightweight abstraction of observed directory organisation. It can increase the informativeness of filesystem observations by exposing recurring organisational patterns without asserting semantic meaning.
Within the fscontext workflow:
filesystem observations provide evidence about observed resources;
relative paths provide structural organisation;
structural aggregations expose candidate groups that may later support contextual reconstruction, Record Set construction, semantic stabilisation, or other downstream analyses.
Future versions may introduce additional aggregation profiles based on repository structure, provenance, temporal patterns, or other observational evidence.
A data.frame with two columns:
Candidate structural aggregation derived from the selected path profile.
Immediate structural subdivision within the aggregation, when present.
rel_path <- c(
"_packages/demo/R/file.R",
"_packages/demo/tests/testthat/test-file.R",
"_packages/demo/data/input.csv"
)
derive_structural_groups(rel_path)
derive_structural_groups(
rel_path,
profile = "folder-depth-1"
)
derive_structural_groups(
c(
"archive/data.warc.gz",
"indexes/index.cdx",
"pages/pages.jsonl"
),
profile = "wacz"
)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.