My approach. The core is the engine. - page 89

 
Реter Konow:

Demonstrate a working example.

So you can use union to translate ALL types (including string) to uint .

Otherwise, it's just empty words.

Riding on someone else's knowledge? And then puff out your cheeks saying that you did it all yourself?

Can't you study and do it yourself?

Everything has been chewed up, given to you, shown to you.

What I have highlighted looks like - as Nikolay really said - a kindergarten: "I don't think so..., and my dad will beat up your dad, and my mum will beat up your mum...".

 
Реter Konow:

So show me your example. How to bypass conversion to string by turning lots of data of different types into uint via union to store in a resource?

So what's the use of showing you, if for you it will be "just words", "complication of architecture" and "speed will be about the same". You have made up your mind beforehand. You don't want to learn anything new, but you have a big aplomb.

 
Artyom Trishkin:


This is an argument.

I offered a solution. Everyone has lambasted it, but hasn't shown theirs. Like, "go see the fxsaber code, go read the help...".

Aww. Guys.)))

 
Реter Konow:

This is an argument.

I offered a solution. Everyone has lambasted it, but hasn't shown theirs. Like, "go see the fxsaber code, go read the help...".

Aww. Guys.)))

This is not an argument. It's a dissection of your intuitive decision.

I'm not arguing, you can plant a tree in an upside-down pot, devise a system for watering it, a system for storing rainwater and sprinkling it into the upside-down pot, a system for holding the earth in that upside-down pot, a system for lighting from the bottom up, and claim that this intuitive solution is the most correct and most effective, and when people tell you to look out the window, and do not compostiruyut brain - there - outside the window - there are living examples of how better, you, smoking a pipe on satin pillows, broadcast something from the area of "lift my eyelids - can not see, show me, and all this empty words" ... Sorry, looks funny.

I'm gonna go get some popcorn.

 

The main question remains unanswered:

How can a set of data of different types, bypassing conversion to string, be converted to uint via union, to be stored in a resource?


Dear Opponents. You have lambasted my solution by referring specifically to the use of UNION to translate ALL data into UINT.


NO EXAMPLE WAS PROVIDED. SO FAR EVERYTHING IS GROUNDLESS.


Consequently, one conclusion remains for now:My solution was lambasted, according to the biases inherent in programmers.

If the solution is demonstrated, then it is undoubtedly better. I acknowledge this immediately.

 
Реter Konow:

This is an argument.

I offered a solution. Everyone has lambasted it, but hasn't shown theirs. Like, "go see the fxsaber code, go read the help...".

Aww. Guys.)))

Peter, I've told you many times - the problem with your approach is the extreme narrowness of your target audience. You have not even a "niche" product, but just a "slot" - people who are quite good at programming, but prefer to trade "hands".

Look at you - you are opposed mostly by coders, for whom your approach is even quite understandable, but very inconvenient. That's why they want to see "real achievements", "real product" - they won't use your approach, but they are interested in it as an option, so they want to evaluate "whether your approach is worth the cost", whether the inconvenience of your approach is worth the profit it can potentially give.

And you need others - the real traders, who trade with their hands. At the same time, they are quite good at programming. They are able to write a simple Expert Advisor, but find it difficult to understand how to work with graphical objects. And so far I do not see them. That's why your developments are not a success, but they are constantly criticized. Not the right audience!

You said something like "we need to educate them" - but then you surely need to demonstrate your achievements in trading - at least a demo account with a constant growth of Equity, which is obtained through this very "manual" trading using visual objects from your library.
 

Various parameters are changed on the EA side. Their values must be passed to the engine.

Parameters of ALL types. And string too. The values to be passed are of integer arrays.

  1. Or convert all to string and write in object descriptions.
  2. Or convert all of them to string, split them and pass them by parts using OnChartEvent().
  3. Or convert everything to string and convert to char and store in the resource.
  4. Or convert everything to uint through a union and store in the resource.

Question:

  1. Which of these works fastest?
  2. Which of these doesn't work at all?

ZS. I suspect that point 4 doesn't work at all.

 
Georgiy Merts:

