Validates that the actual chromosome lengths in a simulated genome match their expected lengths. Checks both maternal and paternal copies of each chromosome.

check_genome_chr_length(clone_genome, expected_chr_lengths)

Arguments

clone_genome

A nested list containing genome sequences:

  • First level: haplotypes (maternal/paternal)

  • Second level: chromosomes with nucleotide sequences

expected_chr_lengths

A nested list containing expected chromosome lengths:

  • First level: haplotypes (maternal/paternal)

  • Second level: named numeric vector of chromosome lengths

Value

A nested list where:

  • First level: haplotypes (maternal/paternal)

  • Second level: chromosomes

  • Values are status messages indicating whether lengths match or not, including both expected and actual lengths when there's a mismatch

Details

The function:

  1. Checks each chromosome in both maternal and paternal copies

  2. Compares actual sequence length to expected length

  3. Generates informative messages about matches and mismatches

  4. Useful for validating genome synthesis results

Examples

if (FALSE) { # \dontrun{
validation_results <- check_genome_chr_length(
  clone_genome = synthesized_genome,
  expected_chr_lengths = expected_lengths
)
# Access results for specific chromosomes
validation_results$maternal$chr1  # Check maternal chr1 status
} # }