TRADINGVIEW BACKTEST SCRIPT by Lionshare (c) 2015
THS IS A REAL ALTERNATIVE FOR LONG AWAITED TV NATIVE BACKTEST ENGINE.
READY FOR USE JUST RIGHT NOW.
For user provided trading strategy, executes the trades on pricedata history and continues to make it over live datafeed.
Calculates and (plots on premise) the next performance statistics:
profit - i.e. gross...
Standard Error Bands - Code by @XeL_arjona
Original implementation by:
Traders issue: Stocks & Commodities V. 14:9 (375-379):
Standard Error Bands by Jon Andersen
For a quick and publicly open explanation of this Statistical indicator, you can refer at Here!
Extract from the former URL:
Standard Error bands are...
A histogram is a special chart that is applied to statistical data that is divided into numerically ordered groups. For example groups with close relationships in the vicinity like "Close-ref(Close ,1)", "Close-ref(Close,2)" and so on. A histogram provides a snapshot of all the data so that you can quickly get an overview of the historical...
Multiple Statistics from zigzag:
• Price range between swings.
• Bar range between swings.
returns maximum value, avg value and mean deviation.
if you find something missing, please leave a message bellow.
This script holds several useful functions from statistics and machine learning (ML) and takes measurement of a volume weighted distance in order to identify local trends. It attempts at applying ML techniques to time series processing, shows how different distance measures behave and gives you an arsenal of tools for your endeavors. Tested with BTCUSD.
This is a very simple script... it does not necessarily create signals. It only provides useful feedback via statistics & probability.
There will be a green background if there are two green bars in a row, and it will stay green until two red bars show up (in which it switches color to red until two green bars show up again).
The fuchsia arrows show the double...
This script was written to calculate the correlation coefficient (Adjusted R-Squared) for one dependent and two independent variables.(3-way)
Pearson correlation method was used with exponential moving averages as the correlation calculation method.
Use your source ( i use "close" generally ) as the dependent variable.
Inspired by this article :...
// The script is useful to inspect probability:
// If previous day closed at lowest price for several days
// how often next day would be red bar
// As one can see gray lines indicate bars with lowest close. If next bar is green, increment diff_hi, overwise increment diff_lo
// Probability is counted as diff_lo / (diff_hi+diff_lo)
// One can copy script and...
This script shows the average count of 'up bars' vs. 'down bars'. It is intended for statistic and probability purposes only. It does not include high or low price in the calculation - only the open and close prices are used.
Under settings, click "show difference" to see the difference between the two averages. This can also be called positive/negative drift....
Lets say you want to layer into a position and you'd like to see it turn around. The study lets you set a baseline and increments above and below that baseline. A green cross is plotted ever time the price crosses above one of the increments, and red when crossing below that increment.
In the example I set the baseline to $22.1, and Layer increments to $0.50....