If one attempts to use _svmat- with the -names(col)- option, the error message "invalid syntax" will usually come up if a column name is not a legitimate variable name. This message is unhelpful. In this situation, I suggest the error message should be changed to something like "the name(s) for some column(s) are not a legitimate variable names", or even better, list the columns with illegitimate names.
Still better would be an automatic modification to a legitimate variable name as when reading in headers off a non-Stata file. This actually happens in one case only - when the last column (no other one) contains a space in what would otherwise be a legitimate variable name string.
Al Feiveson
*
* For searches and help try:
* http://www.stata.com/help.cgi?search
* http://www.stata.com/support/statalist/faq
* http://www.ats.ucla.edu/stat/stata/