# Convert input word into vector matrix

I wold like some help of converting an input (word or number or mix) into a single row vector, such as the following:

If input is ">DAVID123<" I want it to be as {>,D,A,V,I,D,1,2,3,<}

where all letters considered as unknown variables.

Try

ToExpression[Select[Characters[">DAVID123<" ],StringMatchQ[#,LetterCharacter]&]]


which will give you a vector of

{D,A,V,I,D}


as symbols or variables, but C and D and E and I and K have predefined meaning inside of Mathematica and may cause you grief.

• what about the < and > can I convert them into 0 ? Also where are the numbers {1,2,3} ? – Love Eva Sep 17 at 6:39
• This ToExpression[Characters[StringReplace[">DAVID123<",PunctuationCharacter:>"0"]]] gives you `{0,D,A,V,I,D,1,2,3,0} – Bill Sep 17 at 8:06