Bookmark and Share

Notice: On March 31, it was announced that Statalist is moving from an email list to a forum. The old list will shut down at the end of May, and its replacement, statalist.org is already up and running.


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

st: Trying to import an XML file into STATA


From   "Helen Gibbs" <kiwihelen@gmail.com>
To   <statalist@hsphsun2.harvard.edu>
Subject   st: Trying to import an XML file into STATA
Date   Wed, 30 Jun 2010 20:16:46 +0100

I am sorry, this is probably an ultra-basic question, but I have been doing
this STATA thing for only about a day, and I am stumped


xmluse "C:\Users\Da\Desktop\Helen1.xml"
(using doctype(excel) for C:\Users\Da\Desktop\Helen1.xml)
system limit exceeded -- width shortage
    An attempt was made to add a variable that would have increased the
memory
    required to store an observation beyond 24576 bytes, the maximum width
    allowed.  You have the following alternatives:

     1.  Store existing variables more efficiently; see help compress.

     2.  Drop some variables; see help drop.

     3.  If you are using Stata/SE, increase the maximum width by increasing
         maxvar; see help maxvar.  The maximum width is set to 12*maxvar.

Here are my problems:
I am having to export out of SPSS into an excel document and save as an XML
file (2003 version), then when I try to import it. This is a large file with
around 150 variables and 4000 responses. It is an epidemiological dataset if
anyone is curious!

1) Is there any other way I can do this, which might circumvent this problem
e.g. any way of directly importing SPSS files
2) Is there any way of compressing the XML file ? because I couldn?t see how
I could without being able to open the file which I can?t import in the
first place.
3) I have dropped as many variables as possible (e.g. removed the secondary
calculations and ln outputs, recording a list so I can do them again when
imported), made sure they are all in numeric form, rather than string, and
where possible shortened the variable names at the top of the columns, but
still no luck.
a. Is there anything else I can do to reduce the variable width that I have
missed?
b. Is there any way of finding out which variable is giving STATA the
problem ? is it all my variables or only some of them
4) I ?m using  STATA/ IC 11.1 hence can?t seem to be able to use the maxvar
command ? is this right or am I really showing my inexperience.

Thanks in advance to all,  as you can see I am still with L plates and
trainer wheels!

Helen


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


© Copyright 1996–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   Site index