Skip to contents

[Stable]

Issues a SELECT ?s ?o WHERE { ?s P ?o } query where P is the supplied predicate. The predicate position is constant. Both subject and object are bound. This is a single triple match, the only pattern shape librdf reliably plans on graphs of cybedtools' scale.

Usage

sparql_pairs(rdf, predicate)

Arguments

rdf

An rdf object from rdflib::rdf_parse() or load_combined_ntriples_graph().

predicate

Character. A SPARQL predicate (e.g., "cybed:partOf", "schema:name", "a"). Use the prefixed form. default_prefixes() supplies cybed, schema, rdfs, and skos.

Value

A tibble with columns s (character, subject URI) and o (character, object value, either URI or literal).

Examples

if (FALSE) { # \dontrun{
rdf <- load_combined_ntriples_graph()
sparql_pairs(rdf, "cybed:jurisdiction")
} # }