modPedigreeServer: Pedigree Browser Module - Server Function

View source: R/modPedigree.R

modPedigreeServerR Documentation

Pedigree Browser Module - Server Function

Description

Server logic for pedigree browser module handling focal animal selection, pedigree processing, filtering, and data export.

Usage

modPedigreeServer(id, studbook)

Arguments

id

character vector of length 1. Module namespace identifier.

studbook

reactive returning the cleaned studbook data from modInput.

Details

This module processes the studbook by:

  • Adding a population column via setPopulation()

  • Adding a pedNum column via findPedigreeNumber()

  • Ensuring a gen column exists via findGeneration()

  • Optionally trimming to the ancestors and descendants of focal animals via trimPedigree() and getDescendantPedigree()

Value

A list of reactive values:

  • pedigree - Filtered pedigree for display (respects trim/unknown settings)

  • processedPedigree - Full pedigree with population, pedNum, gen columns

  • focalAnimals - Character vector of focal animal IDs

  • nAnimals - Count of animals in filtered pedigree

  • populationCount - Count of animals marked as population

  • isReady - Logical indicating if pedigree data is ready

See Also

modPedigreeUI for the UI component

setPopulation for population marking

trimPedigree for pedigree trimming

findPedigreeNumber for pedigree numbering

findGeneration for generation calculation

Other Shiny modules: modBreedingGroupsServer(), modBreedingGroupsUI(), modGeneticDiversityServer(), modGeneticDiversityUI(), modGeneticValueServer(), modGeneticValueUI(), modGvAndBgDescServer(), modGvAndBgDescUI(), modInputServer(), modInputUI(), modORIPReportingServer(), modORIPReportingUI(), modPedigreeUI(), modPotentialParentsServer(), modPotentialParentsUI(), modPyramidServer(), modPyramidUI(), modSummaryStatsServer(), modSummaryStatsUI()


nprcgenekeepr documentation built on July 26, 2026, 5:06 p.m.