It can be called a (19, 19, 30) Demand Index... 30 the demand index ma length...and 19 Buy/sell power length & Buy/sell moving average length...
Details:
Formula name: Demand Index
Author/Uploader: Steve Wiser - slwiserr [at] erols.com
Date/Time added: 2001-07-05 19:12:36
Origin:
Keywords:
Level: medium
Flags: system,exploration,indicator
DISCLAIMER: Most formulas present in AFL on-line library are submitted by the users and are provided here on an "as is" and "as available" basis. AmiBroker.com makes no representations or warranties of any kind to the contents or the operation of material presented here. We do not maintain nor provide technical support for 3rd party formulas.
Download formula file | Delete formula
Description:
Uses the demand index for a system test.
Formula:
/* Demand Index */
/* Steve Wiser at [email protected] */
/* Exploration, System and indicator */
Comments:
Steve Wiser
slwiserr [at] erols.com
2001-07-06 03:56:13 The Demand Index, developed by James Sibbet,
combines price and volume in such a way that it
is often a leading indicator of price change.
The Demand Index calculations are too complex,
however, for this text. The calculations
require 21-column accounting paper to calculate
manually.
This indicator is an interpetation of the
MetaStock version.
Depending on the urgency of having this study coded, you may want to consider enlisting the services of an EFS Consultant. These are not employees of eSignal, but rather programming consultants who are intimately familiar with EFS coding. They are fee based, so you may want to get some pricing before committing to a particular service. Hope this helps.
The only complexity in this formula code is the addition of two Boolean values:
(A>=Ref(A,-1)) + (A<Ref(A,-1))
The two expressions on either side of the plus sign are relational expressions that the program evaluates to be either TRUE or FALSE. If the condition is TRUE, it is assigned the value of 1. if it is FALSE, it is assigned the value of 0. The results of these two assignments are then added together.
Because these conditions are mutually exclusive, only one can be TRUE at any given time. Also, because of the nature of the expression, one of them will always be TRUE. Therefore, this section of code is always the equivalent of adding 1 plus 0.
I never have the pretention to be a smart programmer otherwise i will not ask for any help! lol
You can see in the first posts i have already defined the REF function...it's just the precedent value of A.
For example in Metastock this function is defined by:
Ref(Data array, periods)
References a previous or subsequent element in a Data array/
ex. The formula "ref(Close, -12)" returns the closing price 12 periods ago.
So Ref(A, -1) should return the value of A one (1) period ago!
(I think it's the same definition in efs language so if not i will be glad to know the best way to write this)
All the Best,
Phil
ps: If you have other questions you can pm me without any problem. Thanks for your help!
Originally posted by pbereau
You can see in the first posts i have already defined the REF function...it's just the precedent value of A.
For example in Metastock this function is defined by:
Ref(Data array, periods)
References a previous or subsequent element in a Data array/
ex. The formula "ref(Close, -12)" returns the closing price 12 periods ago.
I had downloaded the code and looked through your posts, but could not find the function. Regardless, I am presently quite overcommitted and cannot help much, if at all on this.
Regarding the close values, it is straightforward...
For example in eSignal this function is defined by: close( [ nBarIndex ][, sym() | inv() ] ) . The formula "close(-12) " returns the closing price 12 periods ago.
I located this in less than a minute. To do this, click the EFS Knowledgebase link under Handy Links: at the bottom of my post and search for close . The shortcut is available on the eSignal Learning and Product Training drop downs as well.
looking for demand index as origanaly designed by james sibet
i am looking for the efs code for the demand index as created by james sibet and as available on metastock. i have seen a tweeked version but i would love to find the original. also i would love the code to use the total volume for all months for the future we are trying do calculate a demand index as james sibet intended it to be and not only the volume of the specif month. thanks
Comment