wow, thanks Mr. Popov !
late edit: oh, it is not for expert advisor studio. I red it very fast, too fast!
anyway, good things are coming in the future also for the eas, for sure!
wow, thanks Mr. Popov !
late edit: oh, it is not for expert advisor studio. I red it very fast, too fast!
anyway, good things are coming in the future also for the eas, for sure!
> It's super helpful for organizing strategies across different projects.
It is a good idea!
This can be better implemented with additional options.
Something like:
--input-dir /path/to/my/collections
--input-pattern [SERVER]-[SYMBOL]
--input-recursive true
I may think of it.
Please post a screenshot of how your MetaTrader chart looks like and the options you have enabled in the Expert's Input panel.
Most probably, everything is fine. The difference may come from the different options and protections you have enabled.
Side note!
I'll add a Risk calculation functionality to the "Top 10 Robots App".
It will be ready next week.
If it works fine, I may add such options to EA Studio.
It works as follows:
- The strategy needs Stop Loss (if not, we may assume 100 pips loss)
- Select Rsik percent (let's say 1% of the account)
- The program will calculate the proper Entry Lots depending on the Initial Account, the Stop Loss pips the spread and the commission.
Here is an example from the Prop Firm app (it also show the Stop Loss in dollars)
Você precisa ir na opções create positivo signal e signal e chamar um. Função com stop loss de 500000 pontos assim fica o mesmo que operar sem. Stop e super fácil
Why when I put my EA the indicators don't show up like you do? Do I have to make some changes in settings in MT4? Thanks
Hi again Mr. Popov,
another quick suggestion for the next EG release regarding collection file handling.
As I´ve mentioned a while ago, I've been patching collection.js to allow loading collections from any /collections subdirectory relative to the working directory. It's super helpful for organizing strategies across different projects. Here are the exact changes needed:
1. Add 'resolve' to the path imports:
const {join, parse, isAbsolute, resolve} = require("path");
2. Modify the loadCollection function to handle paths relative to the current working directory:
function loadCollection(inputPath, inputKeys, dataId, dataEndTime, suppressInputError) {
if (typeof inputPath === "string" && inputPath.length > 0) {
try {
let collectionPath = replacePlaceholders(inputPath, dataId, dataEndTime);
// If path is not absolute, prepend the collections directory
if (!isAbsolute(collectionPath) &&
(parse(collectionPath).dir === "" || !collectionPath.includes("collections"))) {
collectionPath = join(".", "collections", collectionPath);
}
// Resolve the path relative to the current working directory
collectionPath = resolve(process.cwd(), collectionPath);
// Check if the path exists and is a directory or file
if (existsSync(collectionPath)) {
const stat = statSync(collectionPath);
if (stat.isDirectory()) {
return readCollectionDir(collectionPath, inputKeys);
} else if (stat.isFile()) {
return readCollectionFile(collectionPath, inputKeys);
}
}
// If we reach here, try adding .json extension if missing
if (!collectionPath.toLowerCase().endsWith(".json")) {
collectionPath += ".json";
if (existsSync(collectionPath)) {
return readCollectionFile(collectionPath, inputKeys);
}
}
if (!suppressInputError) {
console.error(`${color.Red}Cannot open input file: ${color.Bright}${collectionPath}${color.Reset}`);
}
return [];
} catch (e) {
console.error(`${color.Red}${color.Bright}${e.message}${color.Reset}`);
return [];
}
} else if (Array.isArray(inputPath) && inputPath.length > 0) {
return inputPath.flatMap(file =>
loadCollection(file, inputKeys, dataId, dataEndTime, suppressInputError)
);
}
return [];
}
This replaces the current path resolution logic in loadCollection and makes it much more flexible. The changes maintain backward compatibility while allowing users to organize their collections in subdirectories.
Would you consider adding this to the next release? Would save me from patching after each update :-)
Thanks as always!
damn NOBODY AN IDEA?
I try 1000 times. i need the Stoploss of an signal but i dont know how to fetch it.
it must be something with this in OPENpOsition
double stopLoss = GetStopLossPrice(command, signal.StopLossPips);
i think it fetches the stoploss but i dont know how to implement
Hi Mr. Popov,
thanks for the updates, much appreciated.
However, it seems you already dropped support for the old format convention where the entry and exit indicators have not been separated? Using an old .ini file that uses the old formatting:
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; Indicators used by the Generator ;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
ind_accelerator_oscillator = true
ind_accumulation_distribution = false
ind_adx = true
ind_alligator = true
ind_average_true_range = true
ind_awesome_oscillator = false
ind_bears_power = true
ind_bollinger_bands = true
ind_bulls_power = true
ind_candle_color = false
ind_commodity_channel_index = true
ind_demarker = true
ind_directional_indicators = true
ind_do_not_exit = true
ind_donchian_channel = true
ind_entry_time = false
ind_envelopes = true
ind_exit_time = false
ind_force_index = false
ind_long_or_short = false
ind_macd = true
ind_macd_signal = true
ind_momentum = true
ind_money_flow_index = false
ind_moving_average = true
ind_moving_average_of_oscillator = true
ind_moving_averages_crossover = true
ind_on_balance_volume = false
ind_pin_bar = false
ind_rsi = true
ind_rvi = true
ind_rvi_signal = true
ind_standard_deviation = true
ind_stochastic = true
ind_stochastic_signal = true
ind_volumes = false
ind_williams_percent_range = true
Results in:
Unknown parameters found in C:\PortablePrograms\ExpressGenerator2\generate-all-pairs-H1-random.ini: indAcceleratorOscillator, indAccumulationDistribution, indAdx, indAlligator, indAverageTrueRange, indAwesomeOscillator, indBearsPower, indBollingerBands, indBullsPower, indCandleColor, indCommodityChannelIndex, indDemarker, indDirectionalIndicators, indDoNotExit, indDonchianChannel, indEntryTime, indEnvelopes, indExitTime, indForceIndex, indLongOrShort, indMacd, indMacdSignal, indMomentum, indMoneyFlowIndex, indMovingAverage, indMovingAverageOfOscillator, indMovingAveragesCrossover, indOnBalanceVolume, indPinBar, indRsi, indRvi, indRviSignal, indStandardDeviation, indStochastic, indStochasticSignal, indVolumes, indWilliamsPercentRange
In your last reply you said:
"You may update your settings at some time because I may deprecate the old options (in 1-2 years, of course)"
So the support for the old format has already been removed now or is this a bug?
Thank you.