rm_fromto <- function(str) sub("^(from|to)_", "", str)

extract_fromto <- function(str) extract("^(from|to)_", str)
