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]

From |
Robert Picard <picard@netbox.com> |

To |
statalist@hsphsun2.harvard.edu |

Subject |
Re: st: use13 : an experimental Stata command to import datasets in new Stata 13 format into older versions of Stata |

Date |
Wed, 19 Jun 2013 16:29:52 -0400 |

Nope, the check is based on the storage type. However, -compress- will reduce a strL to a str# type if Stata calculates that it would require less memory. Then if all string variables are shorter than str244, you can use -saveold-. Yes, I like the new string expression syntax, it's in -help string functions-, more specifically, -help strdup()- and -help strcat()-. Robert On Wed, Jun 19, 2013 at 3:44 PM, Sergiy Radyakin <serjradyakin@gmail.com> wrote: > Thank you, Robert. > > the above is helpful. So the suggested route is to drop or truncate > variables, and it is up to the user to take the responsibility for the > decision. I am ok with that. Notably Stata reports that the fact of > presence of strL is a problem, does it check that any of the strL's > are really longer than 244 before deciding that it is a problem? (when > they are not binary). > > It seems the expression syntax has also been expanded? "x"*5000 is new > to me, at least in Stata. Mata supported it, but not Stata > expressions. > > Best, Sergiy Radyakin > > > On Wed, Jun 19, 2013 at 3:09 PM, Robert Picard <picard@netbox.com> wrote: >> The -saveold- command of Stata 13 returns an error if the data >> contains a long string: >> >> . clear >> >> . set obs 2 >> obs was 0, now 2 >> >> . gen s = "x" * 5000 >> >> . saveold test.dta >> data cannot be saved in old format >> Data contain strL or str#, #>244, and prior releases of Stata >> would not know how to process these variables. Either drop the >> variables or use recast with the force option to change them to str244. >> r(459); >> >> >> >> On Wed, Jun 19, 2013 at 2:25 PM, Sergiy Radyakin <serjradyakin@gmail.com> wrote: >>> On Wed, Jun 19, 2013 at 1:11 PM, Nick Cox <njcoxstata@gmail.com> wrote: >>>> I have no access to Stata 13, but there is precisely no point to >>>> -saveold- if Stata 12 is presented with data features it can not >>>> handle. So, at best long string variables will get truncated at 244 >>>> characters. That's my guess. >>> >>> The idea is to be creative and make the content accessible in Stata 12. There >>> are several strategies: splitting long variables into chunks, >>> (resume-->resume_1, resume_2, resume_3....) >>> each no longer than 244, or dumping the long variables into a text file, >>> from which the users can pull the strings using alternative methods, etc. >>> The simplest approach is to truncate the data, but it is not >>> necessarily the best. >>> >>> But the bulk of the users are not going to use the new features of Stata 13 >>> right away. Just as many of the datasets that are shipped with Stata 12 can >>> be resaved for Stata 9 without any losses. Consider auto.dta for example. >>> Secondly, since the features of Stata 13 were kept out of public view, noone >>> was planning for them in advance, and having the possibility of long strings >>> would not change the questionnaires being designed this month, and the data >>> collected using them in the next half a year. >>> >>> The feature that lacks in Stata is really: savemin (imaginary name), which would >>> examine the file and save it in the lowest possible version that would not incur >>> losses (that is really a job for save, but let's not get into that). >>> With that, many >>> datasets will end up somewhere in the v4-v7 range (imho). >>> >>> Another strategy could have been dual compatibility: SPSS v7 can read SPSS >>> v11 datasets. It does not understand everything, but the core of data >>> can be read, >>> and decoration is often (not always, but often) not essential. >>> >>>> >>>> I hope you don't get troubled by users who imagine that you have found >>>> a cheap way for them to upgrade without paying! >>> >>> Nothing in the announcement implies that. It is not an upgrade for Stata 12 that >>> delivers features of Stata 13. It is a way to read data from Stata 13 subject to >>> a) limitations of the existing Stata versions and b) my own goals and >>> time/effort >>> constraints. Not sure whether the same argument applies to e.g. StatTransfer, >>> which is doing a similar conversion, though having had more time for >>> implementation (and [hypothetically] more insider information). >>> >>> Best, Sergiy >>> >>> >>>> Nick >>>> njcoxstata@gmail.com >>>> >>>> >>>> On 19 June 2013 18:05, Sergiy Radyakin <serjradyakin@gmail.com> wrote: >>>>> And just as long they continue to "forget" doing this. >>>>> >>>>> Also, I am not sure what is the behavior of -saveold- in Stata 13. >>>>> What does it do with the long strings? The documentation is only >>>>> saying "saves the dataset currently in memory on disk ... in Stata 12 >>>>> format". How is conversion done? >>>>> >>>>> Sergiy. >>>>> >>>>> On Wed, Jun 19, 2013 at 1:00 PM, Nick Cox <njcoxstata@gmail.com> wrote: >>>>>> Note that getting your colleagues using Stata 13 to use -saveold- to >>>>>> save their datasets is the age-old solution to this. >>>>>> >>>>>> Nick >>>>>> njcoxstata@gmail.com >>>>>> >>>>>> >>>>>> On 19 June 2013 17:54, Sergiy Radyakin <serjradyakin@gmail.com> wrote: >>>>>>> -use13- is an experimental Stata command to import datasets in new >>>>>>> Stata 13 format into older versions of Stata >>>>>>> >>>>>>> The dataset format has changed in the new version of Stata to be >>>>>>> released on June 24, 2013 to accommodate new features. >>>>>>> >>>>>>> The command will help users who can't upgrade immediately, but need to >>>>>>> load the data produced by Stata 13 (e.g. by their colleagues who have >>>>>>> upgraded) during the transition period. >>>>>>> >>>>>>> The use, limitations, and installation instructions are described here: >>>>>>> http://www.adeptanalytics.org/radyakin/stata/use13/use13.htm >>>>>>> >>>>>>> Best, Sergiy Radyakin >>>>>>> * >>>>>>> * For searches and help try: >>>>>>> * http://www.stata.com/help.cgi?search >>>>>>> * http://www.stata.com/support/faqs/resources/statalist-faq/ >>>>>>> * http://www.ats.ucla.edu/stat/stata/ >>>>>> * >>>>>> * For searches and help try: >>>>>> * http://www.stata.com/help.cgi?search >>>>>> * http://www.stata.com/support/faqs/resources/statalist-faq/ >>>>>> * http://www.ats.ucla.edu/stat/stata/ >>>>> * >>>>> * For searches and help try: >>>>> * http://www.stata.com/help.cgi?search >>>>> * http://www.stata.com/support/faqs/resources/statalist-faq/ >>>>> * http://www.ats.ucla.edu/stat/stata/ >>>> * >>>> * For searches and help try: >>>> * http://www.stata.com/help.cgi?search >>>> * http://www.stata.com/support/faqs/resources/statalist-faq/ >>>> * http://www.ats.ucla.edu/stat/stata/ >>> * >>> * For searches and help try: >>> * http://www.stata.com/help.cgi?search >>> * http://www.stata.com/support/faqs/resources/statalist-faq/ >>> * http://www.ats.ucla.edu/stat/stata/ >> * >> * For searches and help try: >> * http://www.stata.com/help.cgi?search >> * http://www.stata.com/support/faqs/resources/statalist-faq/ >> * http://www.ats.ucla.edu/stat/stata/ > * > * For searches and help try: > * http://www.stata.com/help.cgi?search > * http://www.stata.com/support/faqs/resources/statalist-faq/ > * http://www.ats.ucla.edu/stat/stata/ * * For searches and help try: * http://www.stata.com/help.cgi?search * http://www.stata.com/support/faqs/resources/statalist-faq/ * http://www.ats.ucla.edu/stat/stata/

**References**:**st: use13 : an experimental Stata command to import datasets in new Stata 13 format into older versions of Stata***From:*Sergiy Radyakin <serjradyakin@gmail.com>

**Re: st: use13 : an experimental Stata command to import datasets in new Stata 13 format into older versions of Stata***From:*Nick Cox <njcoxstata@gmail.com>

**Re: st: use13 : an experimental Stata command to import datasets in new Stata 13 format into older versions of Stata***From:*Sergiy Radyakin <serjradyakin@gmail.com>

*From:*Nick Cox <njcoxstata@gmail.com>

*From:*Sergiy Radyakin <serjradyakin@gmail.com>

*From:*Robert Picard <picard@netbox.com>

*From:*Sergiy Radyakin <serjradyakin@gmail.com>

- Prev by Date:
**Re: st: Cumulative Return Calculation for Recurring Periods** - Next by Date:
**Re: st: Re: Random draws from a negative binomial distribution** - Previous by thread:
- Next by thread:
- Index(es):