get_haplotypes_individuals(individuals)

Arguments

individuals

Individuals to get haplotypes for.

Value

Matrix of haplotypes where row i is the haplotype of individuals[[i]].

Examples

sim <- sample_geneology(100, 10)
peds <- build_pedigrees(sim$population)
pedigrees_all_populate_haplotypes(peds, 2, c(1, 1))
get_haplotypes_individuals(sim$end_generation_individuals)
#>        [,1] [,2]
#>   [1,]    3    3
#>   [2,]    5   -5
#>   [3,]   -3    1
#>   [4,]    1    3
#>   [5,]    1    1
#>   [6,]    1    5
#>   [7,]    1    1
#>   [8,]    5   -7
#>   [9,]    1   -1
#>  [10,]   -3   -5
#>  [11,]   -1    3
#>  [12,]    1   -1
#>  [13,]   -1    3
#>  [14,]    1    1
#>  [15,]    1   -3
#>  [16,]   -3    3
#>  [17,]   -1   -3
#>  [18,]   -5    1
#>  [19,]   -5    1
#>  [20,]    1    3
#>  [21,]    3    3
#>  [22,]   -3    3
#>  [23,]   -1    3
#>  [24,]   -1    1
#>  [25,]   -3    1
#>  [26,]    1    5
#>  [27,]   -3    1
#>  [28,]    5    1
#>  [29,]   -1   -1
#>  [30,]    3   -7
#>  [31,]   -3   -1
#>  [32,]    1    3
#>  [33,]    3    1
#>  [34,]    1   -1
#>  [35,]    1   -1
#>  [36,]    3   -3
#>  [37,]   -1    7
#>  [38,]   -1    3
#>  [39,]    3   -5
#>  [40,]    1   -1
#>  [41,]   -1    5
#>  [42,]    5   -3
#>  [43,]   -1   -5
#>  [44,]   -3   -3
#>  [45,]   -1    3
#>  [46,]   -1    3
#>  [47,]    1   -3
#>  [48,]   -3    5
#>  [49,]   -1    5
#>  [50,]   -3   -1
#>  [51,]    1    5
#>  [52,]    1    5
#>  [53,]   -1    5
#>  [54,]   -1   -1
#>  [55,]    3    5
#>  [56,]    1    5
#>  [57,]    3   -3
#>  [58,]   -3   -3
#>  [59,]    1    1
#>  [60,]    5   -3
#>  [61,]   -1   -3
#>  [62,]    1   -5
#>  [63,]    1    1
#>  [64,]    3   -3
#>  [65,]   -3    1
#>  [66,]   -3    3
#>  [67,]    1   -1
#>  [68,]    3    7
#>  [69,]    3   -1
#>  [70,]   -1   -5
#>  [71,]    1   -7
#>  [72,]    3    1
#>  [73,]   -1   -5
#>  [74,]    3   -7
#>  [75,]   -5   -5
#>  [76,]   -1   -1
#>  [77,]    3    1
#>  [78,]    3   -7
#>  [79,]    3    5
#>  [80,]   -1    5
#>  [81,]    1    3
#>  [82,]    1   -3
#>  [83,]   -1    5
#>  [84,]    3   -3
#>  [85,]   -1    3
#>  [86,]    3    3
#>  [87,]   -5    1
#>  [88,]   -1    3
#>  [89,]   -1    5
#>  [90,]    1   -1
#>  [91,]   -1    7
#>  [92,]   -5    1
#>  [93,]   -1    1
#>  [94,]   -5   -5
#>  [95,]    3    3
#>  [96,]    1   -1
#>  [97,]    3   -1
#>  [98,]   -1   -5
#>  [99,]    1   -1
#> [100,]    1    5