Discussion of article "Statistical Distributions in MQL5 - taking the best of R" - page 12

 
fxsaber:

It's been possible to draw anything interactively for years. Only nobody (publicly for sure) uses it.

The code is not short, but long and very crooked (as well as the result - flickers). The library should be seriously improved.

If you took plot from R as an analogue, it seems to be only static graphics. if there is interactive graphics, it is definitely not plot in a direct form. i searched for something like that there for the sake of interest, but there were references somewhere in the direction of joint work with java, etc.

like this

dashboardInteractive Data Visualisation with D3.js

if I understood correctly, and such

timevis:

Create rich and fully interactive timeline visualisations. Timelines can be included in Shiny apps and R markdown documents, or viewed from the R console and RStudio Viewer. 'timevis' includes an extensive API to manipulate a timeline after creation, and supports getting data out of the visualisation into R. Based on the'vis.js' Timeline module and the 'htmlwidgets' R package.

CRAN - Package dashboard
  • cran.r-project.org
Johann Laurent.
 
ivanivan_11:

If plot from R was taken as an analogue of plot, it seems to be only static graphics. if there is interactive graphics, it is definitely not plot in its direct form. i searched for something like that there for the sake of interest, but there were references somewhere in the direction of cooperation with java, etc.

Only GraphPlot-function (not method) refers to R. The classes themselves have nothing to do with R and should allow interactivity. They will.
 

It seems that one thing is missing: the cluster analysis.

(It seems that one thing is missing: the cluster analysis.)

 
На практике компилятор MQL5 языка оказался гораздо быстрее С++ реализаций функций в R
If you compile an implementation from R in C++, will its execution be slower than your implementation in MQL5?
 
fxsaber:
If you compile an implementation from R in C++, will its execution be slower than your implementation in MQL5?

Yes, due to the use of dynamic data as a minimum and the general frontal approach.

In fact, a lot of basic mat functions are compiled in the C/C++ compiler. It is enough to look at the source code.

 
Renat Fatkhullin:

Yes, due to the use of dynamic data as a minimum and a general head-on approach.

In fact, a lot of basic mat functions are compiled on C/C++ compiler. It is enough to look at the source code.

And where to see HOW you compare the speed?
 
Renat Fatkhullin:

Yes, due to the use of dynamic data as a minimum and a general head-on approach.

In fact, a lot of basic mat functions are compiled on C/C++ compiler. It is enough to look at the source code.

So does the implementation in MQL5 algorithmically differ for the better or the MQL5 compiler turned out to be faster than C++?
 
СанСаныч Фоменко:
Where can I see HOW you compare speeds?
Read the whole article.
 

GREAT ARTICLE!

Will be looking into it.

+

 
Renat Fatkhullin:
Read the article in full.

Read it.

Got into it.

I think that the tests you have given are not quite correct. I consider it necessary to write about it, because comparisons of performance are not the last.

The point is that MKL is qualitatively different from R. And in cases of performance comparisons these qualitative differences should be taken into account where possible. R is an interpreter and MKL is a compiler. This qualitative difference for industrial programmes goes in favour of MKL.

But there is another qualitative difference which is also of great importance in industrial exploitation of programmes and in tests these differences were not taken into account, which led to distorted results.

The qualitative difference between R and MKL is that the elementary object in MKL is a scalar, from which more complex objects, for example vectors, are made up. It is vectors that are fed to the input of distribution functions.

In R there is no concept of "scalar" at all. The simplest object is a vector. R widely exploits this circumstance and in our example of comparing distribution functions in R code we can clearly see such a programming technique, specific for R, as "vectorisation", which is not available in MKL. Since this is a specific technique in R that speeds up computations 10-100 times (depending on the size of the matrix), the code for R would have to contain this very technique. The use of vectorisation is obvious, because in tests we take an input vector and perform calculations over it 100 times, i.e. it is a matrix with the same or different columns.

To summarise: a text in R should be written in R using its capabilities, especially in the absence of their analogues in MKL.

PS.

Since we are talking about cycles, R is intended to load cores. But let's leave it behind brackets.