prepare_resource: Download, harmonize, and import an author-released network

View source: R/network-resources.R

prepare_resourceR Documentation

Download, harmonize, and import an author-released network

Description

This high-level interface implements the resource workflow represented by network_catalog(). It never runs implicitly: callers must provide an explicit cache directory, and large resources require confirmation.

Usage

prepare_resource(
  id,
  cache_dir,
  mappings = NULL,
  n_top = NULL,
  allow_large = FALSE,
  paths = NULL,
  universe = NULL,
  mapper = NULL,
  chunk_size = 100000L,
  min_score = NULL,
  quiet = FALSE
)

Arguments

id

Resource identifier or specification.

cache_dir

Explicit cache root.

mappings

Optional identifier mappings from load_id_mappings().

n_top

Optional number of highest-scoring mapped edges.

allow_large

Confirm a resource marked as a large download.

paths

Optional named paths returned by download_resource().

universe

Optional vector restricting both mapped endpoints.

mapper

Optional endpoint mapping function, overriding mappings.

chunk_size

Positive number of source rows parsed per chunk.

min_score

Optional minimum author score.

quiet

Suppress download progress.

Value

An undirected igraph network with a provenance manifest available through manifest().


NEArender documentation built on Nov. 28, 2026, 5:10 p.m.