[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]
RE: st: RE: -save- with emptyok
I have some sympathy with this call, echoed by Jeph Herrin,
but not total sympathy.
In practice the work-around is so easy that I would much
rather the good folks at StataCorp implement many other
Any way, what is the underlying problem? You want to
join several data files, observation-wise, and kicking
off the process is a little tricky because you have
to -use- before you can -append-? Isn't Roger Newson's
-dsconcat- one of several solutions to that?
More crucially, this looks like a little deal from your
point of view, but you are asking StataCorp to
change one or more fundamental commands.
I am not clear whether you want a change to -save- or to
-append-, but it is the same story either way.
Changing the behaviour of a fundamental command is scary
stuff when you want is not a bug fix (which by definition
is desirable). Who knows what other commands, programs or do files might
be broken by any such change? I have no idea, but unless
you can be certain that there are no side-effects, this
is questionable. Of course, it is StataCorp's job to
worry about that; and be assured, they would worry about
Even adding an extra option looks like questionable complexity.
Stata users often forget that just adding a little feature to
official Stata can be a much bigger deal than just tweaking the code. In
general, you need to make a hit on the help, the manuals, the
dialogs, and the test scripts; and there are downstream implications
for maintenance, tech support and marketing. Now don't feel
sorry for StataCorp: they take your money so that they can do
this, among other things. But these changes can be a bigger deal
than you think.
> Thanks Nick. I implemented a solution, much like the one you
> suggest, that
> does not require emptyok. But it seems to me that emptyok is
> an "empty"
> option if variables/observations need to be specified anyway
> before -save ,
> emptyok- plays nicely with -append- or -merge-. Perhaps this
> is something for
> the good folks at Statacorp to chew on.
> Nick Cox wrote:
> > The issue here is not with -save-, but with -append-.
> > -append- needs something more than almost nothing
> > to join on to. I think you need to -save- your dataset
> > with variables (even though there are no observations).
> > Fortunately, a token variable is sufficient (but evidently
> > necessary).
> > . clear
> > . gen completeanduttergarbage = .
> > . save empty, emptyok
> > . append using auto
> > . drop completeanduttergarbage
> > Admittedly, the error message here does not indicate
> > the problem.
> > Nick
> > email@example.com
> > Partha Deb
> >> I'm having trouble getting -save- to work with emptyok in the
> >> way I think it
> >> should. Here's an example.
> >> . save temp, emptyok
> >> (note: dataset contains 0 observations)
> >> file temp.dta saved
> >> . use temp.dta
> >> . append using auto.dta
> >> no dataset in use
> >> r(3);
> >> Shouldn't I be able to append? What am I doing wrong? I'm
> >> using Stata 9.2.
* For searches and help try: