Learn R Programming

pensar (version 0.4.2)

outlinks: Outlink discovery

Description

Find the pages a given page cites via wikilinks. Find outlinks from a page

Scans a single page for [[wikilinks]] and returns the targets. Mirror of backlinks() in the forward direction.

Usage

outlinks(page, vault = default_vault())

Value

A data.frame with columns target (page name) and

exists (logical: whether the target page exists in the vault).

Arguments

page

Page name (without .md extension).

vault

Path to the vault directory.

Examples

Run this code
v <- tempfile("vault-")
init_vault(v, rproj = FALSE, agent_instructions = FALSE)
fp <- ingest("Cites [[seed]] and [[missing]].", type = "articles",
             source = "demo", vault = v)
outlinks(tools::file_path_sans_ext(basename(fp)), vault = v)
unlink(v, recursive = TRUE)

Run the code above in your browser using DataLab