Parse a formula defining the conditions to pick a stat/test
parse_formula(x, f)
The variable to test it on
A formula to parse
A function to use as a stat/test
Parse a formula defining the conditions to pick a stat/test and return the function to use. The formula is to be given in the form of conditional ~ T | F and conditions can be nested such as conditional1 ~ (conditional2 ~ T | F) | F The FALSE option can be omitted, and the TRUE can be replaced with NA