Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

Re: st: Easy way to export Stata output to Excel versions with different decimal separator


From   Ulrich Kohler <[email protected]>
To   [email protected]
Subject   Re: st: Easy way to export Stata output to Excel versions with different decimal separator
Date   Thu, 15 May 2003 17:06:09 +0200

Dr. Gawrich, Stefan wrote:
> I often have to copy Stata-Output (mostly tables) into Excel.
> The german Excel version uses (like in many other european countries) the
> "," as decimal separator instead of the ".".
> Using "Copy-Table" and "Paste" I get errors (e.g. automatic transformation
> of numbers into dates) so I always have to do some editing tricks to get it
> right.
>
> In Stata related help stuff I didn't find Information on this problem.
> In Excel support pages and newsgroups the most given suggestion is to
> change country preferences (which would affect all Software on the user
> account) But at last I found an easier solution, hope it is useful for some
> of you:
>
>
> In Stata mark the output and just copy (STRG-C), not Copy Table
>
> Paste into Excel. The column which contains the whole copied data must be
> marked.
>
> Menu DATA -> Text to Columns
>
> Normally "Fixed Width" will do for Stata Tables -> Next
>
> Adjust columns if necessary  -> Next
>
> Now the most important part: Click "Advanced" and choose the decimal
> seperator (in the case of Stata output ".")  -> O.K. -> Finish

And, as an alternative, you might change the decimal-point in Stata to comma 
by

. set dp comma

regards
uli

-- 
[email protected]


*
*   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