24 Developer function index
This index covers package-owned R and Rust definitions. Internal functions do not form a stable user API. Scientific algorithms will receive explanations and numerical demonstrations in the relevant chapters; validation, formatting, and storage helpers remain in the reference index.
R-to-Rust wrappers and their compiled kernels are listed separately because they are distinct definitions of the same interface. Local R helpers are scoped to their enclosing functions. Rust test definitions are separate from production code. Anonymous callbacks, vendored dependencies, development scripts, and historical sources in context/ are outside this index.
Use the browser’s find command or book search to locate a function. A standalone searchable inventory provides category filters. Its JSON data are also available for programmatic use.
24.1 Modern internal R
Package-level implementation functions, including scientific algorithms, validation, formatting, I/O, and runtime support.
24.2 Legacy internal R
Private helpers supporting the frozen create_phenotypes() engine.
24.3 R-to-Rust bindings
Seven R wrappers for compiled Rust entry points; these are not seven additional scientific methods.
| Definition | Enclosing scope | Source |
|---|---|---|
numericalize_core |
— | R/extendr-wrappers.R:33 |
meiosis_core |
— | R/extendr-wrappers.R:55 |
mate_haplotypes_core |
— | R/extendr-wrappers.R:82 |
mate_many_core |
— | R/extendr-wrappers.R:110 |
gamete_masks_core |
— | R/extendr-wrappers.R:125 |
stable_hash_core |
— | R/extendr-wrappers.R:131 |
coalescent_chromosome_core |
— | R/extendr-wrappers.R:143 |
24.4 Local R helpers
Named functions defined inside another function. Scope identifies the enclosing function; these are not independently callable package functions.
| Definition | Enclosing scope | Source |
|---|---|---|
make_one |
.draw_qtn_pairs | R/arch_independent.R:94 |
chr_block |
.draw_qtn_ld | R/arch_ld.R:91 |
window_partners |
.draw_qtn_ld | R/arch_ld.R:102 |
r_pair |
.draw_qtn_ld | R/arch_ld.R:121 |
r2_pair |
.draw_qtn_ld | R/arch_ld.R:128 |
per_trait |
.ld_prior_loci | R/arch_ld.R:398 |
record |
crossbreed | R/cross_breed.R:271 |
gen_cross |
crossbreed | R/cross_breed.R:278 |
zero_one |
population_from_haplotypes | R/cross_haplotypes.R:143 |
pick |
mate | R/cross_mate.R:126 |
ids_of |
mating_design | R/cross_mate.R:369 |
key_of |
mating_design | R/cross_mate.R:380 |
ok |
mating_design | R/cross_mate.R:430 |
try_slot |
mating_design | R/cross_mate.R:432 |
sub |
.check_interference | R/cross_mating.R:144 |
num1 |
.check_interference | R/cross_mating.R:167 |
digit_strand |
.founder_pedigree | R/cross_pedigree.R:110 |
strand_part |
.founder_pedigree | R/cross_pedigree.R:113 |
st |
.mating_pedigree | R/cross_pedigree.R:203 |
pid |
parentage | R/cross_pedigree.R:271 |
pid |
families | R/cross_pedigree.R:315 |
close_to |
.same_map | R/cross_population.R:420 |
draw |
phenotype_value | R/cross_population.R:1078 |
scale_idx |
.pleio_draw | R/effects_pleioarch.R:202 |
spec_rows |
.pleio_units | R/effects_pleioarch.R:557 |
as_units |
.pleio_unit_effects | R/effects_pleioarch.R:588 |
pick |
.pleio_total_cor_check | R/effects_pleioarch.R:741 |
fmt |
.pleio_total_cor_check | R/effects_pleioarch.R:749 |
per_chr |
founders_coalescent | R/founders_coalescent.R:202 |
eff_for |
additive | R/grammar_layers.R:287 |
build |
additive | R/grammar_layers.R:291 |
eff_for |
dominance | R/grammar_layers.R:521 |
build |
dominance | R/grammar_layers.R:565 |
eff_for |
epistasis | R/grammar_layers.R:788 |
build |
epistasis | R/grammar_layers.R:790 |
build |
vqtl | R/grammar_layers.R:959 |
as_idx |
.resolve_qtn_arg | R/grammar_layers.R:1280 |
to_idx |
.resolve_epi_qtn | R/grammar_layers.R:1366 |
to_mat |
.resolve_epi_qtn | R/grammar_layers.R:1382 |
loci |
.ad_partition | R/grammar_realize.R:873 |
scaled |
.ad_partition | R/grammar_realize.R:879 |
walk |
.small_expr | R/grammar_simulate_phenotype.R:585 |
fmt |
print.phenotype_sim | R/grammar_simulate_phenotype.R:1102 |
is_letter |
parse_hapmap_chars_to_raw | R/io_detect_format.R:238 |
.rows |
parse_hapmap_chars_to_raw | R/io_detect_format.R:302 |
grab |
handle_vcf | R/io_read_formats.R:715 |
find_col |
handle_finalreport | R/io_read_formats.R:949 |
write_pheno |
write_phenotypes | R/io_write.R:246 |
rollback |
.commit_staged | R/io_write.R:816 |
enc |
.json_classed_elements | R/io_write.R:1140 |
block |
qtn_table | R/io_write.R:1417 |
gene_block |
qtn_table | R/io_write.R:1442 |
numify |
genotypes | R/legacy_Genotypes.R:69 |
numeric_df |
genotypes | R/legacy_Genotypes.R:79 |
read_one |
genotypes | R/legacy_Genotypes.R:122 |
pair_ld |
.ld_check_indirect | R/legacy_QTN_linkage.R:1922 |
out |
.ld_check_indirect | R/legacy_QTN_linkage.R:1930 |
differs |
.ld_check_indirect | R/legacy_QTN_linkage.R:1935 |
chk |
.check_partial_counts | R/legacy_QTN_partially_pleiotropic.R:875 |
chk_eff |
.check_partial_counts | R/legacy_QTN_partially_pleiotropic.R:889 |
whole1 |
.v1_validate_basic | R/legacy_check_in.R:1165 |
ok |
.v1_validate_ld | R/legacy_check_in.R:1224 |
worst_of |
.v1_validate_seed_arith | R/legacy_check_in.R:1285 |
ok |
.v1_validate_seed_arith | R/legacy_check_in.R:1294 |
accepted |
.v1_validate_seed_arith | R/legacy_check_in.R:1331 |
chk |
.v1_validate_effects | R/legacy_check_in.R:1414 |
g |
.v1_check_qtn_capacity | R/legacy_check_in.R:1505 |
cleanup_outputs |
create_phenotypes | R/legacy_create_phenotypes.R:552 |
note |
filter_geno | R/qc_filter_geno.R:304 |
whole |
.ld_spec | R/qc_filter_geno.R:429 |
lg |
.ld_sweep | R/qc_filter_geno.R:578 |
sg |
.ld_sweep | R/qc_filter_geno.R:579 |
ls |
.ld_sweep | R/qc_filter_geno.R:585 |
ss |
.ld_sweep | R/qc_filter_geno.R:590 |
is_pruned |
.ld_sweep | R/qc_filter_geno.R:591 |
set_pruned |
.ld_sweep | R/qc_filter_geno.R:592 |
maf_of |
.ld_sweep | R/qc_filter_geno.R:593 |
cor_sub |
.ld_sweep | R/qc_filter_geno.R:594 |
is_singular |
.ld_sweep | R/qc_filter_geno.R:600 |
win_at |
.ld_sweep | R/qc_filter_geno.R:605 |
clq |
.plink_blocks_classify | R/qc_filter_geno.R:1005 |
counts_of |
.plink_blocks_chrom | R/qc_filter_geno.R:1076 |
bad |
.founder_inbreeding | R/select_blup.R:114 |
one |
.mt_variances | R/select_blup.R:474 |
ok |
.blup_variances | R/select_blup.R:683 |
m |
selection_methods | R/select_blup.R:778 |
obj_of |
.bqp_solve | R/select_bqp.R:134 |
feas_of |
.bqp_solve | R/select_bqp.R:137 |
pen_of |
.bqp_solve | R/select_bqp.R:182 |
p2 |
.index_weights | R/select_ind.R:813 |
coan_at |
.tune_lambda | R/select_ocs.R:664 |
done |
.tune_lambda | R/select_ocs.R:668 |
bad |
.check_backed | R/select_schemes.R:450 |
draw |
observe_counts | R/transcriptome_counts.R:95 |
build |
transcriptome | R/transcriptome_layer.R:259 |
draw |
transcriptome / build | R/transcriptome_layer.R:260 |
negll |
.greml_h2 | R/transcriptome_mimic.R:76 |
run |
simulate_transcriptome | R/transcriptome_simulate.R:405 |
z1 |
simulate_transcriptome / run | R/transcriptome_simulate.R:492 |
draw_resid |
predict.transcriptome_sim | R/transcriptome_simulate.R:892 |
z1 |
predict.transcriptome_sim / draw_resid | R/transcriptome_simulate.R:893 |
draw |
.tx_synthetic_coords | R/transcriptome_simulate.R:1062 |
24.5 Rust implementation
Functions and associated methods in the package-owned Rust source. Rust pub visibility does not make a function part of the exported R API.
24.6 Rust tests and test helpers
Verification code, separated from implemented methods. Includes the test-specific Bits::tail_is_clean definition.
| Definition | Enclosing scope | Source |
|---|---|---|
Tree::lineages_at |
test configuration | src/rust/src/coalescent.rs:413 |
Tree::lineages_crossing |
test configuration | src/rust/src/coalescent.rs:502 |
harmonic |
test configuration | src/rust/src/coalescent.rs:832 |
xoshiro_reference_stream |
test configuration | src/rust/src/coalescent.rs:837 |
unif_and_below_are_in_range |
test configuration | src/rust/src/coalescent.rs:847 |
kingman_tmrca_mean_constant_size |
test configuration | src/rust/src/coalescent.rs:857 |
kingman_length_mean_is_harmonic |
test configuration | src/rust/src/coalescent.rs:876 |
pair_tmrca_under_a_size_change |
test configuration | src/rust/src/coalescent.rs:894 |
tree_at_end |
test configuration | src/rust/src/coalescent.rs:916 |
smc_prime_keeps_the_marginal_tree_kingman |
test configuration | src/rust/src/coalescent.rs:929 |
marginal_tree_follows_the_demography_after_recombination |
test configuration | src/rust/src/coalescent.rs:958 |
tree_stays_consistent_through_recombination |
test configuration | src/rust/src/coalescent.rs:977 |
seeded_runs_reproduce |
test configuration | src/rust/src/coalescent.rs:1005 |
reservoir_keeps_the_requested_number_in_order |
test configuration | src/rust/src/coalescent.rs:1014 |
overflowing_rates_are_errors_not_hangs |
test configuration | src/rust/src/coalescent.rs:1028 |
extreme_history_sizes_are_errors_not_panics |
test configuration | src/rust/src/coalescent.rs:1034 |
lineage_sampler_is_uniform_over_the_lineages_at_tau |
test configuration | src/rust/src/coalescent.rs:1058 |
two_locus_correlation_is_smc_prime_not_smc |
test configuration | src/rust/src/coalescent.rs:1088 |
check_split_invariants |
test configuration | src/rust/src/coalescent.rs:1125 |
split_keeps_demes_isolated_until_the_join |
test configuration | src/rust/src/coalescent.rs:1151 |
between_deme_pair_tmrca_is_join_plus_half |
test configuration | src/rust/src/coalescent.rs:1167 |
within_deme_sample_before_a_late_join_is_kingman |
test configuration | src/rust/src/coalescent.rs:1205 |
split_inputs_are_validated |
test configuration | src/rust/src/coalescent.rs:1227 |
Bits::from_code |
test configuration | src/rust/src/genome.rs:94 |
Bits::tail_is_clean |
test configuration | src/rust/src/genome.rs:159 |
all_ones_via_flip_all_keeps_the_tail_clean |
test configuration | src/rust/src/genome.rs:294 |
flip_all_is_an_involution_and_keeps_tail_clean |
test configuration | src/rust/src/genome.rs:307 |
toggle_from_covers_the_suffix_only |
test configuration | src/rust/src/genome.rs:324 |
toggle_from_at_or_past_n_is_a_noop |
test configuration | src/rust/src/genome.rs:338 |
toggle_from_twice_cancels |
test configuration | src/rust/src/genome.rs:351 |
code_round_trips_ascending |
test configuration | src/rust/src/genome.rs:363 |
genotype_uses_loci_major_layout |
test configuration | src/rust/src/genome.rs:374 |
genotype_is_symmetric_in_the_two_strands_only_for_homozygotes |
test configuration | src/rust/src/genome.rs:396 |
layout_rejects_mismatched_counts |
test configuration | src/rust/src/genome.rs:410 |
layout_rejects_empty_chromosome_na_and_no_chromosomes |
test configuration | src/rust/src/genome.rs:418 |
layout_rejects_non_finite_and_decreasing_positions_but_allows_ties |
test configuration | src/rust/src/genome.rs:426 |
strands_must_match_the_layout_and_the_binary_alphabet |
test configuration | src/rust/src/genome.rs:436 |
layout_slices_chromosomes_in_order |
test configuration | src/rust/src/genome.rs:446 |
empty_input_is_the_offset_basis |
test configuration | src/rust/src/hash.rs:44 |
prime_is_two_pow_88_plus_two_pow_8_plus_0x3b |
test configuration | src/rust/src/hash.rs:49 |
known_answer_vectors |
test configuration | src/rust/src/hash.rs:54 |
distinct_inputs_differ_and_repeat_equally |
test configuration | src/rust/src/hash.rs:68 |
pos |
test configuration | src/rust/src/meiosis.rs:770 |
layout |
test configuration | src/rust/src/meiosis.rs:774 |
stream |
test configuration | src/rust/src/meiosis.rs:778 |
breaks_counts_positions_at_or_below_the_chiasma |
test configuration | src/rust/src/meiosis.rs:788 |
a_chiasma_exactly_on_a_marker_leaves_it_upstream |
test configuration | src/rust/src/meiosis.rs:797 |
zero_chiasmata_gives_all_zero_or_all_one_by_the_flip |
test configuration | src/rust/src/meiosis.rs:807 |
one_chiasma_toggles_the_downstream_segment_inclusively |
test configuration | src/rust/src/meiosis.rs:816 |
a_chiasma_upstream_of_the_first_marker_toggles_everything |
test configuration | src/rust/src/meiosis.rs:826 |
two_chiasmata_restore_the_intervening_segment |
test configuration | src/rust/src/meiosis.rs:834 |
duplicate_chiasmata_cancel_and_order_is_irrelevant |
test configuration | src/rust/src/meiosis.rs:841 |
single_locus_chromosome |
test configuration | src/rust/src/meiosis.rs:854 |
event_stream_slices_ragged_blocks_in_order |
test configuration | src/rust/src/meiosis.rs:863 |
err_of |
test configuration | src/rust/src/meiosis.rs:881 |
event_stream_rejects_a_count_chiasmata_mismatch |
test configuration | src/rust/src/meiosis.rs:889 |
event_stream_rejects_negative_and_na_counts |
test configuration | src/rust/src/meiosis.rs:901 |
event_stream_rejects_non_binary_flips |
test configuration | src/rust/src/meiosis.rs:910 |
event_stream_rejects_ragged_shapes |
test configuration | src/rust/src/meiosis.rs:919 |
event_stream_rejects_non_finite_and_out_of_range_chiasmata |
test configuration | src/rust/src/meiosis.rs:926 |
chiasma_range_is_per_chromosome |
test configuration | src/rust/src/meiosis.rs:944 |
genome_mask_concatenates_chromosomes_ascending |
test configuration | src/rust/src/meiosis.rs:952 |
recombine_picks_cis_where_the_mask_is_set |
test configuration | src/rust/src/meiosis.rs:960 |
dh_progeny_are_fully_homozygous |
test configuration | src/rust/src/meiosis.rs:968 |
cross_takes_cis_from_the_first_parent |
test configuration | src/rust/src/meiosis.rs:977 |
events_are_consumed_progeny_major |
test configuration | src/rust/src/meiosis.rs:989 |
dh_haplotypes_are_segments_of_the_parent_strands_not_the_mask |
test configuration | src/rust/src/meiosis.rs:1002 |
mate_core_agrees_with_mate_haplotypes |
test configuration | src/rust/src/meiosis.rs:1024 |
the_event_budget_must_match_n_prog_exactly |
test configuration | src/rust/src/meiosis.rs:1037 |
progeny_count_rejects_na_and_negative |
test configuration | src/rust/src/meiosis.rs:1057 |
parents_must_match_the_layout |
test configuration | src/rust/src/meiosis.rs:1065 |
design_parsing_and_event_budget |
test configuration | src/rust/src/meiosis.rs:1074 |
entry_points_return_errors_not_panics |
test configuration | src/rust/src/meiosis.rs:1085 |
bits_to_i32 |
test configuration | src/rust/src/meiosis.rs:1151 |
mate_many_equals_sequential_mate_haplotypes |
test configuration | src/rust/src/meiosis.rs:1159 |
mate_many_rejects_inconsistent_inputs |
test configuration | src/rust/src/meiosis.rs:1225 |
mate_many_core_returns_errors_not_panics |
test configuration | src/rust/src/meiosis.rs:1254 |
run |
test configuration | src/rust/src/numeric.rs:253 |
additive_101_unflipped_and_flipped |
test configuration | src/rust/src/numeric.rs:266 |
each_snp_uses_its_own_flip |
test configuration | src/rust/src/numeric.rs:284 |
full_valid_grid_matches_an_independent_mapper |
test configuration | src/rust/src/numeric.rs:293 |
malformed_inputs_are_errors_not_defaults |
test configuration | src/rust/src/numeric.rs:362 |
size_args_reject_na_and_negative |
test configuration | src/rust/src/numeric.rs:385 |