Bookmark and Share

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]

Re: st: RE: r(1000) error when running xi


From   A Loumiotis <[email protected]>
To   [email protected]
Subject   Re: st: RE: r(1000) error when running xi
Date   Tue, 1 Nov 2011 10:02:56 +0200

It's not the same but I think it is related so I modified the code
above and I now get a r(1000) error when I use the subinstr extended
macro function.

local test 0
forvalues i=1/20000 {
	local test : subinstr local test "0" "0000000000"
	local ctest : length local test
	di "`i'"
	di "`ctest'"
}

...
165169
18353
165178
18354
165187
18355
165196
system limit exceeded - see manual
r(1000);

end of do-file

r(1000);



On Tue, Nov 1, 2011 at 9:44 AM, Nick Cox <[email protected]> wrote:
> The error "too many macros" is not the same as the error on macro
> length you reported earlier.
>
> On Tue, Nov 1, 2011 at 7:08 AM, A Loumiotis <[email protected]> wrote:
>> The problem is not limited to -xi- of -ice-.  For example the
>> following code stops with a r(920) error when the length of local test
>> reaches 165198.
>>
>> local test
>> forvalues i=1/166000 {
>>        local test "`test' `i'"
>>        local ctest : length local test
>>        di "`ctest'"
>> }
>>
>> ...
>> 165180
>> 165186
>> 165192
>> 165198
>> too many macros
>> r(920);
>>
>>
>>
>> On Mon, Oct 31, 2011 at 2:55 PM, Nick Cox <[email protected]> wrote:
>>> I do have a wild guess, which is that the limit on macro length may be affected by a -version- declaration somewhere along the computational path.
>>>
>>> Nick
>>> [email protected]
>>>
>>>
>>> -----Original Message-----
>>> From: [email protected] [mailto:[email protected]] On Behalf Of Nick Cox
>>> Sent: 31 October 2011 12:40
>>> To: '[email protected]'
>>> Subject: RE: st: RE: r(1000) error when running xi
>>>
>>> I see. There is a division of labour here: if the problem appears to be in -ice- then tech-support is likely to refer you to its author.
>>>
>>> I have no guesses what is going on. I try never to estimate more about seven parameters at a time.
>>>
>>> Nick
>>> [email protected]
>>>
>>> A Loumiotis
>>>
>>> Thanks Nick.
>>> I will contact tech support and I will take your advise from now on
>>> and clone official stata commands before I modify them.
>>>
>>> The problem occurs when I use -ice- which does not accept factor
>>> variables (and the -ice- code uses xi).
>>>
>>> SJ-9-3  st0067_4  . Mult. imp.: update of ice, with emphasis on cat. variables
>>>        (help ice, uvis if installed) . . . . . . . . . . . . . . . P. Royston
>>>        Q3/09   SJ 9(3):466--477
>>>        update of ice package with emphasis on categorical
>>>        variables; clarifies relationship between ice and mi
>>>
>>>
>>> On Mon, Oct 31, 2011 at 2:09 PM, Nick Cox <[email protected]> wrote:
>>>> Also, -xi:- is not needed in Stata 11, given the introduction of factor variables.
>>>>
>>>> Nick
>>>> [email protected]
>>>>
>>>> A Loumiotis
>>>>
>>>>
>>>> I get the following error when I run xi:
>>>>
>>>> system limit exceeded - see manual
>>>> r(1000);
>>>>
>>>> I modified a bit xi and measured the length of the local orig and
>>>> found out that the error occurs when the macro length of orig exceeds
>>>> 165198.  I'm surprised because I'm not using Stata/IC where the macro
>>>> limit is 165,200 but I'm using Stata/MP where the macro limit is
>>>> 1,081,511.  Do you know why this is happening?
>>>>
>>>> My version of Stata is the following:
>>>>
>>>> .about
>>>> Stata/MP 11.2 for Windows (32-bit)
>>>> Born 01 Sep 2011
>>>> Copyright 1985-2009 StataCorp LP
>>>>
>>>> Total physical memory:     2097151 KB
>>>> Available physical memory: 1726136 KB
>>>>
>>>
>>> *
>>> *   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/
>>>
>>> *
>>> *   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/
>>>
>>
>> *
>> *   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/
>>
>
> *
> *   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/
>

*
*   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–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index