tx_subsumes: Test subsumption between codings

View source: R/udfs.R

tx_subsumesR Documentation

Test subsumption between codings

Description

Takes two Coding columns as input. Returns a Column that contains a Boolean value, indicating whether the left Coding subsumes the right Coding.

Usage

tx_subsumes(left_codings, right_codings)

Arguments

left_codings

A Column containing a struct representation of a Coding or an array of Codings.

right_codings

A Column containing a struct representation of a Coding or an array of Codings.

Value

A Column containing the result of the operation (boolean).

See Also

Pathling documentation - Subsumption testing

Other terminology functions: tx_display(), tx_member_of(), tx_property_of(), tx_subsumed_by(), tx_translate()

Examples

## Not run: 
# Test the codings of the Condition `code` for subsumption of a SNOMED CT code.
pc %>%
  pathling_example_resource("Condition") %>%
  sparklyr::mutate(
    id,
    subsumes = !!tx_subsumes(
      code[["coding"]],
      !!tx_to_snomed_coding("444814009")
    ),
    .keep = "none"
  )

## End(Not run)

pathling documentation built on June 3, 2026, 9:08 a.m.