MATLAB: Change table variable data type

MATLABtable

I used readtable() to read a text file into a table. One of the columns of the table was read (by default) as a double rather than a string. How does one change a columns datatype within a table?

Best Answer

Change it before reading it in by modifying the options passed to readtable.
Or
t.Var1 = num2str(t.Var1)