Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
st: Stata crashes when loading a dataset
From
Dan Blanchette <[email protected]>
To
[email protected]
Subject
st: Stata crashes when loading a dataset
Date
Wed, 25 May 2011 09:54:06 -0400 (EDT)
I fell upon an odd situation where Stata 11 crashed when I tried to load
a dataset that I downloaded from the internet (from a site in a foreign
country) when I used the -use- command like so:
. use "C:\data\foreign_data.dta"
The person supplying the dataset reported that the dataset loaded fine
for him on his computer. In the process of trying to figure out a way
to get Stata to load the dataset without crashing, I stumbled on an odd
solution. All I had to do was specify a varlist like so:
. use * using "C:\data\foreign_data.dta"
and Stata loaded the whole dataset just fine. I discovered that the
dataset contained almost all numeric variables. The one string variable
had no foreign characters. The dataset nor variables had any notes. Two
of the numeric variables had two value labels that had 1 foreign character
in them. I believe that is what caused Stata to crash when not specifying
a variable list.
Would you not expect these two commands to be identical?
. use "C:\data\foreign_data.dta"
. use * using "C:\data\foreign_data.dta"
BTW, I tested this on 32-bit Windows XP, 64-bit Windows 7, and 64-bit Linux
with Stata 11 and Stata 10 and had the exact same experience. So, it seems
this issue has been the case for years.
I reported this to Stata tech support, but they have not responded with any
explanation as to why specifying the varlist allows Stata to load the dataset.
I am posting this to the list in order to get this solution documented so that
it helps others and to see if anyone out there has any insight to this oddness.
HTH,
Dan Blanchette
Research Programming Services
Carolina Population Center
University of North Carolina
Chapel Hill, NC 27516 USA
[email protected]
*
* 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/