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

RE: [amibroker] Newbie needs help with HHV



PureBytes Links

Trading Reference Links




DT, i 
am disappointed in that you say it cannot be done... that is just not like you 
:-) 
<FONT face=Arial color=#0000ff 
size=2> 
You 
can easily save the parameter in a small text file, it will be read on each 
refresh (RT). You can have this file update whenever you use the Param() to 
change background colors, periods, charts displayed, anything you like. Simple 
example:



// 
Indicator with Global Param():
<FONT face=Arial color=#0000ff 
size=2>function SS( FileName, String)    
{    fh = fopen(FileName, "w");    if( fh 
)        
{        fputs(String, fh 
);        fclose( fh 
);        }    return 
fh;}
 
Pd = 
Param("Period",10,10,100,10);Plot(RSI(Pd),"Master 
RSI"+NumToStr(Pd,1.0),4,1);SS( "Period1", 
NumToStr(Pd,1.0));



// 
Indicator with Slave RSI()
<FONT face=Arial color=#0000ff 
size=2>function RS( Filename )    
{    fh = fopen(FileName, "r");    
Str = fgets( fh );    return Str;    } 

 
Pd = 
StrToNum(RS( "Period1" ));Plot(RSI(Pd),"Slave 
RSI"+NumToStr(Pd,1.0),5,1);<SPAN 
class=453314910-01072004>


<FONT face=Arial color=#0000ff 
size=2>herman.

  <FONT face=Tahoma 
  size=2>-----Original Message-----From: DIMITRIS TSOKAKIS 
  [mailto:TSOKAKIS@xxxxxxxxx]Sent: Thursday, July 01, 2004 3:24 
  AMTo: amibroker@xxxxxxxxxxxxxxxSubject: [amibroker] Re: 
  Global Parameter??Ara,This would not give a 
  "global" action [in the sense Ned probably wants].Suppose you save in 
  your Ti3 folder theA=Param("A",10,10,50,10);Y=LinRegSlope(C,A);as 
  LINREG.afl.Now paste in 2 empty IB windows the same#include 
  "C:\Ti3\LINREG.afl";Plot(Y,"Y",1,1);If you set A=40 in the first 
  graph, it does not affect the 2nd.You should set A value in every single 
  indicator.As far as I understand, Ned would like to set A once and see 
  this setting in ANY indicator using A.I do not see how this could be 
  done.Dimitris Tsokakis--- In amibroker@xxxxxxxxxxxxxxx, "Ara 
  Kaloustian" <ara1@xxxx> wrote:> Try using the parameter code in a 
  separate file and bring that file in each> indicator as an #include 
  file.> > ----- Original Message ----- > From: "recce101" 
  <ned@xxxx>> To: <amibroker@xxxxxxxxxxxxxxx>> Sent: 
  Wednesday, June 30, 2004 10:20 PM> Subject: [amibroker] Global 
  Parameter??> > > > I have a considerable number of 
  right-click user-defined parameters> > in my custom indicators, 
  and frequently two or three indicators> > displayed together have 
  similar parameters which need to be adjusted> > at the same 
  time. For example,> >> > LinearRegressionPeriod=Param("LR 
  period",10,5,40,1);> >> > might be used for custom 
  indicators in three separate AFL files.> > Currently I must 
  right-click each indicator separately and adjust its> > linear 
  regression parameter to the value desired. I'm looking for a> > 
  way to define a "global" parameter which would be recognized by 
  all> > three indicators, so one right-click adjustment would 
  suffice for all> > three. This would be similar to how the 
  setting in a Preferences> > window affects all indicators linked to 
  that setting, except that> > these would be user-defined parameters 
  not found in the set of built-> > in Preferences. My search 
  through the help files using "parameter"> > and "global" did not 
  answer my question, though I must confess that I> > did not 
  fully understand a good portion of what I read.> >> > 
  There must be a way to do this, and it's probably very simple, so 
  I> > would appreciate being pointed in the right 
  direction.> >> > Ned> >> >> 
  >> >> > Check AmiBroker web page at:> > <A 
  href="">http://www.amibroker.com/> 
  >> > Check group FAQ at:> <A 
  href="">http://groups.yahoo.com/group/amibroker/files/groupfaq.html> 
  > Yahoo! Groups Links> >> >> >> 
  >> >> >Check AmiBroker web 
  page at:<A 
  href="">http://www.amibroker.com/Check 
  group FAQ at: <A 
  href="">http://groups.yahoo.com/group/amibroker/files/groupfaq.html 
  


Check AmiBroker web page at:
http://www.amibroker.com/

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.