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.1 seconds and yielded 30 results.

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

[...] IRSTS_StepPattern() { paramPercent = CreateParameter("Reversal %", 10.0, 1.0, 50.0, 1.0); paramLookbackForStepPattern = CreateParameter("Lookback", 3, 1, 20, 1); } bool isInsideBody( int bar, double price ) { return price bar ,Close bar ) && price >= Math.Min(Open bar ,Close bar ); } bool Upstep( int bar, int lookback ) { bool result = false; bool way1 = (Open bar [...]

TASC 2016-10 | Which Trend Indicator Wins? (Katsanos) — 1.9%

[...] periodADX = 14, adxTrend = 30, adxMax = 42, mab = 50, crit = 22, adxLag = 12; double adxMult = 1.8; var c = obj.Close; var adx = ADX.Series(obj.Bars,periodADX); var avgMAB = SMA.Series(c,mab); var adxLow = Lowest.Series(adx,adxLag); ChartPane p = obj.CreatePane(30,true,true); obj.PlotSeries(p, adx, Color.Red, LineStyle.Solid, 2 ); for(int bar = obj.GetTradingLoopStartBar(1); bar bar bar > avgMAB bar ) obj.BuyAtMarket(bar+1,"Strong Trend"); if( adx bar > adxMult * [...]

TASC 2009-02 | Trading the Aussie (Katsanos) — 1.3%

[...] DateTime(2003, 4, 23), false); for(int bar = 0; bar bar = yba stBar ; // Based calculations from raw data and then synchronize DataSeries ybaSMA = Synchronize( SMA.Series(yba, 40) ); DataSeries xauROC = Synchronize( ROC.Series(xau, 1) ); DataSeries crbROC = Synchronize( ROC.Series(crb, 1) ); DataSeries ejROC = Synchronize( ROC.Series(ej, 2) ); ej = Synchronize( ej ); yba = Synchronize( yba ); DataSeries sec1BOL = SecBol( Close, per ); DataSeries [...]

TASC 2011-05 | Volume Zone Oscillator (Khalil, Steckler) — 1.1%

[...] ); EMA ema = EMA.Series( Close, 60, EMACalculation.Modern ); for(int bar = period; bar bar = Math.Sign( Close bar - Close bar-1 ) * Volume bar ; } DataSeries VP = EMA.Series( R, period, EMACalculation.Modern ); for(int bar = period; bar bar != 0 ) VZO bar = 100 * VP bar / TV bar ; } ChartPane vzoPane = CreatePa

TASC 2011-06 | Entering The Price Zone (Khalil, Steckler) — 1.1%

[...] ); EMA ema = EMA.Series( Close, 60, EMACalculation.Modern ); for(int bar = period; bar bar = Math.Sign( Close bar - Close bar-1 ) * Close bar ; } DataSeries VP = EMA.Series( R, period, EMACalculation.Modern ); for(int bar = period; bar bar != 0 ) PZO bar = 100 * VP bar / TV bar ; } ChartPane pzoPane = CreatePa

Introductory | Bars, Loops, and Bar + 1 — 1.0%

Bars, Loops, and Bar + 1 Original article by Robert Sucher in the legacy Knowledge Base here . Wealth-Lab Developer has features such as order slippage and variable commissions to bring trading simulation as close to reality as possible. Likewise, your task as a trading system designer is to express your system in C# code that validly recreates security orders as they would have been and will be executed in real life. Bar Definition A bar is any interval of time that has an open, high, low, and closing [...]

TASC 2015-10 | The Money Flow Oscillator (Apirine) — 1.0%

[...] from recent peaks or troughs. System rules Once a bullish divergence is detected, enter long next bar at open if MFO is below its centerline Exit long next bar at open when MFO crosses above the centerline Trades from the short side are deliberately not taken as their performance seems poor. Figure 1. Bullish divergence between the MFO and price formed in June 2015 triggered a long trade in KO (Coca Cola). After updating the TASCIndicators library to v2015.09 or later, the MoneyFlowOscillator indicator can be found under the TASC [...]

TASC 2021-01 | A Fresh Look At Short-Term Patterns (Kaufman) — 1.0%

