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 on April 23, and its replacement, statalist.org is already up and running.


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

Re: st: New package -use10save9- available on SSC


From   Lars Ängquist <lars.angquist@telia.com>
To   <statalist@hsphsun2.harvard.edu>
Subject   Re: st: New package -use10save9- available on SSC
Date   Wed, 2 Nov 2011 19:34:56 +0100

Dear Nick.

Many thanks for your comments.

As you indicate the primary use of -use10save9- should be, and was planned
to be, to facilitate for the Stata 9 user to in a one-command way being able
to transfer multiple files from e.g. Stata 10 format to a format that would
be readable for such a user. (An aside is that this was initialized by an
actual need, from one time to another, for some Stata users at the Institute
where I work, where in fact still quite a few users are using Stata 9.)

Initially I designed the program to simply use Stata's built-in -save-
function when, after each loading of a matched file, re-saving the file
and hence to make it useful strictly from Stata 9-only, but then I noticed on
Statalist that (an update to)  -save9- was made available and hence thought
that I could perhaps add a secondary application addressing this task from,
so to say, the other way around in the sense of facilitating a one-command
option to, from e.g. Stata 10, calling the program in order to save a matched set of files in an older-than-used format (instead of loading, and re-saving, files
having a more recent-than-used format). Admittedly, this task should also be
directly solvable by usage of the in-built duo -save- and -saveold- but I here considered this approach to be quite convenient in the sense of not having to
check the user-version; since e.g. -saveold- and -save- then appeared to be
appropriate for the task from Stata 10 and Stata 9 respectively.
(Another aside, originally I thought that -saveold- used from within Stata 12 would not save data in a format readable from Stata 9 since the Stata 12 format was described as a new format, and hence here introduce further complications in this sense, but I later found out that I was probably mistaken in that case,
see e.g. http://www.stata.com/support/faqs/data/commaold.html.)

Regarding the usage of -use10- and Stata versions, the command at least
seem to be working for Stata 11.2 (which I currently run) and my only defense in this respect is that I, admittedly somewhat naively, assumed that it would perhaps also work in Stata 12 based on the information stated in the help-file that the program will in fact use the standard -use- in cases of not recognizing the
Stata 10 format and hence then assumingly work also for these cases.
I have unfortunately not had the possibility to test this myself in Stata 12,
since it is currently not available to me, but I would be very grateful if
someone did that and - if not working properly - I would happily update
the -use10save9- help-file in order to state that it then requires Stata 9/10/11.

I do not claim any other functionality of -use10save9- than the primary and
secondary ones outlined above (except for some limited side-effect possibilities
of renaming multiple files, but for such purposes I would perhaps recommend
another of my functions -renfiles- available on SSC).

With best wishes & regards  /  Lars Ängquist

--- --- ---

Date: Mon, 31 Oct 2011 09:15:43 +0000
From: Nick Cox <njcoxstata@gmail.com>
Subject: Re: st: New package -use10save9- available on SSC

This program raises questions similar to, but not identical to, those
raised by -save9- (SSC). See earlier postings by Joerg Luedicke

http://www.stata.com/statalist/archive/2011-04/msg00654.html

http://www.stata.com/statalist/archive/2011-10/msg00928.html

and myself

http://www.stata.com/statalist/archive/2011-10/msg01158.html

http://www.stata.com/statalist/archive/2011-10/msg01253.html

Marco Ercolani's replies are included in these postings. (He is the
author of -save9-.)

First, -use10save9- is I gather essentially for users of version 9, as
if you have Stata 10 up you don't seem to need it (except for its
support for multiple files). That is clearly a class of users who
might seek some help in reading .dta files that otherwise are
unreadable. However, if you have version 9, then inbuilt -save- will
automatically save to version 9 format. So, the use of -save9- within
-use10save9- appears superfluous.

Second, -use10- (SSC) itself claims only that it can read Stata 10
.dta files in Stata 9, whereas the claim made on its behalf here is
that you can read Stata 10+ files. This seems all too likely to be
misunderstood by some users, as Stata 10+ surely includes Stata 12.

Third, you can go beyond what official Stata provides if you write
extra code that makes use of StataCorp's published specification of
.dta format. -use10- does do this among the three programs mentioned
but otherwise I don't see that the programs can do anything radically
different from what -save- and -saveold- do in any particular version
of Stata.

The underlying principles are very simple. Everyone benefits from
being totally precise about what programs can and, by extension,
cannot do. Similarly, superfluous programs do no harm, except that
they can confuse.

Those are the principles. In practice -use10save9- does offer
functionality for working with several .dta files at once, but
otherwise I am unclear about its precise rationale. Perhaps others too
would appreciate some clarification here, or correction of what I am
not understanding.

Nick

Nick

On Sun, Oct 30, 2011 at 10:29 PM, Lars Ängquist <lars.angquist@telia.com>
wrote:
Dear Statalist.

Many thanks to Kit Baum who recently (2011-10-29) made the -use10save9-
package available for download from SSC. In Stata, use the -ssc- command
to
do this directly, or go somewhat more indirectly through usage of
the -findit- command.

--- --- ---

Brief abstract:

use10save9 - is a program that helps out with opening Stata 10+ files from
within Stata 9 and then saving them in Stata 9 format using the
user-written
-use10- (Radyakin, 2008) and -save9- (Ercolani, 2011) functions. May be
applied to a quite generally defined/matched set of Stata datasets within
a
defined folder and, if selected, also with respect to all corresponding
subfolders. The simplest syntax is purely based on defaults. All options
are
optional.
 An alternative, secondary, usage might be to simply use the function as
an
extension to -save9- in order to save matched sets of datasets in Stata 9
format while being in Stata 10+.

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