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

[amibroker] Re: Real-Time Trading System Examples



PureBytes Links

Trading Reference Links




For 
what it's worth... I have had trouble with setforeign too. It does not always 
seem to work.
<FONT face=Arial color=#0000ff 
size=2> 
I have 
had better luck assigning the data to a variable:
<FONT face=Arial color=#0000ff 
size=2>Index1=Foreign("otc-c","C")
<FONT face=Arial color=#0000ff 
size=2>Index2=Foreign("SP-CP","C")
<FONT face=Arial color=#0000ff 
size=2> 
And 
then calculate relative strength using the variables.
<FONT face=Arial color=#0000ff 
size=2> 
I've 
not run this though IB, but it would be something like this:
<FONT face=Arial color=#0000ff 
size=2> 
<FONT face=Arial color=#0000ff 
size=2>Period=10
<FONT face=Arial color=#0000ff 
size=2>R1=Index1/Ref(Index1,Period)
<FONT face=Arial color=#0000ff 
size=2>R2=Index2/Ref(Index2,Period)
<FONT face=Arial color=#0000ff 
size=2>RS=100*R1/R2
<FONT face=Arial color=#0000ff 
size=2>Plot(RS,"RELATIVE STRENGTH",Colorgreen,Stylethick)
<FONT face=Arial color=#0000ff 
size=2> 
That 
should get you started. 

  
  <FONT 
  face=Tahoma size=2>-----Original Message-----From: ssingh_01803 
  [mailto:ssingh_01803@xxxxxxxxx] Sent: Sunday, April 11, 2004 9:22 
  PMTo: amibroker@xxxxxxxxxxxxxxxSubject: [amibroker] Re: 
  Relative StrengthHi,   Any help on this 
  question ?Thanks,Singh--- In 
  amibroker@xxxxxxxxxxxxxxx, "ssingh_01803" <ssingh_01803@xxxx> 
  wrote:> Hi,>  I would like to plot the relative strenth 
  of "otc-c" with respect > to "SP-CP". I'm using the following code but 
  it seems to always plot > the relative strength of the current 
  symbol and not "otc-c". is > SetForeign() is not supposed to set the 
  current symbol ? > > SetForeign("otc-c"); > Plot( 
  RelStrength("SP-CP"),"Relative Strength", -8 );> RestorePriceArrays(); 
  > > Is there any better way to do this ?> > 
  Thanks,> SinghSend BUG REPORTS to 
  bugs@xxxxxxxxxxxxxSend SUGGESTIONS to 
  suggest@xxxxxxxxxxxxx-----------------------------------------Post 
  AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx (Web page: <A 
  href="">http://groups.yahoo.com/group/amiquote/messages/)--------------------------------------------Check 
  group FAQ at: <A 
  href="">http://groups.yahoo.com/group/amibroker/files/groupfaq.html 
  


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








Yahoo! Groups Sponsor


  ADVERTISEMENT 












Yahoo! Groups Links
To visit your group on the web, go to:http://groups.yahoo.com/group/amibroker/ 
To unsubscribe from this group, send an email to:amibroker-unsubscribe@xxxxxxxxxxxxxxx 
Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.