col2factor function

Transform defined columns to factor.