This function takes a genomic position and a CIGAR string as input and extracts information about indels. It processes the CIGAR string to determine the genomic positions, lengths, and indel type.

get_indel_info(pos, cigar)

Arguments

pos

An integer representing the starting genomic position of the CIGAR string.

cigar

A character string representing the CIGAR format.

Value

A list containing the following elements: - genomic_pos: An integer vector of the genomic positions of the indels. - indel_length: An integer vector of the lengths of the indels. - indel_type: A character vector of the types of the indels (either 'I' for insertion or 'D' for deletion).