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

Re: st: RE: notes lost in append


From   Fred Wolfe <fwolfe@arthritis-research.org>
To   statalist@hsphsun2.harvard.edu
Subject   Re: st: RE: notes lost in append
Date   Tue, 11 May 2004 09:52:59 -0500

At 08:48 AM 5/11/2004, you wrote:
I thank Fred and Nick for their responses to my question about appending notes.

For the short-term, I would be happy to try Fred's suggestion if only I could figure out how to do it. Having checked the documentation, I can't see how to retrieve the notes from a data set in order to copy them into a new data set. Are they stored in some retrievable variable?
Nick wrote that solutions were "messy" and I think he is right.

Off the top of my head, you could

preserve
use the appending set

Notes are stored as char, as in

char list
nwofunc[note1]: generate nwofunc = wofunc *.05882353
nwostiff[note0]: 1

Using a foreach loop, extract the note and note number to a (probably) global macro
restore
add or replace the note in the master set with data from the global macro

It's messy, probably difficult to program, but doable.

Fred




*
* 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–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index