[...] atrPeriod); var trendFilter = SMA.Series(Close, maPeriod); for(int bar = GetTradingLoopStartBar(Math.Max(atrPeriod,maPeriod)); bar bar > High bar - 1 && Low bar bar - 1 && Close bar bar - 1 ; bool keyRevBull = High bar > High bar - 1 && Low bar bar - 1 && Close bar > High bar - 1 ; //island reversal bool islRevBear = Low bar > [...]

TASC 2015-07 | The Slow Relative Strength Index (Apirine) — 1.0%

[...] 100, 1); paramThresholdForTrend = CreateParameter("ADX Threshold", 30, 10, 50, 10); paramHighest = CreateParameter("Highest high of", 20, 5, 50, 1); paramExitDays = CreateParameter("Exit after", 20, 1, 50, 1); } protected override void Execute() { bool peak = false; int peakBar = -1; int high = paramHighest.ValueInt; bool trough = false; int troughBar = -1; int low = paramHighest.ValueInt; int period = paramPeriod.ValueInt; int periodWMA = paramPeriodWMA.ValueInt; int days [...]

FAQ | Strategies and WealthScript — 0.9%

[...] to create a Pullback in an Uptrend entry. For instance, in an established uptrend, wait for a three bar pullback and enter at stop $0.10 above prior bar high. However, the Rule Wizard doesn't seem to have "Buy at Stop" rule desired. Solution: You can get pretty close by starting with these rules: BuyAtLimit (High) - Moving Average is trending up (Moving Average group) - Price decreases a consecutive number of bars (Price (or Volume) group) ..and add an exit (if you only want a screen, see Techniques > Creating a Screener in the WealthScript [...]

TASC 2009-11 | Seasonal System for Soybean Futures (Katsanos) Rev A — 0.9%

[...] the Symbol Info Manager: Futures Mode: enabled Symbol: ZS; Type: Future; Margin: 4000; Point Value: 50; Tick: 0.25; Decimals: 2 WealthScript Code (C#) /* Seasonal Soybean Strategy per Katsanos article EL code */ using System; using System.Collections.Generic; using System.Text; using System.Drawing; using WealthLab; using WealthLab.Indicators; namespace WealthLab.Strategies { public class MyStrategy : WealthScript { StrategyParameter D1DXY; StrategyParameter D2SNL; StrategyParameter LRSDXYSELL; StrategyParameter LRSNLSELL; StrategyParameter MASELL; StrategyParameter [...]

TASC 2017-12 | Weekly & Daily MACD (Apirine) — 0.9%

[...] 130, 60, 300, 10); paramExitDays = CreateParameter("Exit after", 20, 1, 50, 1); paramDailyLength1 = CreateParameter("Daily Length 1",12,2,300,20); paramDailyLength2 = CreateParameter("Daily Length 2",26,2,300,20); paramWeeklyLength1 = CreateParameter("Weekly Length 1",60,2,300,20); paramWeeklyLength2 = CreateParameter("Weekly Length 2",130,2,300,20); } protected override void Execute() { if( Bars.Scale != BarScale.Daily ) { DrawLabel(PricePane, "Switch to Daily scale"); Abort(); } bool peak = false; int peakBar = [...]

TASC 2014-09 | Finding The Golden Triangle (Hudgin) — 0.8%

[...] GoldenTriangleStrategy() { paramRiseBars = CreateParameter("Rise: X bars", 50, 10, 100, 10); paramWhiteSpace = CreateParameter("White space %", 50, 10, 100, 10); paramMinRise = CreateParameter("Min. rise %", 10, 5, 200, 5); paramSMA = CreateParameter("SMA period", 50, 10, 200, 10); paramMom = CreateParameter("Momentum period", 10, 2, 30, 2); paramHi = CreateParameter("Highest period", 20, 10, 100, 10); paramProximity = CreateParameter("Within SMA %", 2, 1, 5, 1); paramPullback = CreateParameter("Pullback [...]

Intraday Support Functions — 0.8%

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 GetTime returns 24-hour time as an integer. Example: 4pm = 1600 Syntax [...]

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

[...] PricePane, daily.Close, Color.Black, LineStyle.Dashed, 1 ); for(int bar = 20; bar bar .Hour == 10) if ( Bars.IntradayBarNumber(bar) == 0 ) if (Open bar > daily.Close bar-1 ) if (Close bar > Open bar ) if( BuyAtClose(bar) != null ) Stop = daily.Close bar-1 ; } } } else DrawLabel( PricePane, "For use on intraday data", Color.Red ); } } }

TASC 2020-08 | Tracking Relative Strength In Four Dimensions (RS4r) (Garofallou) — 0.7%

[...] MA: Blue int Tier1 = 0, Tier2 = 0, Tier3 = 0, Tier4 = 0; for (int bar = GetTradingLoopStartBar(Math.Max(period * 3, 30)); bar bar >= Med bar && Med bar >= Slow bar && Slow bar >= Vslow bar ) ? 10 : 0; Tier2 = (Fast bar >= Med bar && Med bar >= Slow bar && Slow bar bar ) ? 9 : 0; Tier3 = (Fast bar bar && Med bar >= Slow [...]

Intraday | Building blocks of Intraday trading strategies — 0.7%

[...] 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 = 0955 ) & ( GetTime(bar) Identify the Open price of the day when working with intraday data Here's [...]

TASC 2009-07 | Tr&nd Stop (Vervoort) — 0.7%

[...] DataSeries(b, "TrendsStop(" + period + "," + factor + ")"); for (int bar = 0; bar bar = b.Low bar ; for (int bar = period; bar bar-2 ; double prev = trends bar-1 ; if( (b.Low bar >= [...]

TASC 2013-10 | An Expert Of A System (Vervoort) — 0.7%

[...] above the 2nd one and the previous value was less than or equal to the target value at the previous bar. Motivated traders can compare approaches by commenting and uncommenting these lines: if( CrossUnder( bar, tpEma, haEma ) ) //if( tpEma bar bar ) ... if( CrossOver( bar, tpEma, haEma ) ) //if( tpEma bar > haEma bar ) To run the sample Strategy in Wealth-Lab, you'll need the TASCIndicators [...]

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

[...] changed from 12 to 51, and DataSeries initializations have been simplified. // WAS: double Trend = ds bar - ds cycPeriod ; // SHOULD BE (IS): double Trend = ds bar - ds bar - cycPeriod ; /* Strategy Code revised 20090611 */ using System; using System.Collections; using System.Collections.Generic; using System.Text; using System.Drawing; using WealthLab; using WealthLab.Indicators; namespace WealthLab.Strategies { public class CoronaCharts : WealthScript { public const double twoPi = 2 * Math.PI; public const [...]

TASC 2017-07 | Trading The Nikkei (Katsanos) — 0.7%

[...] generated short signals. Figure 1 . Trades generated by the intermarket divergence system with the 50-day regression divergence indicator plotted on the top. Get the companion Strategy's C# code by downloading it right from Wealth-Lab's "Open Strategy" dialog: using System; using System.Collections.Generic; using System.Text; using System.Drawing; using WealthLab; using WealthLab.Indicators; using TASCIndicators; namespace WealthLab.Strategies { public class MyStrategy : WealthScript { private StrategyParameter slider1; private StrategyParameter slider2; private [...]

Stop/Limit Orders — 0.7%

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 bar, Position p, [...]

TASC 2017-10 | A Candlestick Strategy With Soldiers And Crows (D'Ambrosio, Star) — 0.6%

[...] for easy reference in users' Strategies. Here's the complete list of Strategy rules: Enter long next bar at open if following conditions are met: Stock price greater than $1 50-day simple moving average of volume is greater than 100,000 Yesterday’s close was less than the day before Yesterday’s close was less than its open Today’s open is greater than yesterday’s close Today’s close is greater than yesterday’s open Today’s open is less than yesterday’s open As of yesterday’s close, price had been closing lower for three days Sell short [...]

TASC 2016-01 | Simplify It (Rich, Rich) — 0.6%

[...] spy = GetExternalSymbol("SPY",true); SMA spySma = SMA.Series(spy.Close,50); SMA sma20 = SMA.Series(Close,20); SMA sma50 = SMA.Series(Close,50); SMA sma200 = SMA.Series(Close,200); SMA smaHi = SMA.Series(High,8); SMA smaLo = SMA.Series(Low,8); //PlotSeries(PricePane,sma20,Color.Orange,WealthLab.LineStyle.Solid,1); PlotSeries(PricePane,sma50,Color.Red,WealthLab.LineStyle.Solid,1); //PlotSeries(PricePane,sma200,Color.Blue,WealthLab.LineStyle.Solid,1); PlotSeriesFillBand(PricePane, smaHi, smaLo, Color.Green, [...]

TASC 2015-03 | Kiss & Touch With The Modified True Range (Lindgren) — 0.6%

[...] the average MTR by 3 standard deviations of MTR or greater. An entry is triggered when: Buy next bar at market if today's close price has declined. Short next bar at market if today's close price has increased. A position is exited with a simple trailing channel exit: Exit long when today's low price has broke below the 3-day lowest price. Cover short when today's high price has broke above the 3-day highest price. This system is merely a proof-of-concept. Among possible enhancements to this barebone system, the following can be [...]

TASC 2012-11 | Identify the Start of a New Trend with DMI (Low) — 0.6%

[...] = Convergence( lstADX, 10, paramADXThDn.ValueInt, true ); bool adxTurnup = TurnUp(bar, adx4) && TurnUp(bar, adx5) && TurnUp(bar, adx6); bool adxTurndown = TurnDown(bar, adx4) && TurnDown(bar, adx5) && TurnDown(bar, adx6); bool dipTurnup = TurnUp(bar, dip5) && TurnUp(bar, dip8) && TurnUp(bar, dip14); bool dimTurnup = TurnUp(bar, dim5) && TurnUp(bar, dim8) && TurnUp(bar, dim14); // Signal 1: start of an uptrend if( adxConvergingUp && adxTurnup ) { SetBackgroundColor(

TASC 2013-03 | Camarilla Points (Bobrowski) — 0.6%

[...] bar = 0; bar bar = bar; RestoreScale(); dailyBars = Synchronize(dailyBars); DataSeries GetDailyBar = Synchronize(CompBar); // Initialize an instance of the CamarillaPoint class Camarilla c = new Camarilla(); double tick = Bars.SymbolInfo.Tick; bool enterTrades = true; bool canTrade = true; Entry e = paramEntryType.ValueInt == 0 ? Entry.Inside : paramEntryType.ValueInt == 1 ? Entry.Outside : Entry.Breakout; // [...]

TASC 2010-03 | Empirical Mode Decomposition (Ehlers, Way) — 0.6%

[...] public EmpiricalModeDecomp() { _period = CreateParameter("Period", 20, 5, 50, 1); _delta = CreateParameter("Delta", 0.5, 0.05, 1, 0.05); _fraction = CreateParameter("Fraction", 0.25, 0.1, 1, 0.05); } public DataSeries BandPassSeries(DataSeries ds, int period, double delta) { DataSeries res = new DataSeries(ds, "BandPassSeries(" + ds.Description + "," + period + "," + delta + ")"); double beta = Math.Cos(2 * Math.PI / period); double gamma = 1/ Math.Cos(4 * Math.PI * delta / period); double alpha = gamma - Math.Sqrt(gamma [...]

TASC 2013-01 | The DMI Stochastic (Star) — 0.6%

[...] almost any entry style without adding prejudice. Entry rules Pullback entry: Buy at open next bar if the DMI Oscillator is above 0 and the DMI Stochastic crosses above 10. Short at open next bar if the DMI Oscillator is below 0 and the DMI Stochastic crosses below 90. Countertrend entry: Short at open next bar if the DMI Oscillator crosses under -20. Buy at open next bar if the DMI Oscillator crosses above 20. Exit rules Fixed bars: exit at open next bar [...]

TASC 2015-12 | Trading The Loonie (Katsanos) — 0.6%

[...] StochD.Series(Bars,30,3); ChartPane oilPane = CreatePane(50,true,true); HideVolume(); PlotSymbol(oilPane,GetExternalSymbol("Light",true),Color.Green,Color.Red); ChartPane divPane = CreatePane(50,true,true); LineStyle ld = LineStyle.Dashed; PlotSeries(divPane,divergence,Color.Black,LineStyle.Solid,1); DrawHorzLine(divPane,20,Color.Black,ld,1); DrawHorzLine(divPane,-20,Color.Black,ld,1); for(int bar = GetTradingLoopStartBar(60); bar bar >85) || (llvDiv bar bar bar bar-1 && correlation60 [...]

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.