PureBytes Links
Trading Reference Links
|
Hi Erkan,
the syntax error says:
Condition in IF, WHILE, FOR statements
has to be Numeric or Boolean type. You can not use array
here, please use [] (array subscript operator) to access
array elements
UM
<BLOCKQUOTE
>
----- Original Message -----
<DIV
>From:
ERKAN BISEVAC
To: <A title=amibroker@xxxxxxxxxxxxxxx
href="">amibroker@xxxxxxxxxxxxxxx
Sent: Saturday, April 26, 2003 1:51
AM
Subject: [amibroker] CONES
<BLOCKQUOTE
>
I am trying to translate one indicator but it's not working.
Can somebody look at this, please.
Thanks
Erkan
VolatilityLength=<FONT color=#ff00ff
size=1>30/<FONT color=#ff00ff
size=1>252;
SD=2<FONT color=#000000
size=1>;
VIX=Foreign<FONT color=#000000
size=1>("^Vix"<FONT color=#000000
size=1>,"C"<FONT color=#000000
size=1>);
PriceRows=75<FONT color=#000000
size=1>;
BarColumns=75<FONT color=#000000
size=1>;
VolatilitySDev = SD*(0.01<FONT
color=#000000 size=1>*VIX)*<FONT color=#0000ff
size=1>sqrt(volatilitylength);
MT = Close + (Close * VolatilitySDev);
MB = Close - (Close * VolatilitySDev);
RH = (MapTop - MapBottom) / PriceRows;
CL=Close;
for(<FONT face="Courier New" color=#000000
size=1>I=<FONT color=#ff00ff
size=1>1;<FONT face="Courier New"
color=#000000 size=1>i<=<FONT
face="Courier New" color=#000000 size=1>BARCOLU<FONT color=#000000
size=1>mns;<FONT face="Courier New" color=#000000
size=1>i++)
{
PriceLevel = M<FONT face="Courier New" color=#000000
size=1>B[I];
while (PriceLevel < MT<FONT face="Courier New"
color=#000000 size=1>[I])
{
if (PriceLevel < C<FONT face="Courier New" color=#000000
size=1>L[I])
Probability = 1<FONT
face="Courier New" color=#000000 size=1>;
<FONT color=#000000
size=1>
else
{
Probability = .5;
}
<FONT color=#000000
size=1>
Plot<FONT color=#000000
size=1>(PriceLevel*(1<FONT
color=#000000 size=1>-Probability),<FONT color=#ff00ff
size=1>"UP",<FONT color=#ff00ff
size=1>1,<FONT color=#ff00ff
size=1>1);
Plot<FONT color=#000000
size=1>(PriceLevel*(1<FONT
color=#000000 size=1>+Probability),<FONT color=#ff00ff
size=1>"UP",<FONT color=#ff00ff
size=1>1,<FONT color=#ff00ff
size=1>1);
PriceLevel = PriceLevel + RH<FONT face="Courier New" color=#000000
size=1>[I];
}
}
Yahoo! Groups Sponsor
Send BUG REPORTS to bugs@xxxxxxxxxxxxx
Send SUGGESTIONS to suggest@xxxxxxxxxxxxx
-----------------------------------------
Post AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx
(Web page: http://groups.yahoo.com/group/amiquote/messages/)
--------------------------------------------
Check group FAQ at: http://groups.yahoo.com/group/amibroker/files/groupfaq.html
Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
|