[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: EXE to Large



PureBytes Links

Trading Reference Links

"Gaston Lang" <gastonlang@xxxxxxxxxxxxx> wrote:
> I am getting an EXE code to large error when i try to run this
> function. It is a true false function to return a 1 or 0 depending
> on whether or not the ADX meets trending criteria.This does not
> seem to complicated or large enough to pose a problem. Any one have
> any ideas. 

Remember that TS counts not just your code, but the code for any 
functions that you use.

LinearRegSlope is pretty small.  But ADX (and the DMI functions it 
calls) is pretty big.

However, this function by itself wouldn't exceed the limits.  You 
must be calling it from a system or indicator that (by itself or with 
other functions it calls) is already fairly large.

I don't see any obvious way to dramatically reduce your EXE size for 
this function, since there's no way to get rid of the ADX exe size.  
Can you get rid of anything in the study that calls the function?

You *could* speed up your EXECUTION speed quite a bit.  You're 
calling ADX many times with the same arguments, requiring TS to 
recompute the same info many times.  Why not store ADX(14) and ADX(8) 
in variables so you only have to compute each one once?

Gary