Log in to see Cloud of Tags

Wealth-Lab Wiki

Search Engine

Here you can search through the pages of this Namespace, their attachments and the files uploaded to the system.
Note: the results will only display the items you have permissions to read.



Filter by Category

















This search, performed through 4.04 MB (775 documents, 11955 words), completed in 0.0 seconds and yielded 30 results.

TASC 2008-11 | Corona Charts (Ehlers) — 3.1%

[...] the Highest and Lowest lead for samples in the list private void PhaseList( ref ArrayList fifo, int cntMax, double lead, out double H, out double L) { H = lead; L = lead; if ( fifo.Count < cntMax ) fifo.Add(lead); else { fifo.RemoveAt(0); fifo.Add(lead); } for ( int n = 0; n < fifo.Count - 1; n++) { double val = ( double )fifo[n]; if ( val > H ) H = val; if ( val < L ) L = val; } } public void SuperIndicators(DataSeries ds, out DataSeries domCycMdn, out DataSeries [...]

Swing Functions — 2.3%

Syntax Community Indicators: public SwingHiLo( Bars bars, int LeftBars, double LeftReversalAmount, int RightBars, double RightReversalAmount, double EqualPriceThreshold, bool PercentMode, bool SetLeftSwings, bool SetOuterSwings, bool SetSteppedSeries, string description ) public SwingHiLo( Bars bars, int LeftBars, int RightBars, double EqualPriceThreshold, bool SetLeftSwings, bool SetOuterSwings, bool SetSteppedSeries, string description ) public static SwingHiLo( Bars [...]

TASC 2013-07 | The Step Candle Pattern (Vervoort) — 1.5%

[...] 1.0); paramLookbackForStepPattern = CreateParameter( "Lookback" , 3, 1, 20, 1); } bool isInsideBody( int bar, double price ) { return price <= Math.Max( Open [bar], Close [bar]) && price >= Math.Min( Open [bar], Close [bar]); } bool Upstep( int bar, int lookback ) { bool result = false ; bool way1 = ( Open [bar] > Close [bar] & Open [bar+1] < Close [bar+1]) && isInsideBody(bar, Open [bar+1]) && Close [bar+1] > Open [bar]; bool way2 = ( Open [bar] [...]

Intraday Support Functions — 1.4%

Syntax public static int GetTime( this WealthScript obj, int bar) public static int GetTime( this Bars bars, int bar) // For use when using a non-synchronized Bars object public int GetTime( int bar) public int GetTime(Bars bars, int bar) // For use when using a non-synchronized Bars object Parameter Description bar Bar number bars Bars object [...]

TASC 2016-09 | Measuring Market Cycles (Ehlers) — 1.0%

[...] 8.0) * Deg2Rad); double c2 = b1; double c3 = -a1 * a1; double c1 = 1 - c2 - c3; for ( int bar = 2; bar < Bars .Count; bar++) { HP[bar] = 0.5*(1 + alpha1) * ( Close [bar] - Close [bar-1]) + alpha1*HP[bar-1]; //Smooth with a SuperSmoother Filter Filt[bar] = c1*(HP[bar] + HP[bar-1]) / 2 + c2*Filt[bar-1] + c3*Filt[bar-2]; } DataSeries[] ds = new DataSeries[48]; ChartPane tp = CreatePane (50, false , false ); for ( int n = 0; n < 48; n++ ) { ds[n] = new DataSeries( Bars ,n. ToString [...]

TASC 2016-05 | Zero In On The MACD (Star) — 0.8%

[...] true , true ); PlotSeries (MACDPane, macd, Color.Red, LineStyle.Histogram, 2); for ( int bar = GetTradingLoopStartBar (55 * 3); bar < Bars .Count; bar++) { bool isBarBlue = false ; bool isAboveMA = Close [bar] > ema[bar]; bool isWarning = ( Close [bar] < wma[bar]) && ( High [bar] > ema[bar]); if ( macd[bar] > 0 ) { SetSeriesBarColor ( bar, macd, Color.Blue ); SetBarColor ( bar, Color.Blue ); isBarBlue = true ; if ( isWarning ) SetBarColor ( bar, Color.Orange [...]

CheckExtendedTrendline — 0.8%

Syntax public static int CheckExtendedTrendline( this WealthScript obj, int bar, ChartPane pane, DataSeries ds, int bar1, int bar2, Color linecolor, int thickness, int consecBars = 1) public int CheckExtendedTrendline( int bar, ChartPane pane, DataSeries ds, int bar1, int bar2, Color linecolor, int [...]

DrawLinRegChannel — 0.8%

Syntax public static void DrawLinRegChannel( this WealthScript obj, int bar, DataSeries ds, int period, double width, Color color, LineStyle style, int line) public static void DrawLinRegChannel( this WealthScript obj, int bar, DataSeries series, int period, Color color, LineStyle style, int line) public static void DrawLinRegChannel( this WealthScript obj, int bar, DataSeries series, [...]

TASC 2008-02 | Trading Divergences (Vervoot) — 0.8%

[...] 5, 1, 30, 1); } // Strategy logic protected override void Execute() { int pkPctPrice = peakPctPrice.ValueInt; int pkPctIndicator = peakPctIndicator.ValueInt; int barsToHold = exitBars.ValueInt; int lastDetectedBar = 0; _barLastChecked = 0; DataSeries rsi = RSI.Series( Close , 14); ChartPane rsiPane = CreatePane (40, true , true ); PlotSeries (rsiPane, rsi, Color.Brown, WealthLab.LineStyle.Solid, 2); for ( int [...]

TASC 2019-11 | The Stochastic MACD Oscillator (Apirine) — 0.8%

[...] 5, 30, 1); exitBars = CreateParameter( "Exit bars" , 20, 1, 30, 1); } private const int proxBars = 6; private int _barLastChecked = 0; protected override void Execute() { int pkPctPrice = peakPctPrice.ValueInt; int pkPctIndicator = peakPctIndicator.ValueInt; int barsToHold = exitBars.ValueInt; int lastDetectedBar = 0; _barLastChecked = 0; var s = STMACD.Series( Bars ,45,12,26); var [...]

Stop/Limit Orders — 0.8%

Syntax public static Position BuyAtStopLimit( this WealthScript ws, int bar, double price) public static Position BuyAtStopLimit( this WealthScript ws, int bar, double price, string signalName) public static Position ShortAtStopLimit( this WealthScript ws, int bar, double price) public static Position ShortAtStopLimit( this WealthScript ws, int bar, double price, string signalName) public static bool SellAtStopLimit( this WealthScript ws, int [...]

Intraday / Multi-Time Frame | Keep from holding positions overnight — 0.7%

[...] LastPosition , "Last Bar" ); } Or in a multiple open positions strategy that translates to: for ( int p = ActivePositions .Count - 1; p >= 0; p--) { Position pos = ActivePositions [p]; // exit on the last bar of the day if ( Bars .IsLastBarOfDay(bar) ) ExitAtClose ( bar, pos, "Last Bar" ); } However, sometimes it gets more tricky. Read on below: Problem I'm trying to code an intraday strategy that doesn't hold any positions overnight. In order to do this I need to keep the buy limit order from being placed on the bar before the last bar of [...]

TASC 2019-09 | A Simple Way To Trade Seasonality (Kaufman) — 0.7%

[...] (); //Collect monthly average price var lstMonths = new List<MonthData>(); for ( int bar = 1; bar < Bars .Count; bar++) { if ( Date [bar].Month ! = Date [bar - 1].Month) //New month { lstMonths.Add( new MonthData( Date [bar].Month, Date [bar].Year, avgMonthlyPrice[bar])); } } //Calculations for ( int bar = GetTradingLoopStartBar ( startBar); bar < Bars .Count; bar++) { if (bar <= 0) continue ; int yearTo = Date [bar].Year; [...]

3/10 Oscillator — 0.7%

Syntax public LBR3_10(DataSeries ds, int period1, int period2, string description) public static LBR3_10 Series(DataSeries [...]

Semi-Cup Pattern Detection — 0.7%

[...] then be accessed from the Cups Dictionary (see Cups member below). public SemiCups(WealthScript ws, int minBars, DataSeries pkBarSer) ws An instance of the WealthScript object. Pass this . minBars The minimum number of bars spanned by a Semicup. For example, if a peak occurs on bar number 100, and minBars is 20, an associated Semicup cannot be detected prior to bar 120. pkBarSer Each Semicup is associated with a peak in the PeakBar.Series. Pass a PeakBar DataSeries. ActiveSemiCups(int bar) For backtesting: returns a list of [...]

TASC 2013-06 | The 1-2-3 Wave Count (Vervoort) — 0.7%

[...] ; ZZBuilder zz = new ZZBuilder( Bars , percent ); List<ZigZag> lst = zz.ZigZags; for ( int bar = 1; bar < Bars .Count; bar++) { if ( IsLastPositionActive ) { Position p = LastPosition ; double ProfitTgt = 0, StopPrice = 0; if ( p.PositionType == PositionType.Long ) { ProfitTgt = p.EntryPrice * (1 + target / 100.0d); StopPrice = p.EntryPrice * (1 - stop / 100.0d); } else { ProfitTgt = p.EntryPrice * (1 - target / 100.0d); StopPrice = p.EntryPrice * (1 + stop / 100.0d); } [...]

TASC 2014-06 | Slope Divergence: Capitalizing On Uncertainty (Kaufman) — 0.6%

[...] Sell = -1, NA = 0 } public class TASC201406_Kaufman : WealthScript { Side SingleDivergence( int bar, int period, int momperiod, DataSeries ps, DataSeries ms, out bool trendup, out bool trenddn, out int p, out int m ) { trendup = (ps[bar] > 0 && ms[bar] > 0); trenddn = (ps[bar] < 0 && ms[bar] < 0); p = ps[bar] >= 0 ? 1 : ps[bar] < 0 ? -1 : 0; m = ms[bar] >= 0 ? 1 : ms[bar] < 0 ? -1 : [...]

Intraday / Multi-Time Frame | Mixing intraday and daily data — 0.6%

[...] daily ); PlotSeries ( PricePane , daily. Close , Color.Black, LineStyle.Dashed, 1 ); for ( int bar = 20; bar < Bars .Count; bar++) { if ( IsLastPositionActive ) { if ( Bars .IsLastBarOfDay( bar ) ) SellAtClose ( bar, LastPosition , "At Close" ); else SellAtStop ( bar+1, LastPosition , Stop, "Stop" ); } else { //if (Date[bar].Hour == 10) if ( Bars .IntradayBarNumber(bar) == 0 ) if ( Open [bar] > daily. Close [bar-1]) if ( Close [bar] > Open [bar]) if ( BuyAtClose [...]

Intraday | Building blocks of Intraday trading strategies — 0.6%

[...] to easily determine and compare time of day public class MyStrategy : WealthScript { public int GetTime( int bar) { return Date [bar].Hour * 100 + Date [bar].Minute; } protected override void Execute() { // Specifically, I use a strategy that buys stocks only in the time period between 9:55 am and 13:00. for ( int bar = 1; bar < Bars .Count; bar++) { if ( IsLastPositionActive ) { // exit rule here... } else if ( ( GetTime(bar) >= 0955 ) & ( GetTime(bar) [...]

Projection Bands — 0.6%

Projection Bands Syntax public PBandUpper( Bars bars, int period, string description) public static PBandUpper Series( Bars bars, int period) public PBandLower( Bars bars, int period, string description) public static PBandLowerSeries( Bars bars, int period) Parameter [...]

TASC 2011-08 | Automated Techniques For Intraday Traders (Coles) — 0.6%

[...] WealthLab.Strategies { public class FibLucas : WealthScript { private StrategyParameter paramAmount; int [] fib = new int [] {5,8,13,21,34,55,89,144,233,377,610,987,1597,2584,4181,6765}; int [] lucas = new int [] {3,4,7,11,18,29,47,76,123,199,322,521,843,1364,2207,3571}; Font font = new Font( "Wingdings" , 8, FontStyle.Bold); Font font2 = new Font( "Verdana" , 7, FontStyle.Regular); string upArrow = Convert.ToChar(0x00E9). ToString (); string dnArrow = Convert.ToChar(0x00EA). [...]

TASC 2015-05 | Filtering Price Movement (Siligardos) — 0.6%

[...] Community.Components; namespace WealthLab.Strategies { internal struct PipInterval { public int X1; public int X2; } public class zzTOPAutoStudy : WealthScript { StrategyParameter _pct; StrategyParameter _thickness; List< int > _pipList; // list of PIP bar numbers public zzTOPAutoStudy() { _pct = CreateParameter( "PIP Percent" , 20, 2, 50, 1); _thickness = CreateParameter( "Line Width" , 2, 1, 3, 1); } int [...]

TASC 2008-03 | Measuring Cycle Periods (Ehlers) — 0.6%

[...] twoPi = 2 * Math.PI; // Initialize arrays ArrayHolder[] ah = new ArrayHolder[51]; for ( int n = 8; n < 51; n++ ) ah[n] = new ArrayHolder(); Color[] color = new Color[21]; DataSeries[] DB = new DataSeries[51]; double domCycle = 0d; string name = ds.Description; DataSeries result = Close - Close ; result.Description = "Dominant Cycle(" + name + ")" ; // Create and plot the decibel series - change the colors later ChartPane dbPane = CreatePane (40, false , false ); for ( int [...]

WeeklyDailyPPO — 0.5%

Syntax public RelativeDailyPPO(DataSeries ds, int DailyLength1, int DailyLength2, int WeeklyLength1, [...]

GetRemainingTradingDays — 0.5%

Syntax public static int GetRemainingTradingDays( this DateTime DateFrom) public static int GetRemainingTradingDays(DateTime DateFrom) Parameter Description DateFrom From which date Description This function returns the approximate number of remaining trading days in a month. For example, it is useful with Strategies that enter X market days before the end of the month and exit on Y market day of the following month. Note that even after handling weekends properly, you're still left with business (banking/trading) [...]

CIV (Cumulative Intraday Volume) — 0.5%

Syntax public CIV( Bars bars, int startTime, int stopTime, string description) public static CIV Series( Bars bars, int startTime, int stopTime) Parameter Description Bars A Bars object startTime Start time stopTime Stop time Description Sums volume from start to stop times, and holds the result constant until it is reset the following day. CIV is the Cumulative Intraday Volume between the supplied start and stop times. Use in [...]

Weekly & Daily MACD — 0.5%

Syntax public RelativeDailyMACD(DataSeries ds, int DailyLength1, int DailyLength2, int WeeklyLength1, [...]

Pattern Recognition — 0.5%

Syntax public static MTop CheckTop( this WealthScript obj, int bar, DataSeries ds, int lookback, double pctRetrace, double threshold) public static WBottom CheckBottom( this WealthScript obj, int bar, DataSeries ds, int lookback, double pctRetrace, double threshold) public MTop CheckTop( int bar, DataSeries ds, int lookback, double pctRetrace, double threshold) public WBottom CheckBottom( int [...]

ATR — 0.5%

Syntax public ATR(WealthLab. Bars bars, int period, string description) public static ATR Series(WealthLab. Bars bars, int period) public static double Value( int bar, WealthLab. Bars bars, int period) Parameter Description bars The Bars object period Indicator calculation period Description The Average True Range is the average of the true ranges over the specified Period. WealthScript uses the moving average as formulated by Welles Wilder, [...]

Alligator (Bill Williams) — 0.5%

Syntax public AlligatorJaw(DataSeries ds, int period, int delay, string description) public static AlligatorJaw Series(DataSeries ds, int [...]

Important Disclaimer: The information provided by Wealth-Lab is strictly for informational purposes and is not to be construed as advice or solicitation to buy or sell any security.  The owner of Wealth-Lab.com assumes no liability resulting from the use of the material contained herein for investment purposes. By using this web site, you agree to the terms of this disclaimer and our Terms of Use.


ScrewTurn Wiki. Some of the icons created by FamFamFam.