Peter, I've told you more than once - the problem with your approach is the extreme narrowness of your target audience. You do not even have a "niche" product, but just a "slotted" one - people who know programming well, but prefer to sell "hands on".

Look at you - you are opposed mostly by coders, for whom your approach is even quite understandable, but very inconvenient. That's why they want to see "real achievements", "real product" - they won't use your approach, but they are interested in it as an option, so they want to evaluate "whether your approach is worth the trouble", whether the profit that it can potentially give is worth the inconvenience.

And you need others - the real traders, who trade with their hands. At the same time, they are quite good at programming. Who are able to write a simple Expert Advisor, but who have difficulties in working with graphical objects. And so far I do not see them. That's why your developments are not a success, but they are constantly criticized. Not the right audience!

There is an audience. Only on other sites. I've seen one site, or rather one of my customers told me about it, where they were raving with delight about the code of one of my experts, which I wrote for a customer, and the customer (not the one who gave me the address for this discussion) posted it there with a request to add the new features for free. People were shocked by the standard approaches. There - among that school audience - Peter can scratch his ego - he will be a god there.

 
Реter Konow:

How do I bypass string conversion to uint via union to store in a resource?

Forum on trading, automated trading systems and trading strategy testing

Libraries: TradeTransactions

fxsaber, 2018.12.17 23:48

You can trade anything through Resources.

// Пример обмена любыми данными (включая строковые массивы).

#include <fxsaber\TradeTransactions\ResourceData.mqh> // https://www.mql5.com/ru/code/22166

#define  PRINT(A) Print(#A + " = " + (string)(A));

void OnStart()
{    
  // Произвольные данные для примера
  string Str[] = {"123", "Hello World!"};
  double Num = 5;
  MqlTick Tick = {0};
  Tick.bid = 1.23456;

  const RESOURCEDATA<uint> Resource; // Ресурс для обмена данными
  CONTAINER<uint> Container;         // Создаем контейнер - все будет храниться в массиве простого типа (в примере выбран uint)
  
  // Заполняем контейнер разными данными
  Container[0] = Str;
  Container[1] = Num;
  Container[2] = Tick;
    
  // Распечатаем типы хранимых в контейнере данных
  for (int i = 0; i < Container.GetAmount(); i++)
    PRINT(Container[i].GetType())

  Resource = Container.Data;  // Отправили данные на обмен
  
  CONTAINER<uint> Container2; // Сюда будем получать данные
  
  Resource.Get(Container2.Data); // Получили данные
      
  // Получим данные в исходном виде
  string Str2[];
  Container[0].Get(Str2);                // Получили массив
  ArrayPrint(Str2);

  PRINT(Container[1].Get<double>())      // Получили число
  PRINT(Container[2].Get<MqlTick>().bid) // Получили структуру  
}
 
Реter Konow:

Various parameters are changed on the EA side. Their values must be passed to the engine.

Parameters of ALL types. And string too. The values to be passed are of integer arrays.

  1. Or convert all to string and write in object descriptions.
  2. Or convert all of them to string, split them and pass them by parts using OnChartEvent().
  3. Or convert everything to string and convert to char and store in the resource.
  4. Or convert everything to uint through a union and store in the resource.

Question:

  1. Which of these works fastest?
  2. Which of these doesn't work at all?

SZY. I suspect that point 4 doesn't work at all.

The only and only GlobalVariables and files for data exchange between EAs, indicators and scripts are

All 4 points above are local "hacks" from fishing. All 4 points above are using mechanisms not intended to exchange arbitrary data, much less arrays of data.

п1. 100% leads to temporary locking of interface thread (yep, objects live there and their "descriptions" too) and doesn't work in optimizer. The object descriptions are for human-readable description of objects,

p2. n2. does not work in tester and optimizer, and serves to notify of events

P3. p4. resources (even named) are intended for long-term storage, not for quick exchange. I can't say anything about usability in tester/optimizer :-) I use read-only resources

It doesn't make sense to talk about the speed of crooked solutions.

ps/ by the way, you can use files, more precisely pipes

Reason: