comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: r_correlate; get "loop limit expression too large" error with /Kendall
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
Re: r_correlate; get "loop limit expression too large" error with /Kendall [message #74334] Thu, 13 January 2011 16:05
Michael Galloy is currently offline  Michael Galloy
Messages: 1114
Registered: April 2006
Senior Member
On 1/13/11 4:53 PM, Paulo Penteado wrote:
> On Jan 13, 7:16 pm, David Fanning<n...@dfanning.com> wrote:
>> wlandsman writes:
>>> An alternative is to use IDL 8.0, where there is automatic promotion of 16 bit integers to LONG.
>>
>> What!? Get out! Seriously? I've got to check
>> this out. This would be a Good Thing, IMHO. :-)
>
> As I remember it, this was added in 8.0, with some bug related to it
> fixed in 8.0.1.

I do not use defint32:

IDL> for i = 0, 50000 do j = i
IDL> help, i, j
I LONG = 50001
J LONG = 50000

Mike
--
www.michaelgalloy.com
Research Mathematician
Tech-X Corporation
Re: r_correlate; get "loop limit expression too large" error with /Kendall [message #74336 is a reply to message #74334] Thu, 13 January 2011 15:53 Go to previous message
penteado is currently offline  penteado
Messages: 866
Registered: February 2018
Senior Member
Administrator
On Jan 13, 7:16 pm, David Fanning <n...@dfanning.com> wrote:
> wlandsman writes:
>> An alternative is to use IDL 8.0, where there is automatic promotion of 16 bit integers to LONG.  
>
> What!? Get out! Seriously? I've got to check
> this out. This would be a Good Thing, IMHO. :-)

As I remember it, this was added in 8.0, with some bug related to it
fixed in 8.0.1.
Re: r_correlate; get "loop limit expression too large" error with /Kendall [message #74341 is a reply to message #74336] Thu, 13 January 2011 13:16 Go to previous message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
wlandsman writes:

> An alternative is to use IDL 8.0, where there is automatic promotion of 16 bit integers to LONG.

What!? Get out! Seriously? I've got to check
this out. This would be a Good Thing, IMHO. :-)

Cheers,

David



--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.idlcoyote.com/
Sepore ma de ni thui. ("Perhaps thou speakest truth.")
Re: r_correlate; get "loop limit expression too large" error with /Kendall [message #74343 is a reply to message #74341] Thu, 13 January 2011 12:59 Go to previous message
wlandsman is currently offline  wlandsman
Messages: 743
Registered: June 2000
Senior Member
On Thursday, January 13, 2011 2:49:26 PM UTC-5, Snow53 wrote:
> On Jan 13, 12:30 pm, David Fanning <n....@dfanning.com> wrote:

>> Ah, then open r_correlate.pro in a text editor and add
>>
>>    Compile_Opt defint32
>>
>> at the top of the program.

>
> Hi David; I noticed that suggestion in one of your prior posts (I am
> an avid follower) and it is in the program already but didn't solve
> the issue. :(

Are you sure that it is already in your copy of r_correlate.pro ? This is an ITTVIS supplied program, and it is missing the compile_opt defint32 statement. Note that it is not enough to put compile_opt defint32 in *your* program since the scope is local. You have to edit r_correlate.pro.

An alternative is to use IDL 8.0, where there is automatic promotion of 16 bit integers to LONG. --Wayne
Re: r_correlate; get "loop limit expression too large" error with /Kendall [message #74350 is a reply to message #74343] Thu, 13 January 2011 11:49 Go to previous message
Snow53 is currently offline  Snow53
Messages: 32
Registered: July 2010
Member
On Jan 13, 12:30 pm, David Fanning <n...@dfanning.com> wrote:
> Snow53 writes:
>> I'm not using r_correlate within a loop.  I have two files, x and y,
>> that are 1-D.  I am simply using r_correlate(x,y).
>
> Ah, then open r_correlate.pro in a text editor and add
>
>    Compile_Opt defint32
>
> at the top of the program.
>
> Cheers,
>
> David
>
> --
> David Fanning, Ph.D.
> Fanning Software Consulting, Inc.
> Coyote's Guide to IDL Programming:http://www.idlcoyote.com/
> Sepore ma de ni thui. ("Perhaps thou speakest truth.")

Hi David; I noticed that suggestion in one of your prior posts (I am
an avid follower) and it is in the program already but didn't solve
the issue. :(
Re: r_correlate; get "loop limit expression too large" error with /Kendall [message #74354 is a reply to message #74350] Thu, 13 January 2011 11:30 Go to previous message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
Snow53 writes:

> I'm not using r_correlate within a loop. I have two files, x and y,
> that are 1-D. I am simply using r_correlate(x,y).

Ah, then open r_correlate.pro in a text editor and add

Compile_Opt defint32

at the top of the program.

Cheers,

David


--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.idlcoyote.com/
Sepore ma de ni thui. ("Perhaps thou speakest truth.")
Re: r_correlate; get "loop limit expression too large" error with /Kendall [message #74356 is a reply to message #74354] Thu, 13 January 2011 11:26 Go to previous message
Snow53 is currently offline  Snow53
Messages: 32
Registered: July 2010
Member
On Jan 13, 9:34 am, Paolo <pgri...@gmail.com> wrote:
> You have some code that looks like:
>
> for i=0,50000 do ...
>
> that should read
>
> for i=0L,50000 do ...
>
> Ciao,
> Paolo
>
> On Jan 13, 11:22 am, Snow53 <jennifer_wa...@hotmail.com> wrote:
>
>
>
>> I'm dealing with float vectors of length 50000.  I can run r_correlate
>> just fine, but get a "Loop limit expression too large for loop
>> variable type" when I switch to Kendall's instead of Spearman's.  Am
>> curious as to why this might be happening.
>
>> Has anyone else seen this?
>
>> Thanks!- Hide quoted text -
>
> - Show quoted text -

I'm not using r_correlate within a loop. I have two files, x and y,
that are 1-D. I am simply using r_correlate(x,y).
Re: r_correlate; get "loop limit expression too large" error with /Kendall [message #74364 is a reply to message #74356] Thu, 13 January 2011 08:34 Go to previous message
pgrigis is currently offline  pgrigis
Messages: 436
Registered: September 2007
Senior Member
You have some code that looks like:

for i=0,50000 do ...

that should read

for i=0L,50000 do ...

Ciao,
Paolo


On Jan 13, 11:22 am, Snow53 <jennifer_wa...@hotmail.com> wrote:
> I'm dealing with float vectors of length 50000.  I can run r_correlate
> just fine, but get a "Loop limit expression too large for loop
> variable type" when I switch to Kendall's instead of Spearman's.  Am
> curious as to why this might be happening.
>
> Has anyone else seen this?
>
> Thanks!
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Re: lat/lon to km-spaced grid ?
Next Topic: COLORBAR

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 11:42:47 PDT 2025

Total time taken to generate the page: 0.00642 seconds