This script is meant to help verify the existence of a seasonal effect in asset returns, using a Z-test. There are three steps:
1. Think of a way to identify a season. The available methods are: by month, by week of the year, by day of the month, by day of the week, by hour of the day, and by minute of the hour.
2. Set the chart to the unit of your season. For...
A probability cone is an indicator that forecasts a statistical distribution from a set point in time into the future.
Forecast a Standard or Laplace distribution.
Change the how many bars the cones will lookback and sample in their calculations.
Set how many bars to forecast the cones.
Let the cones follow price from a set number of bars back.
Based on historical data (rather than theory), calculates the probability of a price level being "touched" within a given time frame. A "touch" means that price exceeded that level at some point. The parameters are:
- level: the "level" to be touched. it can be a number of points, percentage points, or standard deviations away from the mark price. a positive...
Methods for probability distribution sampling selection.
sample(probabilities) Computes a random selected index from a probability distribution.
probabilities : float array, probabilities of sample.
Methods to implement Markov Chain Monte Carlo Simulation (MCMC)
markov_chain(weights, actions, target_path, position, last_value) a basic implementation of the markov chain algorithm
weights : float array, weights of the Markov Chain.
actions : float array, actions of the Markov Chain.
target_path : float...
erf(value) Complementary error function
value : float, value to test.
ierf_mcgiles(value) Computes the inverse error function using the Mc Giles method, sacrifices accuracy for speed.
value : float, -1.0 >= _value >= 1.0 range, value to test.
Probability Distribution Histogram
During data exploration it is often useful to plot the distribution of the data one is exploring. This indicator plots the distribution of data between different bins.
Essentially, what we do is we look at the min and max of the entire data set to determine its range. When we have the range of the data, we decide how many...
The script is inspired by user NickbarComb, I suggested checking out his Price Convergence script.
Basically, this script plots a table containing the probability of the current candle closing either higher or lower based on user-define past period.
Hope that it will be helpful.
function to calculate Chebyshev Inequality. wich can be used to compute the probability that we will diverge from what we expect to obtain.
The Omega Ratio is a risk-return performance measure of an investment asset, portfolio, or strategy. It is defined as the probability-weighted ratio, of gains versus losses for some threshold return target . The ratio is an alternative for the widely used Sharpe ratio and is based on information the Sharpe ratio discards.
As we have mentioned...
First of all the biggest thanks to @tista and @KivancOzbilgic for publishing their open source public indicators Bayesian BBSMA + nQQE Oscillator. And a mighty round of applause for @MarkBench for once again being my superhero pinescript guy that puts these awesome combination Ideas and ES stradegies in my head together. Now let me go ahead and explain what we...
Pattern Recognition Probabilities (PRP) is a REALLY smart indicator. It uses the correlation coefficient formula to determine if the current set of bars resembles that of past patterns. It counts the number of times the current pattern has occurred in the past and looks at how it performed historically to determine the probability of an up move, down move,...