Description Private Fields Private Methods Methods Examples
The check for loops runs on repeated depth-first-traversals of all vertices in the directed graph that represents a pedigree.
tbl_pedigreenode-list representation of pedigree as tibble
n_ani_colcolumn index for animal ids
n_sire_colcolumn index for sire ids
n_dam_colcolumn index for dam ids
l_set_wgblist of white, grey and black set
b_report_cycleFlag indicating whether vertices in a cycle must be reported
tbl_cycleTibble storing pairs of parent and offspring in the cycle
b_debugFlag for debugging mode
qprp_loggerLogger object from log4r
dfs(p_current_vertex)Depth-first-search starting at vertex p_current_vertex
move_grey_black(p_current_vertex)Move vertex p_current_vertex from grey set to black set
move_white_grey(p_current_vertex)Move vertex p_current_vertex from white set to grey set
get_neighbors(p_current_vertex)Find vector of neighbor vertices of current vertex p_current_vertex
new()Initialise fields in object at creation.
PedigreeCycleCheck$new()
read_pedigree()read pedigree from file given by ps_pedigree_path
PedigreeCycleCheck$read_pedigree( ps_pedigree_path, ps_delim = "|", pn_ani_col = 1, pn_sire_col = 2, pn_dam_col = 3, ... )
ps_pedigree_pathpath to pedigree input file
ps_delimdelimiting character between columns
pn_ani_colanimal id column
pn_sire_colsire id column
pn_dam_coldam id column
...additional arguments passed to readr::read_delim
tbl_pedigree pedigree as tibble
has_cycle()Run a depth-first traversal with all vertices (animals in the pedigree) until a cycle has been found.
PedigreeCycleCheck$has_cycle()
set_tbl_pedigree()Setter method for the field tbl_pedigree
PedigreeCycleCheck$set_tbl_pedigree(ptbl_pedigree)
ptbl_pedigreecurrent tibble with pedigree
set_n_ani_col()Setter method for n_ani_col
PedigreeCycleCheck$set_n_ani_col(pn_ani_col)
pn_ani_colcurrent value for index of animal column
set_n_sire_col()Setter method for n_sire_col
PedigreeCycleCheck$set_n_sire_col(pn_sire_col)
pn_sire_colcurrent value for index of sire column
set_n_dam_col()Setter method for n_dam_col
PedigreeCycleCheck$set_n_dam_col(pn_dam_col)
pn_dam_colcurrent value for index of dam column
set_b_report_cycle()Setter method for b_report_cycle
PedigreeCycleCheck$set_b_report_cycle(pb_report_cycle)
pb_report_cyclecurrent value for b_report_cycle
set_b_debug()Setter method for b_debug
PedigreeCycleCheck$set_b_debug(pb_debug)
pb_debugcurrent value of b_debug to be set
get_tbl_cycle()Getter method for tbl_cycle
PedigreeCycleCheck$get_tbl_cycle()
tbl_cycle tibble with parent offspring pairs in cycle
clone()The objects of this class are cloneable with this method.
PedigreeCycleCheck$clone(deep = FALSE)
deepWhether to make a deep clone.
1 2 3 4 5 6 | ## Not run:
pcc <- PedigreeCycleCheck$new()
pcc$read_pedigree(ps_pedigree_path = system.file('extdata','data_sample2.csv', package = 'qprppedigree'))
pcc$has_cycle()
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.