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

[amibroker] Advanced Get Oscillator



PureBytes Links

Trading Reference Links

David, I think it could be in your columns formula and using writeval() is
unnecessary. Also you have limited the exploration results to only instances
when the two values cross. Suggest you use filter=1; to test if the function
works first. You could also just have Buy=Cross(PCS,PCM); and do a scan for
the signals

function PCRSI(eperc,wperc)
{

Value = EMA( RSI( wperc ), eperc );
AUC = Wilders( Max( C - Ref( C, -1 ), 0 ), wperc );
ADC = Wilders( Max( Ref( C, -1 ) - C, 0 ), wperc );
xc = ( wperc - 1 )*( ADC * Value/(100-Value)-AUC); 
PcRSIP = IIf( xc >= 0, C + xc, C + xc*(100-Value)/Value );

return PCRSIP;
}
//function calls
PCS=PCRSI(50,18);
PCM=PCRSI(100,21);

Filter = 1;//Cross(PCS,PCM);
AddColumn(Cross(PCS,PCM),"Cross",1);
AddColumn(PCS, "PCS", 1.2);
AddColumn(PCM, "PCM", 1.2);

Cheers,
Graham
http://e-wire.net.au/~eb_kavan/

-----Original Message-----
From: wooziwog [mailto:xcitemint@xxxxxxx] 
Sent: Wednesday, March 17, 2004 10:21 AM
To: amibroker@xxxxxxxxxxxxxxx
Subject: [amibroker] Formula help please

I am trying to do a crossover exploration with no success, the values 
for "PCS" and "PCM" values do not appear in the columns, the columns 
are blank.  Can anyone help with this?  Any help will be appreciated.
Thanks.

David K.

function PCRSI(eperc,wperc)
{

Value = EMA( RSI( wperc ), eperc );
AUC = Wilders( Max( C - Ref( C, -1 ), 0 ), wperc );
ADC = Wilders( Max( Ref( C, -1 ) - C, 0 ), wperc );
xc = ( wperc - 1 )*( ADC * Value/(100-Value)-AUC); 
PcRSIP = IIf( xc >= 0, C + xc, C + xc*(100-Value)/Value );

return PCRSIP;
}
//function calls
PCS=PCRSI(50,18);
PCM=PCRSI(100,21);

Filter = Cross(PCS,PCM);
Column1 = PCS;
Column1Name = "PCS";Column1 = PCS; WriteVal(PCS);
Column2 = PCM;
Column2Name = "PCM";Column2 = PCM; WriteVal(PCM); 




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 Links



 



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 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:
     http://docs.yahoo.com/info/terms/