
Convert simple text fractions to numeric values
frac_to_num.RdParses character strings of the form "a/b" and returns their numeric
value \(a/b\). Intended for ordering or comparing simple fractions.
Examples
frac_to_num(c("1/4", "1/2", "3/4"))
#> [1] 0.25 0.50 0.75