make_homopolymer_plot | R Documentation |
The function uses the output from function 'method_homopolymer_indels' to make a plot to compare how the accuracy vary according to the homopolymer length or not within homopolymers. Those accuracy measures can be either rates of TPs, FNs and FPs, or the precision, recall and F1-score.
make_homopolymer_plot(
input_hom_table,
variant_type,
method_name,
truth_name,
hom_length_intervals,
interval_names,
to_calculate
)
input_hom_table |
A data.frame. The output of the function 'method_homopolymer_indels'. |
variant_type |
A 1-length string. The variant type. Possivle values are: "snp", "deletion", or "insertion". |
method_name |
A 1-length string. The name of the method to analyse. |
truth_name |
A 1-length string. The name of the ground-truth. |
hom_length_intervals |
A vector of integers. Must be the same length of 'interval_names'. The inferior limit for each interval for homopolymer length. |
interval_names |
A vector of strings. Must be the same length of 'hom_length_intervals'. The name of each interval of homopolymer length. |
to_calculate |
A 1-length string. Possible values are: "rates" or "pre_rec_f1". |
A list, in which the first element, named 'p', is a ggplot object, and the second element, named 'interval_counts', is a named vector of integers that stores the counts of variants in each interval specified by the x-axis of the plot in 'p'.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.