pc a synthetics - recycle legacy
Info
The pc a synthetics - recycle legacy is a Indicator for MetaTrader 5 that indicator for automatic selection of the coefficients for every instrument in a pseudo-stationary portfolio, which tends to equilibrium at zero. the indicator requires the presence of the alglib library in the include\math folder of the terminal.
Usage
This tool is typically used for enhancing chart analysis and decision making.
Platform
This Indicator works exclusively on MetaTrader 5 (both build 600+ and newer versions).
Setup
Place the downloaded file in MQL5/Indicators folder via File ? Open Data Folder in MetaTrader 5.
How to Install and Use pc a synthetics - recycle legacy
1. Installation: Place your file in the MQL/Indicators folder via "Open Data Folder" and restart your terminal.
2. Loading: Find the indicator in the Navigator, drag it onto your chart, and configure the input parameters in the popup window.
3. Customization: Press Ctrl+I to open the indicator list, select your tool, and click "Properties" to change colors, levels, or visual styles.
4. Updating: Replace the old file in the Indicators folder with the new version and restart the platform to apply changes.
Frequently Asked Questions
Q: Why is my indicator not showing? A: Verify the file is in the MQL/Indicators folder, or try right-clicking the "Indicators" tree in the Navigator and clicking "Refresh."
Q: Do custom indicators slow down the platform? A: Too many complex indicators can impact performance; remove unused ones via the "Indicator List" (Ctrl+I).
Q: Can I use MT4 indicators on MT5? A: No, MQL4 and MQL5 are distinct languages; ensure the indicator is compiled specifically for your platform version.
What this tool does
indicator for automatic selection of the coefficients for every instrument in a pseudo-stationary portfolio, which tends to equilibrium at zero.
Typical Use Case
This Indicator excels in automated trading and technical analysis on MetaTrader 5.
Compatible Platform & Setup
This Indicator works on MetaTrader 5. Place the file in the MQL5/Indicators folder and restart the terminal.
Description & Settings
Related: color bears candle - another powerful indicator for MetaTrader 5 traders.
indicator for automatic selection of the coefficients for every instrument in a pseudo-stationary portfolio, which tends to equilibrium at zero.
Also recommended: jfatl candle ht f - similar indicator with strong performance on MetaTrader 5.
the indicator requires the presence of the alglib library in the include\math folder of the terminal.a bit of theory
every instrument moves in its own direction, every direction is a separate dimension in a multidimensional array. bu turning the matrix, that is, by multiplying its every element by a certain number, we try to find an axis, with the minimum distance the axis and all instruments, i.e. the least total variance. the number to multiply each element of the matrix then becomes the angle value, by which the moving instrument should be turned so that it moves in the same direction as other instruments. this angle value is the coefficient for every currency in the portfolio.
if the coefficient value is greater than 0 the currency is bought, if less than 0 — sold. thus, it is possible to sustain the stationarity of the created synthetic by recalculating the coefficients from time to time. in addition, the pca does not simply find the axis with the least variance for the portfolio, but several. the number of instruments in the portfolio is the number of components (vectors). each of them is called the main component, and determines how much it affects the total change of the portfolio movement.
possible problems
if the chart is not drawn, see what is printed in the experts tab. perhaps, there are some errors or synchronizations with other charts is in progress. if there are no messages, click through other timeframes.
the obtained vector values were verified with the once calculated in the r package, so the values themselves are correct. but the sign of a specific coefficient may be wrong, as the РСА does not pay attention to signs. the "-" or "+" sign can only be determined empirically, that is by trial and error.
problem #2 with has been describes with the pictures here:
parameters inpvector = 0; // if there are n currencies in portfolio, the movement axis number 0 = maximum variance, n - 1 = minimuminpframe = 300; // floating window for calculation of coefficients, for each of inpdepth bars make inpframe computationsinpdepth = 1000; // the total number of bars in history, for which the chart is drawninpforward = 500; // the bar to stop recalculating the coefficients and use the previous ones, this is oosinpperiod = 1; // smoothing for the МА, to make the chart look less twitchedinptimeperiod = period_current; // timeframe for the calculationsinpnormalize = true; // normalize the prices before displaying them, to smooth the volatility gaps of usdjpy and eurgbpinpsynthetics = true; // draw the summary synthetic multiplied by the found coefficients or each pair individuallyinpprices = logs; // normalization algorithm of pairsinpsymbols = "audusd,usdchf,usdcad"; // pairs for the portfolioinpmagic = "id" // custom name of the indicator, to facilitate placing multiple instances on one chart without conflicts
the idea was adopted from here:
You may also like: doulble ma cross draw histogram - excellent alternative for indicator users on MetaTrader 5.
Source Code
#property indicator_separate_window
#property indicator_buffers 10
#property indicator_plots 10
#property indicator_type1 draw_line
#property indicator_color1 clrblue
#property indicator_type2 draw_line
#property indicator_color2 clrblack
#property indicator_type3 draw_line
#property indicator_color3 clrred
#property indicator_type4 draw_line
.......
⚠ Limitations & Risk Warning
- This tool is provided for educational and testing purposes only.
- Past performance does not guarantee future results.
- Trading involves substantial risk of loss. Use on a demo account first.
- Results may vary depending on market conditions, broker, and settings.
- We recommend thorough backtesting and forward testing before using with real funds.