More erratic behaviour. when i double-click the ListAvg indicator in the
charts tab, a new pane opens in the chart and so does the parameter window.
I notice that after i have input the watchlist number and "click" to
calculate, the ATC is not formed under Group253 for a few, and it does form
for a few others.

Do I  - load the Listavg afl into formula editor> tools>insert chart - for
every composite i want to create? Is this what i am doing wrong?

thanks for the effort and patience.

best
kazaan

On 23 March 2010 15:05, furinkazaan <[email protected]> wrote:

> Thanks very much Bruce. In fits and starts I seemed to have got the hang of
> plotting averages for watchlists. I had problems the first time around
> because the AA range settings were from before available data.
>
> Also I suspect that the avergae does not plot if different stocks in the
> wathlist have data starting from different dates. I wonder if the fact that
> there might be data gaps in the middle also affects if / the way the avg is
> plotted.
>
> I notice that the dates for which the average is plotted is completely
> awry. While my AA range settings are 01Jan2004-31Dec2020, I notice that the
> averages are plotted for 1997-1998.
>
> One average starts plotting in 1996(earlier than others) - as a flat line,
> starts plotting the curve from 1997 and has last plot in 2004.
>
> I also notice that the x-axis is turned off by default in parameters.Is
> this a known problem or is it just me? The awry dates worry me.
>
> thanks again.
>
>
> On 23 March 2010 01:59, Bruce <[email protected]> wrote:
>
>>
>>
>> Furinkazaan -
>>
>> I'm not sure if you got your problem solved with ListAvg. If you are still
>> having problems, did you try the EXACT procedure in the following post (it
>> should rule out config issues) ?
>>
>> http://finance.groups.yahoo.com/group/amibroker/message/147986
>>
>> If you still have problems after trying that procedure, e-mail me. I'm
>> traveling, but I'll check.
>>
>>
>> -- BruceR
>>
>> --- In [email protected] <amibroker%40yahoogroups.com>,
>> furinkazaan <furinkaz...@...> wrote:
>> >
>> > gordon,
>> >
>> > http://www.amibrokeru.com/Home/tabid/36/Default.aspx
>> >
>> > need to register. look under FREE. Hope this helps.
>> >
>> > On 22 March 2010 09:55, Gordon Pelletier <gordonpellet...@...> wrote:
>> >
>> > >
>> > >
>> > > Thanks for trying to help furinkazaan, but the webpage not longer
>> exists
>> > >
>> > > Regards
>> > >
>> > > Gordon.
>> > >
>> > > On 18 March 2010 20:11, furinkazaan <furinkaz...@...> wrote:
>> > >
>> > >>
>> > >>
>> > >> this is a free code project that Bruce posts in the free Library on
>> the
>> > >> Amibroker University.
>> > >> http://www.amibrokeru.com/FreeLibrary/FreeCode
>> > >>
>> > >> On 1 January 2010 13:28, Gordon <gordonpellet...@...> wrote:
>> > >>
>> > >>>
>> > >>>
>> > >>> I m trying to follow this thread with some difficulty. I cannot find
>> any
>> > >>> reference to ListAvg.afl anywhere is the literature. Would you
>> please tell
>> > >>> me where it can be located.
>> > >>>
>> > >>> Thanks
>> > >>>
>> > >>>
>> > >>> --- In [email protected] 
>> > >>> <amibroker%40yahoogroups.com><amibroker%
>> 40yahoogroups.com>, "Bruce"
>>
>> > >>> <brucer@> wrote:
>> > >>> >
>> > >>> > I'm buried in some end of the year paperwork right now, but let me
>> > >>> offer a couple of quick comments.
>> > >>> >
>> > >>> > 1. The dropdown list of names is in the expanded version that I
>> plan to
>> > >>> put in the subscriber area along with some other functions related
>> to
>> > >>> portfolio mixes, such as percentage allocations, re-balance
>> intervals, etc.
>> > >>> My long-term intent is really to offer "starter" examples in the
>> FREE CODE
>> > >>> area that users can expand on. We want to concentrate on breadth of
>> topics
>> > >>> there.
>> > >>> >
>> > >>> > 2. One simple tip that might help deal with WL numbers in many
>> places
>> > >>> is to name your watchlist to their number plus that name. That will
>> make the
>> > >>> numbers easier to find in a long list of names in the watchlist
>> tree. For
>> > >>> example, my watchlist 13 is named "13 - Select".
>> > >>> >
>> > >>> > 3. Lastly, the ATC should be going into Group 253 since
>> atcFlagDefaults
>> > >>> was used in the ATC call in the example that I posted. I may have
>> misread
>> > >>> your note, but it seemed to say that you believe are seeing it in
>> the
>> > >>> watchlist. As far as what the ATC is named, you can use the name
>> instead of
>> > >>> the number by changing the AddtoComposite statement to the following
>> -
>> > >>> >
>> > >>> > AddToComposite( Lavg, "~ListAvg_" + CategoryGetName(
>> categoryWatchlist,
>> > >>> wlnum ),
>> > >>> > "X", atcFlagDefaults + atcFlagEnableInIndicator );
>> > >>> >
>> > >>> >
>> > >>> > -- BruceR
>> > >>> >
>> > >>> >
>> > >>> > --- In [email protected] 
>> > >>> > <amibroker%40yahoogroups.com><amibroker%
>> 40yahoogroups.com>,
>>
>> > >>> furinkazaan <furinkazaan@> wrote:
>> > >>> > >
>> > >>> > > Bruce, I notice that the parameters use a WLNUMfor a watch list
>> > >>> number.
>> > >>> > > Since I intend to run this on many sectoral watchlists, I wonder
>> if
>> > >>> we can
>> > >>> > > show the 'Watchlist Name' instead of/ in addition to WL NUM? Can
>> the
>> > >>> > > Parameters dialog be coded to offer a drop-down list of all
>> > >>> watchlists to
>> > >>> > > the current market? Can the LAVG be defined to show "~ListAVg" +
>> > >>> Watchlist
>> > >>> > > Name?
>> > >>> > >
>> > >>> > > while its fantastic that each atc is written ijnto the watchlist
>> > >>> folder for
>> > >>> > > which it is computed, if I got them all into 1 group to check,
>> say
>> > >>> relative
>> > >>> > > performance, then I'd have trouble identifying eact atc by just
>> the
>> > >>> WL Num.
>> > >>> > >
>> > >>> > > can you help? Best wishes for a great year ahead!
>> > >>> > >
>> > >>> > >
>> > >>> > > 2009/12/11 furinkazaan <furinkazaan@>
>> > >>> > >
>> > >>> > > > Thanks very much Bruce. I intend to set this up over the
>> weekend.
>> > >>> I'll
>> > >>> > > > report progress.
>> > >>> > > >
>> > >>> > > > 2009/12/9 Rick Osborn <ricko@>
>> > >>> > > >
>> > >>> > > >
>> > >>> > > >>
>> > >>> > > >>
>> > >>> > > >>
>> > >>> > > >> changed the AA range and ran a dummy scan. That did the trick
>> > >>> > > >> Thanks
>> > >>> > > >>
>> > >>> > > >>
>> > >>> > > >> ------------------------------
>> > >>> > > >> *From:* Bruce <brucer@>
>> > >>> > > >> *To:* 
>> > >>> > > >> [email protected]<amibroker%40yahoogroups.com><amibroker%
>> 40yahoogroups.com>
>>
>> > >>> > > >> *Sent:* Tue, December 8, 2009 8:16:46 PM
>> > >>> > > >>
>> > >>> > > >> *Subject:* [amibroker] Re: AmibrokerU Update
>> > >>> > > >>
>> > >>> > > >>
>> > >>> > > >>
>> > >>> > > >> Rick -
>> > >>> > > >>
>> > >>> > > >>
>> > >>> > > >> Not much info, so I can't be sure. A SWAG would be to check
>> the
>> > >>> From/To
>> > >>> > > >> range in the AA window. As I noted in the original article, I
>> used
>> > >>> the
>> > >>> > > >> existing AA user interface as an easy way to control the
>> range. If
>> > >>> that is
>> > >>> > > >> it, you can change the AA range and run a dummy scan to "set
>> it".
>> > >>> Or, you
>> > >>> > > >> might want to look at the ListAvg AFL code for a comment that
>> > >>> notes that a
>> > >>> > > >> variable called "bir" can be set to 1 to use all bars by
>> default.
>> > >>> > > >>
>> > >>> > > >> -- Bruce
>> > >>> > > >>
>> > >>> > > >> --- In amibro...@yahoogrou ps.com <amibroker%
>> 40yahoogroups.com>,
>> > >>> Rick
>> > >>> > > >> Osborn <ricko@> wrote:
>> > >>> > > >> >
>> > >>> > > >> > Bruce
>> > >>> > > >> > All the values in all the watchlists are 1000.
>> > >>> > > >> > What am I doing wrong?
>> > >>> > > >> >
>> > >>> > > >> >
>> > >>> > > >> >
>> > >>> > > >> >
>> > >>> > > >> >
>> > >>> > > >> > ____________ _________ _________ __
>> > >>> > > >> > From: Bruce <brucer@>
>> > >>> > > >> > To: amibro...@yahoogrou ps.com <amibroker%
>> 40yahoogroups.com>
>> > >>> > > >>
>> > >>> > > >> > Sent: Tue, December 8, 2009 2:28:20 PM
>> > >>> > > >> > Subject: [amibroker] Re: AmibrokerU Update
>> > >>> > > >> >
>> > >>> > > >> >
>> > >>> > > >> > Sure, I'll give a (hopefully) useful example. And, I'll try
>> to
>> > >>> do more
>> > >>> > > >> > of this, where possible, in the future. In order to
>> facilitate
>> > >>> this,
>> > >>> > > >> > though, it is best to use a Chart Template, Complete file
>> and
>> > >>> record a
>> > >>> > > >> > generic procedure for how to use it. Rather than introduce
>> that
>> > >>> now,
>> > >>> > > >> > I'll walk you through a manual install.
>> > >>> > > >> >
>> > >>> > > >> > So, download the ListAvg.afl file to your include
>> directory. If
>> > >>> you
>> > >>> > > >> > have done a stock install, it will be at C:\Program
>> > >>> > > >> > Files\Amibroker\ Formulas\ Include. You can verify this by
>> > >>> selecting the
>> > >>> > > >> > Tools / Preferences menu and then the AFL tab. The standard
>> > >>> include
>> > >>> > > >> > path will be the first Pick button.
>> > >>> > > >> >
>> > >>> > > >> > Now, take the following code and either save it in your
>> Custom
>> > >>> formulas
>> > >>> > > >> > directory, or enter it into the code editor. The editor can
>> be
>> > >>> launched
>> > >>> > > >> > from the Analysis / Formula Editor menu.
>> > >>> > > >> >
>> > >>> > > >> > Once it is copied into the editor, you can use the Tools /
>> > >>> Insert Chart
>> > >>> > > >> > menu to get a chart.
>> > >>> > > >> >
>> > >>> > > >> > This indicator uses parameters to select a watchlist to
>> perform
>> > >>> the
>> > >>> > > >> > ListAvg on. Right click on the chart and select
>> parameters.. You
>> > >>> will
>> > >>> > > >> > need to enter a watchlist number. When ready, click the
>> > >>> Calculate
>> > >>> > > >> > parameter button to perform the calculation. Since this can
>> be
>> > >>> lengthy,
>> > >>> > > >> > it is only done on user action. But, it is written to an
>> > >>> AddtoComposite
>> > >>> > > >> > ticker ("~ListAvg" + number) for each watchlist, and simply
>> read
>> > >>> > > >> > thereafter.
>> > >>> > > >> >
>> > >>> > > >> > #include <ListAvg.afl>
>> > >>> > > >> > wlnum = Param( "Watchlist", 13, 1, 100, 1 );
>> > >>> > > >> > trig = ParamTrigger( "Calculate", "CLICK" );
>> > >>> > > >> > Lavg = Nz( Foreign( "~ListAvg" + wlnum , "C" ) );
>> > >>> > > >> > if ( trig )
>> > >>> > > >> > {
>> > >>> > > >> > Lavg = ListAvg( CategoryGetSymbols( categoryWatchlist,
>> wlnum
>> > >>> > > >> > ) );
>> > >>> > > >> > AddToComposite( Lavg, "~ListAvg" + wlnum, "X",
>> > >>> > > >> > atcFlagDefaults + atcFlagEnableInIndi cator );
>> > >>> > > >> > }
>> > >>> > > >> > Plot( Lavg, "Watchlist " + wlnum + " ListAvg", colorDefault
>> );
>> > >>> > > >> >
>> > >>> > > >> > Lastly, since you mentioned sector averages - I'll mention
>> one
>> > >>> example
>> > >>> > > >> > use from my experience. Technology averages do not
>> typically
>> > >>> indicate
>> > >>> > > >> > the health of innovative small-cap tech stocks. The
>> averages are
>> > >>> driven
>> > >>> > > >> > by Intel, Microsoft, etc. An average of targeted,
>> innovative
>> > >>> small-cap
>> > >>> > > >> > tech companies in a watchlist can be more useful for stock
>> > >>> investing.
>> > >>> > > >> >
>> > >>> > > >> > Hope that helps.
>> > >>> > > >> > -- Bruce
>> > >>> > > >> >
>> > >>> > > >> > --- In amibro...@yahoogrou ps.com, furinkazaan
>> <furinkazaan@>
>> > >>> > > >> wrote:
>> > >>> > > >> > >
>> > >>> > > >> > > Bruce, thanks for the afl. It comes at the most oppurtune
>> time
>> > >>> when
>> > >>> > > >> > I'm
>> > >>> > > >> > > considering creation of many sectoral indices. However,
>> rookie
>> > >>> that I
>> > >>> > > >> > am, I
>> > >>> > > >> > > am not able to figure out how to use the AFL. I would
>> > >>> appreciate a
>> > >>> > > >> > > step-by-step detail on how to use it, including where to
>> copy
>> > >>> the afl,
>> > >>> > > >> > where
>> > >>> > > >> > > to store the csv list of tickers etc., and how to run
>> it.. Can
>> > >>> the afl
>> > >>> > > >> > be
>> > >>> > > >> > > pointed to a watchlist instead of a csv file of tickers?
>> > >>> > > >> > >
>> > >>> > > >> > > Thanks again.
>> > >>> > > >> > >
>> > >>> > > >> > >
>> > >>> > > >> > > 2009/11/18 Bruce brucer@
>> > >>> > > >> > >
>> > >>> > > >> > > >
>> > >>> > > >> > > >
>> > >>> > > >> > > > Quick update - I've added a Free Code module and Free
>> Code
>> > >>> article
>> > >>> > > >> > to
>> > >>> > > >> > > > AmibrokerU called ListAvg. For those who need for an
>> equal
>> > >>> weighted
>> > >>> > > >> > > > average of a list of tickers, the Code module provides
>> a
>> > >>> function
>> > >>> > > >> > that
>> > >>> > > >> > > > implements the result in a single call. If you are
>> > >>> interested in the
>> > >>> > > >> > > > background on the need for this function, and the
>> problem
>> > >>> with other
>> > >>> > > >> > > > types of index and list averages, the article should be
>> of
>> > >>> interest.
>> > >>> > > >> > > > Here are the links (sorry they are long, I'll fix that
>> soon)
>> > >>> -
>> > >>> > > >> > > >
>> > >>> > > >> > > >
>> > >>> > > >> > http://www.amibroke ru.com/FreeLibra ry/FreeCode/
>> tabid/99/
>> > >>> > > >> articleType/ Arti\
>> > >>> > > >> > \
>> > >>> > > >> > > >
>> > >>> > > >> > cleView/articleId/ 109/ListAvg- ndash-A-Function
>> -to-Calculate-
>> > >>> > > >> an-Equal- Wei\
>> > >>> > > >> > \
>> > >>> > > >> > > >
>> > >>> > > >> > ghted-Average- of-a-List- of-Tickers. aspx<
>> http://www.amibroke
>> > >>> > > >> ru.com/FreeLi\
>> > >>> > > >> > brary/FreeCode/ tabid/99/ articleType/ ArticleView/
>> articleId/
>> > >>> > > >> 109/ListAvg- nd\
>> > >>> > > >> > ash-A-Function- to-Calculate- an-Equal- Weighted-
>> Average-of-
>> > >>> a-List-of-
>> > >>> > > >> Ticke\
>> > >>> > > >> > rs..aspx>
>> > >>> > > >> > > >
>> > >>> > > >> > > >
>> > >>> > > >> > http://www.amibroke ru.com/FreeLibra ry/FreeArticles/
>> tabid/63/
>> > >>> > > >> articleType/ \
>> > >>> > > >> > \
>> > >>> > > >> > > >
>> > >>> > > >> > ArticleView/ articleId/ 110/ListAvg- ndash-Uses-
>> and-Example..
>> > >>> aspx<
>> > >>> > > >> http://www\
>>  <http://www>
>> > >>> <http://www/>> > >> <http://www>> .amibrokeru. com/FreeLibrary/
>>
>> > >>> FreeArticles/ tabid/63/
>> > >>> > > >> articleType/ ArticleVie\
>> > >>> > > >> > w/articleId/ 110/ListAvg- ndash-Uses- and-Example. aspx>
>> > >>> > > >> > > >
>> > >>> > > >> > > > As we prepare to open up subscriptions to AmibrokerU
>> soon,
>> > >>> I've
>> > >>> > > >> > received
>> > >>> > > >> > > > some questions about what types of free and
>> subscription
>> > >>> content
>> > >>> > > >> > that we
>> > >>> > > >> > > > plan to add. In general, we will offer "lite" of
>> "subset"
>> > >>> versions
>> > >>> > > >> > of
>> > >>> > > >> > > > premium code and articles available in the subscription
>> > >>> sections.
>> > >>> > > >> > > > ListAvg is an example of that. It implements an equal
>> > >>> weighted
>> > >>> > > >> > average
>> > >>> > > >> > > > of a CSV list, and is effectively re-balanced daily.
>> Plans
>> > >>> call for
>> > >>> > > >> > a
>> > >>> > > >> > > > full-featured routine in the subscription section
>> called
>> > >>> WtMixRebal
>> > >>> > > >> > that
>> > >>> > > >> > > > implements weighed averages that can be re-balanced at
>> > >>> different
>> > >>> > > >> > periods
>> > >>> > > >> > > > or based upon a signal. This module is useful for index
>> > >>> averages as
>> > >>> > > >> > > > well as portfolio modeling of a weighted list of
>> tickers
>> > >>> with
>> > >>> > > >> > shorting
>> > >>> > > >> > > > and margin with a fast, single function call.
>> > >>> > > >> > > >
>> > >>> > > >> > > > In addition to educational articles, I'm going to try
>> to
>> > >>> cover
>> > >>> > > >> > broader
>> > >>> > > >> > > > topics of applications, with examples, that I've found
>> > >>> useful. In
>> > >>> > > >> > that
>> > >>> > > >> > > > spirit, the next topic will be about connecting to
>> Excel and
>> > >>> > > >> > > > manipulating spreadsheets, charts, and data. That may
>> seem a
>> > >>> little
>> > >>> > > >> > > > odd, but there are many uses for such an interface -
>> both
>> > >>> for input
>> > >>> > > >> > to
>> > >>> > > >> > > > and output from Amibroker. For example - summary bar
>> charts,
>> > >>> command
>> > >>> > > >> > > > button trading control, etc. More later ....
>> > >>> > > >> > > >
>> > >>> > > >> > > > -- BruceR
>> > >>> > > >> > > >
>> > >>> > > >> > > >
>> > >>> > > >> > > >
>> > >>> > > >> > >
>> > >>> > > >> >
>> > >>> > > >>
>> > >>> > > >>
>> > >>> > > >>
>> > >>> > > >
>> > >>> > > >
>> > >>> > >
>> > >>> >
>> > >>>
>> > >>>
>> > >>
>> > >
>> > >
>> > > --
>> > > Gordon Pelletier
>> > > 24 Diamond Rd
>> > > Pearl Beach NSW 2256
>> > >
>> > > email gordonpellet...@...
>> > >
>> > > (02) 43424164
>> > >
>> > > 0407990787
>> > >
>> > >
>> >
>>
>>  
>>
>
>

Reply via email to