Implements a general framework for producing trading signals based on the crossing of two Stochastics.
[Visual Basic]
Overloads Public Shared Function CrossingSignal( _
ByVal seriesName As String , _
ByVal s As Series, _
ByVal noOfPeriods As Integer , _
ByVal method As Integer , _
ByVal lengthOfMA As Integer _
) As Series
[C#]
public static Series CrossingSignal(
string seriesName,
Series s,
int noOfPeriods,
int method,
int lengthOfMA
);
-1, 0, 1 - this method returns either -1, 0, 1 to indicate that either a sell, no action or buy signal was generated.
Methodology
Buy when the Stochastic K, crosses above the MA D and sell when the Stochastic K falls below the MA of Stochastic D. Since this approach is prone to being whip-sawed we use two (general) Stochastics so that a MA of the %K Stochastic of the first Stochastic and an even more smoothed second Stochastic. In this case a sell signal is generated if the first (more sensitive) Stochastic cross below the second (smoothed) Stochastic, and a buy signal is generated if the first Stochastic crosses above the second Stochastic.
FinancialEngine Class | FinancialEngine Members | Overload List
2002 - 2005 Webavail Productions Inc. & Corporate Web Solutions Ltd.. All Rights Reserved.