Character vectors are converted to factors (#1)

Character vectors in data are converted to factors, addressing issue #1.

Added appropriate unit test.