Statalist


[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: RE: st: non-ascii character � and "unexpected end of file"


From   "Nick Cox" <[email protected]>
To   <[email protected]>
Subject   st: RE: st: non-ascii character � and "unexpected end of file"
Date   Mon, 20 Aug 2007 17:45:10 +0100

I would use -filefilter- or a file editor 
to change the unacceptable character to something 
acceptable for reading in and then reverse the 
process in Stata. -hexdump- will give you an idea 
of characters not present. @ is 
a character often not present, unless there
are email addresses, but easily used. 

Nick 
[email protected] 

Sergiy Radyakin
 
> Try the following:
> 
> di "This is `=char(255)' and this is y."

Eva Poen

> > while recoding a questionnaire that was originally conducted in
> > German, Arabic, and Russian, I hit the problem mentioned in this
> > thread:
> > http://www.stata.com/statalist/archive/2005-02/msg00316.html
> >
> > I am using Stata 9. I managed to read the data in all right 
> (they are
> > in various tab separated files), but I cannot manipulate a string
> > variable containing the character �. Since "�" is part of 
> some of the
> > answers to the questionnaire, and since I need to recode these, I
> > somehow have to get around it.
> >
> > While a do-file will stop upon seeing "�", the Stata 9 command line
> > will simply ignore it. Typing  -di "This is � and this is 
> y."- results
> > in
> >
> > . di "This is  and this is y."
> > This is  and this is y.
> >
> > I.e. the character � is simply swallowed.

*
*   For searches and help try:
*   http://www.stata.com/support/faqs/res/findit.html
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/



© Copyright 1996–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index