George,
Your code is asking AB to retreive a value (from the future) that does not
exist yet.
To find the value of price that will cause a particular event you need to do
some math to compute the value.
The math in this case would require the equations for the 2 moving averages
to be equal, (
Gerald, just try to figure out how to get all this working in the way
that it's acceptable for you. With AB there are often many different ways
to manage your tasks. In my case, I hardly ever use the mouse and just
absolutely hate drag-&-drop and never ever use it with any application,
so when
I've made everything as written here
http://finance.groups.yahoo.com/group/amibroker/message/94651
--- In amibroker@yahoogroups.com, vikas soni <[EMAIL PROTECTED]> wrote:
>
>
> hi Vosmerkin, Can u plz elaborate this tht who u joined AmiBroker
and Excel to get data in real time.
>
> Also which P
I use universal DDE plug-in
--- In amibroker@yahoogroups.com, vikas soni <[EMAIL PROTECTED]> wrote:
>
>
> hi Vosmerkin, Can u plz elaborate this tht who u joined AmiBroker
and Excel to get data in real time.
>
> Also which Plugin u use.?
>
>
> "vosmerkin.evgen" <[EMAIL PROTECTED]> wrote:
GP, thank you for the help, I want to make a continuation of the
Displaced MA(28,-14) and with your help it will do this for the last 14
days but it seems that it is verticaly displaced. Is any way we can
make this to plot in the continuation of the DMA(28,-14). I'll put here
the entire code I
Thanks Graham
Rick
--- Graham <[EMAIL PROTECTED]> wrote:
> equity(1,0);
>
plot(valuewhen(Cover==4,CoverPrice),"CoverPrice",colorblue);
>
plot(valuewhen(Sell==4,SellPrice),"SellPrice",colorblue);
>
> if you have a delay on the exit, then you need to
> allow for this in
> the valuewhen, here is th
equity(1,0);
plot(valuewhen(Cover==4,CoverPrice),"CoverPrice",colorblue);
plot(valuewhen(Sell==4,SellPrice),"SellPrice",colorblue);
if you have a delay on the exit, then you need to allow for this in
the valuewhen, here is the exit prices if the exit is 1 bar after the
applystop signal
equity(1,0)
Yes - I have Equity(1) included
What I want to plot is the "actual price" that the
system got stopped out at using...
for( i = 0; i < BarCount; i++ )
{
if(Cover[i] ==4)PlotText( "Short\nStop " +
CoverPrice[i], i, L[ i ]-dist[i]*2, colorYellow
,colorBlueGrey);
if( Sell[i]==4 ) PlotText( "Long\n
if it has an array identifier, in thos case [bar] then it is processed
as an array
If not then it is scalar value, but only the last value of scalar
values inside a loop will be passed back to the normal AFL, only
arrays can have different values to be read after the loop in the AFL.
--
Cheers
Gr
It's a single number, not an array.
I'm not sure how the AFL interpreter decides, but I'm guessing the
preprocessor probably scans the file first to see if it's used as an
array anywhere and makes it an array if it is, otherwise it makes it a
single number. That's just a guess though.
GP
--- In
Hi
Good idea. I have another idea but it works or not i don't have any idea. It is
upto you. You have used same color between the bands irrespective of the price
up or down.
Can you make it that one when the price is above 20 SMA color between the bands
one color (let's say light green) and p
In the code below, is sellBar1 an array or a scalar?
How does afl decide whether to allocate an array?
sellBar1 = -100;
for (bar = 1; bar < BarCount; bar++)
{
if (sellTrigger[bar])
{
Sell[bar] = 1;
sellBar1 = bar;
}
}
Rick,
Don't you need a call to Equity(1) in there somewhere to update the
cover array with the stop information?
For #2, what "this" are you plotting - the ATR function or TrailStop?
TrailStop is delayed by a bar because of the Ref( ,-1).
GP
--- In amibroker@yahoogroups.com, Rick Osborn <[EMAI
Try this
//-
stats = "NotYetTransmitted"; // any status
if((List = ibc.GetPendingList( 1, stats )) == "") List = "empty";
"List is: " + List;
//-
BR
Eric
--- In amibroker@yahoogroups.com, "sono_080" <[EMAIL PROTECTED]> wrote:
>
> Hello, how can i control that the
--- In amibroker@yahoogroups.com, "vlanschot" <[EMAIL PROTECTED]> wrote:
>
> Gerald,
>
> In case you haven't:
> - use Apply indicator from Formula Editor to insert it;
> - or from file-tree: right-click on indicator-AFL, then "insert linked"
> - I assume you've set your directory in Preferences->A
Anybody
--- ricko8294_98 <[EMAIL PROTECTED]> wrote:
> I am using the following Applystop code
>
> ATRSet = Optimize("ATRset",40,10,70,5);
> ATRMult = Optimize("AtrMult",4,2,8,1);
> TrailStop = Ref(ATR(ATRSet ) * ATRMult ,-1);
> ApplyStop(stopTypeTrailing, stopModePoint,
> TrailStop, True, T
--- In amibroker@yahoogroups.com, "indianguyinny24"
<[EMAIL PROTECTED]> wrote:
>
> Hi all,
>
> i am looking for some advice and guidance to how to use this
> system ...which seems to have quote a respect in various places...
>
> i have been working with neural netowrk and genetic algorithm for
Gakkhar,
For 'n' bars:
Formula1 = IIf(Cum(1)>BarCount-n, Formula1, Null);
GP
--- In amibroker@yahoogroups.com, "Vinay Gakkhar." <[EMAIL PROTECTED]> wrote:
>
> Dear GP,
>
> If, instead of 1 bar, I want 2 or 3 bars, what change should I make
in the formula?
>
> gakkhar
>
> --- Forwarded m
Enough, already?
-Original Message-
From: amibroker@yahoogroups.com [mailto:[EMAIL PROTECTED] Behalf
Of Vinay Gakkhar.
Sent: Monday, June 18, 2007 5:00 PM
To: amibroker
Subject: [amibroker] PLOTTING OUTPUT
Dear GP,
If, instead of 1 bar, I want 2 or 3 bars, what change should I make in th
Dear GP,
If, instead of 1 bar, I want 2 or 3 bars, what change should I make in the
formula?
gakkhar
--- Forwarded message ---
From: gp_sydney <[EMAIL PROTECTED]>
To: amibroker@yahoogroups.com
Cc:
Subject: [amibroker] Re: PLOTTING OUTPUT
Date: Tue, 19 Jun 2007 04:03:44 +0530
Gakkhar,
Dear GP,
Thanks.
gakkhar
--- Forwarded message ---
From: gp_sydney <[EMAIL PROTECTED]>
To: amibroker@yahoogroups.com
Cc:
Subject: [amibroker] Re: PLOTTING OUTPUT
Date: Tue, 19 Jun 2007 05:06:32 +0530
Gakkhar,
Sorry, just realised BarIndex is not a new function - I got confused
by the r
Gakkhar,
Sorry, just realised BarIndex is not a new function - I got confused
by the red star in the help. And according to the help, it may not be
accurate if QuickAFL is on, in which case you might need:
bi = BarIndex();
Formula1 = IIf(bi-bi[0]==BarCount-1, Formula1, Null);
GP
--- In amibrok
> Actually, I just noticed there's a new function called BarIndex()
Sorry, just realised this is not a new function (got confused by the
red star in the help) and that according to the help, it may not be
accurate if QuickAFL is on. So if using that, I think you might need:
bi = BarIndex();
s5 =
Gakkhar,
Just noticed there's a new function BarIndex() that is supposedly
faster than Cum():
Formula1 = IIf(BarIndex()==BarCount-1, Formula1, Null);
GP
--- In amibroker@yahoogroups.com, "Vinay Gakkhar." <[EMAIL PROTECTED]> wrote:
>
> Dear GP,
>
> You're right! I should have noticed it myself
For those of you who found the Colored Bollinger Bands useful, I have made a
slight change to make it a bit more eye appealing, by coloring area between
Bands.
Below find the code.
Enjoy,
Don Lindberg
Cut Here -
//Colored Bolling
Ray,
This should work (using the Close array):
s5 = IIf(Cum(1) > BarCount-14, MA(Close, 5), Null);
Plot(s5, etc...);
Actually, I just noticed there's a new function called BarIndex()
which will do the same job:
s5 = IIf(BarIndex() >= BarCount-14, MA(Close, 5), Null);
GP
--- In amibroker@yah
Dear GP,
You're right! I should have noticed it myself.
Many thanks for your guidance.
gakkhar
--- Forwarded message ---
From: gp_sydney <[EMAIL PROTECTED]>
To: amibroker@yahoogroups.com
Cc:
Subject: [amibroker] Re: PLOTTING OUTPUT
Date: Tue, 19 Jun 2007 04:03:44 +0530
Gakkhar,
My sta
Hello, I try to plot a SMA(5) only for the last 14 days on the chart,
but I can't figure out how to write the formula to do this. Any help is
appreciated, Thank you, Ray
Gakkhar,
My statement:
> Formula1 = IIf(Cum(1)==BarCount, Formula1, Null);
Your statement:
> formula1 = IIf(Cum(0)==BarCount, formula1, Null);
Spot the difference...
GP
What code will enable me to automatically rename the ~~~Equity result after
a backtest?
What manual method can be used to "save" equity results for various tests?
Thanks for suggestions.
Ken
I think, another way how to code this is:
waitPeriod = 10;
triggerPercentage = 1;
SetupLong = Hold(C < BBandBot(C, 20, 2), waitPeriod);
SetupPriceLong = ValueWhen(SetupLong,H) * triggerPercentage;
Buy = Cross(H, SetupPriceLong) AND SetupLong;
BuyPrice = SetupPriceLong;
Greetings, Thomas
> This
Hi Mr. Don Lindberg
Belated thanks to you for providing this AFL.
In my opinion this is wonderful afl. You are absolutely right...using
this afl as a brick we can play such a wonderful games around stocks.
I have tested this and it is effectively working on 1 hr & 4 hr charts
perfectly comparing
Don, don't know what's up with your system but GetExtraData works for me,
including your clip below when headed with a Filter =1;
Joe .
- Original Message -
From: Don Lindberg
To: amibroker@yahoogroups.com
Sent: Monday, June 18, 2007 10:38 AM
Subject: [amibroker] Problems w
From: "sono_080" <[EMAIL PROTECTED]>
To:
Sent: Monday, June 18, 2007 2:04 AM
Subject: [amibroker] Date/Time: Now + 5 Minutes
> Hello,
>
> im searching for a timestop for orders via IBController.
>
> Now is 18.06.2007 11:05:00
>
> and i need
>
> "GTD 20
I use the GetExtraData fuction to pull almost all of the Quotes Plus
Extra Data fields into various Explorations and Indicators. Sample
code fllows:
AddColumn(GetExtraData("QRS"),"QRS Rank",6.2 ,IIf( GetExtraData
("QRS") >=80, colorGreen, colorOrange ));
AddColumn(GetExtraData("EPSRank"),"EPS Ra
Dear GP,
Here is the whole formula that I was previously using:
LastClose = TimeFrameGetPrice( "C", in5Minute, 0) ; // initialize LastClose
Last5Min = TimeFrameGetPrice( "C", in5Minute, -1) ; // initialize Last5Min
Diff5Min = LastClose-Last5Min ; // initialize Diff5Min
Plot (LastClose, "LastClo
Dear GP,
Here is the whole formula that I was previously using:
LastClose = TimeFrameGetPrice( "C", in5Minute, 0) ; // initialize LastClose
Last5Min = TimeFrameGetPrice( "C", in5Minute, -1) ; // initialize Last5Min
Diff5Min = LastClose-Last5Min ; // initialize Diff5Min
Plot (LastClose, "LastClo
I am using the following Applystop code
ATRSet = Optimize("ATRset",40,10,70,5);
ATRMult = Optimize("AtrMult",4,2,8,1);
TrailStop = Ref(ATR(ATRSet ) * ATRMult ,-1);
ApplyStop(stopTypeTrailing, stopModePoint, TrailStop, True, True);
and want to print out on my chart when the stop kicked in and wha
>From a quick look through without trying it, and assuming that
Longsetup is a True/False type array, I can't see any reason why it
wouldn't work. I could be missing something though.
One thing that may need to be considered is whether the Cross function
will return True if H and HHV(H,3) are the
hi Vosmerkin, Can u plz elaborate this tht who u joined AmiBroker and Excel to
get data in real time.
Also which Plugin u use.?
"vosmerkin.evgen" <[EMAIL PROTECTED]> wrote:
I've made DDE connection to Excel. In excel sheet I have fields
"Ticker" , "Last", "Hi
Indeed a very good document. Very helpful ...
Thanks, Ton.
- Original Message -
From: Grant Noble
To: amibroker@yahoogroups.com
Sent: Monday, June 18, 2007 1:18 AM
Subject: Re: [amibroker] New file uploaded to amibroker
Nice piece of work. Many thanks for taking the time
Gerald,
In case you haven't:
- use Apply indicator from Formula Editor to insert it;
- or from file-tree: right-click on indicator-AFL, then "insert linked"
- I assume you've set your directory in Preferences->AFL->Formula tree
root path.
Saving lay-out, etc. should now keep all your changes fro
Hello,
im searching for a timestop for orders via IBController.
Now is 18.06.2007 11:05:00
and i need
"GTD 20070618 11:10:00 GMT"
Can u help me please?
Thx
Hi
I would like to create a new data source for interday RT data that is
does not exists in the existing data sources ( for TASE ).
looking in the documentation i understand that it is possible to have
a DDE based solution which is not an alternative for me.
Any suggestion how to start with ?
I
Hi all,
i am looking for some advice and guidance to how to use this
system ...which seems to have quote a respect in various places...
i have been working with neural netowrk and genetic algorithm for data
mining on thestock market data previously...
any how to start guidance would be grt...
I've made DDE connection to Excel. In excel sheet I have fields
"Ticker" , "Last", "High", "Low" etc.
In DDE plugin I've wrote
DATA!{ticker}_Last
DATA!{ticker}_High etc. in corresponding fields.
Excel's cells were named like {ticker}_Last...etc.
I've added in amibroker symbol {ticker}. Chart - Pr
Excellent guide GP, thanks for your contribution.
PS
--- In amibroker@yahoogroups.com, amibroker@yahoogroups.com wrote:
>
>
> Hello,
>
> This email message is a notification to let you know that
> a file has been uploaded to the Files area of the amibroker
> group.
>
> File: /AmiBrok
47 matches
Mail list logo