get_ancestors: Identify all ancestors for an individual

View source: R/identify.R

get_ancestorsR Documentation

Identify all ancestors for an individual

Description

This function identifies records in an entire branch of the family tree above a certain individual.

Usage

get_ancestors(
  gedcom,
  indi_xref = character(),
  inc_indi = FALSE,
  inc_sibs = FALSE,
  inc_famg = FALSE,
  inc_supp = FALSE,
  birth_only = TRUE
)

Arguments

gedcom

A tidyged object.

indi_xref

The xref of an Individual record to act on if one is not activated (will override active record).

inc_indi

Whether to also include the individual themselves.

inc_sibs

Whether to also include all siblings of ancestors (siblings of this individual will only be included if the individual is included).

inc_famg

Whether to also include all Family Group records where this individual is a child (and all ancestors' Family Group records).

inc_supp

Whether to also include all supporting records (Note, Source, Repository, Multimedia).

birth_only

Whether to only include biological ancestors.

Value

A vector of xrefs of ancestors.

Examples

get_ancestors(sample555, "@I3@")
get_ancestors(sample555, "@I3@", inc_indi = TRUE)
get_ancestors(sample555, "@I3@", inc_indi = TRUE, inc_famg = TRUE)

jl5000/tidygedcom documentation built on June 22, 2022, 5:16 p.m.