Forex Factory (
-   Trading Systems (
-   -   v2v dynamic trading system (

v2vboni Aug 5, 2019 9:46am | Post# 161

My posts here makes no guarantees as to the accuracy or completeness of the views expressed, including timeliness, and the suitability of shared information herein. Such as the images or charts, and indicators.

All post might be subject to modification or deletion ─ based on my own prerogative and more importantly... based on FF's rules/restrictions as this may become unreliable for various reasons, including changes in the market conditions or economic circumstances.

In addition, please be reminded that there is always the potential for loss. Your trading results may vary. Unique experiences and past performances do not guarantee future results. Hence, it is highly recommended to seek a duly licensed professional for investment advice whether any given investment idea or strategy described herein may be appropriate for your circumstances. All investments involve risk, including loss of principal.

v2vboni Aug 5, 2019 9:58am | Post# 162

2 Attachment(s)
Last Friday... Trade Weighted Fx Index
Click to Enlarge

Size: 281 KB
The charts summarize the relative position of an exchange rate relative to its performance over the last year. The yellow background indicates the square dimension of the chart. The orange dot indicates today's position relative to the high (top of the chart) and low (bottom of the chart) of the FX index during the last 365 days. So if the orange dot is close to the top, the currency is close to its highest valuation. If the orange dot is close to the bottom, the currency is near its lowest valuation. The blue bars indicate the distribution of valuations over the course of one year. The span between high and low valuation is divided into ten ranges (ie, deciles). Then the number of days during which the currency's valuation has been in each of these deciles is counted. The number of days is proportional to the width of each of the ten blue bars. Thus the position of the orange dot relative to the width of the blue bars indicates if the current valuation is a relatively common event or a relatively rare event. For example, if the bulk of valuations has been in the lower deciles, and the orange dot is near the top where the bars are narrow, the currency has recently moved up sharply. These charts ("FX conifers") are a simple method of visually summarizing the performance of a currency over the time period of one year. One useful feature of this chart is that it automatically adjusts for the different volatility of currencies, as the span between one-year high and one-year low is a reflection of a currency's volatility.
Name:  twi_1.jpg
Views: 968
Size:  123 KB
A trade-weighted currency index is a weighted average of a basket of currencies that reflects the importance of a country's trade (imports and exports) with these countries. Sometimes a trade-weighted currency index is taken as a crude measure of a country's international "competitiveness". At any rate, a trade-weighted currency index is a useful measure to aggregate diverging trends among currencies of a country's trading partners. For example, Canada is trading mostly with the United States. Thus the USD/CAD exchange rate has a weight of about 80% in Canada's trade-weighted CAD index.

v2vboni Aug 5, 2019 10:36am | Post# 163

1 Attachment(s)
Click to Enlarge

Name: EUR_today.jpg
Size: 456 KB

v2vboni Aug 6, 2019 2:36am | Post# 164

3 Attachment(s)
...More about JMA

Why does JMA have a PHASE parameter?

There are two ways to decrease noise in a time series using JMA. Increasing the LENGTH parameter will make JMA move slower and thereby reduce noise at the expense of added lag.

Alternatively, you can change the amount of "inertia" contained within JMA. Inertia is like physical mass, the more you have, the more difficult it is to turn direction. So a filter with lots of inertia will require more time to reverse direction and thereby reduce noise at the expense of overshooting during reversals in the time series.
All strong noise filters have lag and overshoot, and JMA is no exception. However, the JMA's adjustable parameters PHASE and LENGTH offer you a way to select the optimal tradeoff between lag and overshoot. This gives you the opportunity to fine-tune various technical indicators.
Name:  jma1.gif
Views: 915
Size:  7 KB
For example, the chart (above shows a fast JMA line crossing over a slower JMA line. To make the fast JMA line turn "on a dime" whenever the market reverses, it was set to have no inertia. In contrast, the slow JMA was set to have large inertia, thereby slowing down its ability to turn during market reversals. This arrangement causes the faster line to cross over the slower line as quickly as possible, thereby producing low lag crossover signals. Clearly, user control of a filter's inertia offers considerable power over filters lacking this capability.

Does JMA forecast a time-series?

It does not forecast into the future. JMA reduces noise pretty much the same way as an exponential moving average, but many times better.

Will prior JMA values, already plotted, change as new data arrives?

No. For any point on a JMA plot, only historical and current data is used in the formula. Consequently, as new price data arrive on later time slots, those values of JMA already plotted are not affected and NEVER change.

Also, consider the case when the most recent bar on a chart is updated in real-time as each new tick arrives. Since the closing price of the most recent bar is likely to change, JMA is automatically re-evaluated to reflect the new closing price. However, historical values of JMA (on all prior bars) remain unaffected and do not change.
One can create impressive-looking indicators on historical data when it analyzes both past and future values surrounding each data point being processed. However, any formula that needs to see future values in a time series cannot be applied in real-world trading. This is because when calculating today's value of an indicator, future values don't exist. All Jurik based indicators use only current and previous time-series data in its calculations. This allows all Jurik indicators to work in all real-time conditions.

How does JMA compare to other filters?

The Kalman filter is similar to JMA in that both are powerful algorithms used for estimating the behavior of a noisy dynamical system when all you have to work with is noisy data measurements. The Kalman filter creates smooth forecasts of the time series, and this method is not entirely appropriate for financial time series as the markets are prone to produce violent gyrations and price gaps, behaviors not typical of smoothly operating dynamical systems. Consequently, Kalman filter smoothing frequently lags behind or overshoots market price time series. In contrast, JMA tracks market prices closely and smoothly, adapting to gaps while avoiding unwanted overshoots. See chart below for an example.
Click to Enlarge

Name: jma2.gif
Size: 9 KB
Two other popular indicators are T3 and TEMA. They are smooth and have little lag. T3 is the better of the two. Nonetheless, T3 can exhibit a serious overshoot problem, as seen in the chart below. Depending on your application, you may not want an indicator showing a price level the real market never attained, as this may inadvertently initiate unwanted trades.
Name:  jma3.gif
Views: 918
Size:  57 KB

v2vboni Aug 6, 2019 3:01am | Post# 165

1 Attachment(s)
v2v dynamic trading system... minor update

  1. TDZ-MTF: default parameter values and label settings
  2. Standard parameter option for JMA

Click to Enlarge

Name: the_tdz.jpg
Size: 408 KB
Get it here >>> Post #1

v2vboni Aug 7, 2019 12:48pm | Post# 166

1 Attachment(s)
UPDATED ...v2v dynamic trading system

  1. Neural Network ─ HMA-DSMA-Jurik: Now using T3 by T.Tillson as the default MA. This is considered to be the best MA algorithm out there
  2. Traders Dynamic Zones: Now using T3 by T.Tillson as the default MA for price line... while TEMA (arguably second to T3 MA) is the default MA for signal line
  3. Volume Profile - Range: code optimization
  4. v2v VWAP: conde optimization
  5. News Events: added "Payrolls" event under "Employment"
  6. New template to reflect the modifications made all throughout the v2v dynamic trading system

Click to Enlarge

Name: TDZ updates.jpg
Size: 488 KB
Get it here >>> Post #1


Better Moving Averages Tim Tillson November 1, 1998

Tim Tillson is a software project manager at Hewlett-Packard, with degrees in Mathematics and Computer Science. He has privately traded options and equities for 15 years.


"Digital filtering includes the process of smoothing, predicting, differentiating, integrating, separation of signals, and removal of noise from a signal. Thus many people who do such things are actually using digital filters without realizing that they are; being unacquainted with the theory, they neither understand what they have done nor the possibilities of what they might have done."

This quote from R. W. Hamming applies to the vast majority of indicators in technical analysis. Moving averages, be they simple, weighted, or exponential, are lowpass filters; low-frequency components in the signal pass through with little attenuation, while high frequencies are severely reduced. "Oscillator" type indicators (such as MACD, Momentum, Relative Strength Index) are another type of digital filter called a differentiator. Tushar Chande has observed that many popular oscillators are highly correlated, which is sensible because they are trying to measure the rate of change of the underlying time series, i.e., are trying to be the first and second derivatives we all learned about in Calculus.
We use moving averages (lowpass filters) in technical analysis to remove the random noise from a time series, to discern the underlying trend or to determine prices at which we will take action. A perfect moving average would have two attributes:

It would be smooth, not sensitive to random noise in the underlying time series. Another way of saying this is that its derivative would not spuriously alternate between positive and negative values.

It would not lag behind the time series it is computed from. Lag, of course, produces late buy or sell signals that kill profits.

The only way one can compute a perfect moving average is to have knowledge of the future, and if we had that, we would buy one lottery ticket a week rather than trade!

(See Appendix II below for more elaboration). Having said this, we can still improve on the conventional simple, weighted, or exponential moving averages. Here's how:

Two Interesting Moving Averages

We will examine two benchmark moving averages based on Linear Regression analysis.

In both cases, a Linear Regression line of length n is fitted to price data.

I call the first moving average ILRS, which stands for Integral of Linear Regression Slope. One simply integrates the slope of a linear regression line as it is successively fitted in a moving window of length n across the data, with the constant of integration being a simple moving average of the first n points. Put another way, the derivative of ILRS is the linear regression slope. Note that ILRS is not the same as a SMA (simple moving average) of length n, which is actually the midpoint of the linear regression line as it moves across the data.

We can measure the lag of moving averages with respect to a linear trend by computing how they behave when the input is a line with unit slope. Both SMA(n) and ILRS(n) have lag of n/2, but ILRS is much smoother than SMA.

Our second benchmark moving average is well known, called EPMA or End Point Moving Average. It is the endpoint of the linear regression line of length n as it is fitted across the data. EPMA hugs the data more closely than a simple or exponential moving average of the same length. The price we pay for this is that it is much noisier (less smooth) than ILRS, and it also has the annoying property that it overshoots the data when linear trends are present.

However, EPMA has a lag of 0 with respect to linear input! This makes sense because a linear regression line will fit linear input perfectly, and the endpoint of the LR line will be on the input line.

These two moving averages frame the tradeoffs that we are facing. On one extreme we have ILRS, which is very smooth and has considerable phase lag. EPMA has 0 phase lag, but is too noisy and overshoots. We would like to construct a better moving average which is as smooth as ILRS, but runs closer to where EPMA lies, without the overshoot.

A easy way to attempt this is to split the difference, i.e. use (ILRS(n)+EPMA(n))/2. This will give us a moving average (call it IE/2) which runs in between the two, has phase lag of n/4 but still inherits considerable noise from EPMA. IE/2 is inspirational, however. Can we build something that is comparable, but smoother? Figure 1 shows ILRS, EPMA, and IE/2.

Filter Techniques

Any thoughtful student of filter theory (or resolute experimenter) will have noticed that you can improve the smoothness of a filter by running it through itself multiple times, at the cost of increasing phase lag.

There is a complementary technique (called twicing by J.W. Tukey) which can be used to improve phase lag. If L stands for the operation of running data through a low pass filter, then twicing can be described by:

L' = L(time series) + L(time series - L(time series))

That is, we add a moving average of the difference between the input and the moving average to the moving average. This is algebraically equivalent to:


This is the Double Exponential Moving Average or DEMA, popularized by Patrick Mulloy in TASAC (January/February 1994). In our taxonomy, DEMA has some phase lag (although it exponentially approaches 0) and is somewhat noisy, comparable to IE/2.
We will use these two techniques to construct our better moving average, after we explore the first one a little more closely.

Fixing Overshoot

An n-day EMA has smoothing constant alpha=2/(n+1) and a lag of (n-1)/2.

Thus EMA(3) has lag 1, and EMA(11) has lag 5. Figure 2 shows that, if I am willing to incur 5 days of lag, I get a smoother moving average if I run EMA(3) through itself 5 times than if I just take EMA(11) once.

This suggests that if EPMA and DEMA have 0 or low lag, why not run fast versions (eg DEMA(3)) through themselves many times to achieve a smooth result? The problem is that multiple runs though these filters increase their tendency to overshoot the data, giving an unusable result. This is because the amplitude response of DEMA and EPMA is greater than 1 at certain frequencies, giving a gain of much greater than 1 at these frequencies when running though themselves multiple times. Figure 3 shows DEMA(7) and EPMA(7) run through themselves 3 times. DEMA^3 has serious overshoot, and EPMA^3 is terrible.

The solution to the overshoot problem is to recall what we are doing with twicing:

DEMA(n) = EMA(n) + EMA(time series - EMA(n))

The second term is adding, in effect, a smooth version of the derivative to the EMA to achieve DEMA. The derivative term determines how hot the moving average's response to linear trends will be. We need to simply turn down the volume to achieve our basic building block:

EMA(n) + EMA(time series - EMA(n))*.7;

This is algebraically the same as:


I have chosen .7 as my volume factor, but the general formula (which I call "Generalized Dema") is:

GD(n,v) = EMA(n)*(1+v)-EMA(EMA(n))*v,

where v ranges between 0 and 1. When v=0, GD is just an EMA, and when v=1, GD is DEMA. In between, GD is a cooler DEMA. By using a value for v less than 1 (I like .7), we cure the multiple DEMA overshoot problem, at the cost of accepting some additional phase delay. Now we can run GD through itself multiple times to define a new, smoother moving average T3 that does not overshoot the data:

T3(n) = GD(GD(GD(n)))

In filter theory parlance, T3 is a six-pole non-linear Kalman filter. Kalman filters are ones which use the error (in this case (time series - EMA(n)) to correct themselves. In Technical Analysis, these are called Adaptive Moving Averages; they track the time series more aggressively when it is making large moves.

Trading Results

I used Metastock 6.5 to compare 5 moving averages (SMA, ILRS, EMA, DEMA, and T3) on the Nasdaq index (NDX) from 7/19/93 to 6/30/97, almost four years of data. I set the interest rate at 4% annualized, and a trading cost of .1% for entry and exit. This is realistic, since I can trade up to 1000 shares through Fidelity Web Express for $14.95, and a typical trade might be 300 shares of a $50 stock.
The system used was very simple. A moving average was computed using each of the five above. A derivative was taken (1-period Rate of Change function, ROC). A long position was entered at bottoms, and closed at tops, of the derivative. No shorts were taken. For example, the code for "enter long" for an EMA was:
res:=Mov(C,opt1,E); d1:=ROC(res,1,points); d1 > Ref(d1,-1) AND Ref(d1,-1) < Ref(d1,-2)
I let opt1 vary from 2 to 10. This is a fast system, which executes a lot of trades. The table below summarizes the best results each MA was able to achieve; note that the optimal parameters did not vary widely.

MA Optimal Parameter Best APR ILRS 7 19.02 SMA 8 20.20 EMA 8 28.17 DEMA 7 28.81 T3 5 (volume = .7) 33.59 No single set of backtesting results is conclusive, of course. But these numbers confirm that T3 has merit - it not only looks good to the eye on the chart, but can be a powerful building block in other indicators and trading systems.

Appendix I - Metastock Implementations

Metastock 6.5 code for ILRS:
{input number of lookback periods, default is 11} periods:=Input("Periods? ",2,63,11); {determine how many points are in the time series} size:=LastValue(Cum(1)); {determine the constant of integration by taking the simple moving average of the first periods points in the time series} start:=LastValue(Ref(Mov(P,periods,S),periods-size)); {value is the integral of linear regression slope plus the constant of integration} Cum(LinRegSlope(P,periods))+start;
Metastock 6.5 code for T3:

If x stands for the action of running a time series through an EMA, f is our formula for Generalized Dema with 'volume' a:
Running the filter though itself three times is equivalent to cubing f:

Thus the Metastock 6.5 code for T3 is:
periods:=Input("Periods? ",1,63,5); a:=Input("Hot? ",0,2,.7); e1:=Mov(P,periods,E); e2:=Mov(e1,periods,E); e3:=Mov(e2,periods,E); e4:=Mov(e3,periods,E); e5:=Mov(e4,periods,E); e6:=Mov(e5,periods,E); c1:=-a*a*a; c2:=3*a*a+3*a*a*a; c3:=-6*a*a-3*a-3*a*a*a; c4:=1+3*a+a*a*a+3*a*a; c1*e6+c2*e5+c3*e4+c4*e3;

v2vboni Aug 7, 2019 4:24pm | Post# 167

1 Attachment(s)
This TDZ has an eye... the Dollar Eye. However, only time will tell if this eye can really see some mo͞oläh. ; )─
Click to Enlarge

Name: thedollar_eye.jpg
Size: 477 KB

v2vboni Aug 7, 2019 11:56pm | Post# 168

1 Attachment(s)
UPDATED ...v2v dynamic trading system

  1. HA-APB: minor modification for high & low lines or the so-called PAC - Price Action Channel with average price.
  2. TDZ - minor modification of period filter for Price.

Click to Enlarge

Name: ha_apb_update.jpg
Size: 364 KB

v2vboni Aug 8, 2019 5:17pm | Post# 169

1 Attachment(s)
UPDATED ...v2v dynamic trading system


  1. HA-APB: PAC & Average Price line has been modifications:
  2. TDZ: just color schemes and minor code updates
  3. Volumes on Main Chart: just color schemes
  4. Neural Network: Some updates made
  5. Again, an updated template to reflect default values/label names or parameters.

Click to Enlarge

Name: the_tdz_one.jpg
Size: 528 KB

kette Aug 8, 2019 5:27pm | Post# 170

UPDATED ...v2v dynamic trading system HA-APB: PAC & Average Price line has been modifications: TDZ: just color schemes and minor code updates Volumes on Main Chart: just color schemes Neural Network: Some updates made {image}

I still use it

v2vboni Aug 8, 2019 5:34pm | Post# 171

1 Attachment(s)
A few modifications in color schemes: Volume vertical bars, Neural Network T3, Average Price (HA-APB), and TDZ
Click to Enlarge

Name: sample new look 2.jpg
Size: 468 KB

v2vboni Aug 9, 2019 12:25am | Post# 172

1 Attachment(s)
※ Heiken Ashi ─ Average Price Bars ( HA-APB ) with PAC

The difference between the original HA-APB Price Action Channel ( PAC ) and this variation of PAC (using JMA, DSMA, and HMA), is that the latter is using three touchpoints instead of just the two-line PAC. This one added the Average Price to see if APB closed above or below it.

☛ HA-APB based Price Action Channel ( PAC ) and
☛ Average Price Line (HA-APB Low + HA-APB High)/2
☛ Fused with MTF mode.
☛ Using T3 MA and with...
☛ Jurik Smoothing/Filter and Deviation-Scaled Moving Average (DSMA)
...some extras added: Access buttons for features & functions, and a symbol or pair and timeframe switch panel

Price Action Channel (PAC)
─ It provides an overall direction near the Price.
─ Reveals periods of consolidation.
─ Reveals periods of volatility.
─ It may Use as an Exit Target or
─ Use as a Trailing Stop Loss
Click to Enlarge

Size: 348 KB

v2vboni Aug 11, 2019 3:29am | Post# 173

1 Attachment(s)
v2v dynamic trading system updates... ※ Heiken Ashi ─ Average Price Bars ( HA-APB ) with PAC

  1. Removed Pairs & TF buttons
  2. Add MTF button switch
  3. Automatic Heiken Ashi Bar width update (on zoom in/out) under current TF without waiting for a tick data (before only in MTF mode).


  1. New template to adjust the vertical location of navigational buttons and default parameter values

    1. TDZ-MTF
    2. News Events
    3. Pivot Fibs plus
    4. Neural Network
    5. Volume Profile
    6. VWAP

Click to Enlarge

Name: newupdate.jpg
Size: 429 KB

kette Aug 12, 2019 8:03pm | Post# 174

HA-APB ... MTF mode {image}

v2vboni Aug 13, 2019 8:26am | Post# 175

1 Attachment(s)
v2v dynamic trading system updates...

※ Heiken Ashi ─ Average Price Bars ( HA-APB ) with PAC

  1. Key updates/more info:
    ─ Removed consolidation wicks color change to focus only on bullish & bearish wicks color change... and more importantly on this APB bars below. Besides, one can easily identify a consolidation or contraction phase using this tool. Hence, one sort of redundancy out of the equation.
    This is not a buy or sell signal... it just another data/information in confluence to your own speculative/sentimental well-informed bias.
    Name:  HA_bar.jpg
Views: 357
Size:  35 KB
    ─ HA Average Price line: Smoothed ( Both avg price line & PAC channels have combined filters used, such as DSMA, HMA non-lag variation, TEMA ),
    ─ added MTF switch button, and
    ─ HA bars automatic body width adjustment (zoom in/out) without waiting for a tick data

Get it here >>> Post#1

v2vboni Aug 13, 2019 11:34am | Post# 176

Earlier.... the volumes on main chart tool just reminded me how lucky I am that this tool is a part of my trading arsenal.

The very first version was made by Mladen... And then, after I attached this to my chart, I just imagined how I could add the volatility code & alerts and making it the heart of a system.

That's the time the v2v dynamic system was born.

v2vboni Aug 13, 2019 4:16pm | Post# 177

the Neural Network (NN)... minor update

  1. Fixed the option for rerunning of Neural Network (wrongly run twice) on Button switch behavior... now, a one-time rerun execution only.
  2. Again... this option is "false" by default. If "true", upon button switch trigger... And at runtime, an observable high CPU usage can be seen.
  3. Reminder: Ideally, you may use this only as another confluence with your own speculative/sentimental well-informed bias.

Get this NN at post#1

v2vboni Aug 13, 2019 8:06pm | Post# 178

1 Attachment(s)
...just in case only. In reference to post #1
Click to Enlarge

Name: warning.jpg
Size: 119 KB

v2vboni Aug 13, 2019 10:38pm | Post# 179

1 Attachment(s)
v2v dynamic trading system ...updates...

※ Volume Profile - Range with VWAP
※ anchored VWAP

  1. These tools are now using by default the tick Volume data source based on what the VP-Range tool (more on tick data quality) is currently using. Otherwise, it will use the default VWAP setup (classic VWAP)

Click to Enlarge

Name: the_dynamics.jpg
Size: 489 KB

v2vboni Aug 14, 2019 2:56am | Post# 180

...almost there guys/gals

Soon... constant update will end... The only foreseeable updates remain for v2v trading system are with the following tools

  1. Long & Short HMA-DSMA
  2. Traders Dynamic Zones
  3. Pivot Fibs plus

© Forex Factory