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

Re: [amibroker] Re: Learning Composites



PureBytes Links

Trading Reference Links

Whitney -  Note that you're indexing the retrieval of fcum with i and but 
your loop is written for f.
When I changed it I do get values and not zeros.   Which was your question 
in the first place.

<<<<<<<<<<<<<< changed the index on the variables fcum>>>>>>>>>>>>>>>>>>>>>.

Cumfarray = Cum( farray );
for (f=fv; f<=Lv; f++)
{
_TRACE( "farray = " + StrFormat( fi, farray[f] ) );
fcum = Cum( farray );
_TRACE( "fcum = " + StrFormat( fi, fcum[f] ) );
}
_TRACE( "lastval of farray after foreign = " + StrFormat( fi, LastValue( 
fcum ) ) );
Buy=Sell=0;

There are no persistent arrays other than writing it out to 1) file..fputs 
fgets, 2) using the ODBC
interface to Access/SQL Server or 3)using the Osaka plugin as a datastore. 
I've used all three in
very basic ways. Osaka mostly for sorts, Access to store positions, no of 
shares, etc. basic portfolio
work to generate an equity curve.   There are persistent numbers and text 
store AFL functions...
VarSet VarGet for numbers and text.  These I understand will persist from 
routine to routine unless
you close Amibroker.

You could write your approach in one long script I suppose and should be 
able to read the intermediate ATC as the script that I sent does. For some 
of the work I do where I build on intermediate results, I use jScript to 
drive say - in one case 5 AFL scripts, with each one building on the other. 
Here I use ATCs function to store intermediate and final averages and equity 
curves as different SCANs are run.  There's a utility by Fred Tonnetti in 
our files called BatMan that will do the same thing and you won't have to 
learn about and how to use jScript objects.

We've asked for persistent arrays but it's not a straight forward add on as 
I understand it.

HTH
Joe



----- Original Message ----- 
From: "whitneybroach" <WhitneyBroach@xxxxxxxxx>
To: <amibroker@xxxxxxxxxxxxxxx>
Sent: Saturday, October 28, 2006 11:10 AM
Subject: [amibroker] Re: Learning Composites


> --- In amibroker@xxxxxxxxxxxxxxx, "Joe Landry" <jelandry@xxx> wrote:
>>
>> Whitney - Were you trying to run this in an indicator window?
> ...
>> What are you trying to accomplish by using ATC?  You may be able to
> do it
>> without
>> iterating i over the range.
>>
>> Hope this helps
>> JOE
> ------------------------
> Joe,
>
> Thanks for your prompt response, and good questions.
>
> Indicator window:  I don't know, I'm so new to AB.  I was in the AFL
> editor and clicking the check mark for verifying syntax. :)
>
> Trying to accomplish:  Static storage for interim test results managed
> by AB instead of using explicit disk i/o.  (A side effect is binary
> instead of string storage; I expect binary to run faster.)  I want to
> store interim results of watchlist-based multisymbol analysis during
> an analysis phase; these results are then to be read from the composites
> during a subsequent summarizing and reporting phase.
>
> I hope this approach can work across multiple tools:  Scan, Explore,
> Optimize.  I would rather write intermediate results to a composite
> than to a file with fputs, so AB manages the disk i/o as
> necessary and my code doesn't have to.  Somehow I think AB can do a
> better job working with the operating system than I can.
>
> Any additional insights are welcome, even if it means not using
> composites.
>
> Best,
>
>
>
>
> Please note that this group is for discussion between users only.
>
> To get support from AmiBroker please send an e-mail directly to
> SUPPORT {at} amibroker.com
>
> For NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
> http://www.amibroker.com/devlog/
>
> For other support material please check also:
> http://www.amibroker.com/support.html
>
> Yahoo! Groups Links
>
>
>
>
> 



Content-Description: "AVG certification"
No virus found in this incoming message.
Checked by AVG Free Edition.
Version: 7.1.409 / Virus Database: 268.13.27/517 - Release Date: 11/3/2006