[Development] Forex Economic Calender
Hi,
While digging around the API and trying out stuff with PTMC, I started developing an "on-chart" FX Economic Calendar like seen on TradingView (I though it's a cool feature and wanted to have it in PTMC):
So, here is my actual one.Tell me what you think and what you want to see/add. I'm open for suggestions! Cheers!
Every event is shown:
Only Symbol events are shown:
Symbols can be shown at any offset of the y axis:
The plan is, that it looks and behaves like the one from TradingView.
The currently used Economic Calendar data is from http://www.forexfactory.com/calendar.php.
The API and functionality of PTMC is just awesome! Seems I'm sticking with C# again for a while :)
Hi BeardPower
What a nice job you are doing with ptmc API. Well done! I enjoy to see someone is involved in deeper understanding of PTMC ecosystem.
According to your potential indicator, if it is not yet of course implemented, definately it is good to have a window popup with additional info (base text, forecast, prev and actual value) on hover. Even though some of flags is overlapping on pointer position, just place scroll inside the popup window to see all news in descending order. See attached pic., as an example.
Also it is worth to adjust the size of the bitmap according to a news value (for example if it is nonfarm payroll get constant size and multiply it by hardcode proportion). This way users are able to distinguish important news and elaborate their daily strategy.
Also it is worth to filter news according to the instrument. For instance there is no point to add news about CNY (RMB) on USD/CAD chart. This way you would keep things simple and chart is not going to be overloaded. If you need any help in implementing these features, you are welcome to skype me, I can assist you with this anyhow.
Best Regards
What a nice job you are doing with ptmc API. Well done! I enjoy to see someone is involved in deeper understanding of PTMC ecosystem.
Thanks. I wished every Trading Platform developer was so open and engaged as you are!
According to your potential indicator, if it is not yet of course implemented, definately it is good to have a window popup with additional info (base text, forecast, prev and actual value) on hover. Even though some of flags is overlapping on pointer position, just place scroll inside the popup window to see all news in descending order. See attached pic., as an example.
Yeah, I already planned that.
Also it is worth to adjust the size of the bitmap according to a news value (for example if it is nonfarm payroll get constant size and multiply it by hardcode proportion). This way users are able to distinguish important news and elaborate their daily strategy.
Like this? Done. :)
Also it is worth to filter news according to the instrument. For instance there is no point to add news about CNY (RMB) on USD/CAD chart. This way you would keep things simple and chart is not going to be overloaded.
That's already possible. It's better to have a feature, than not :). It's mainly for testing stuff.
If you need any help in implementing these features, you are welcome to skype me, I can assist you with this anyhow.
Thank you! I will come back to that offer, when I got stuck :)
Hi,
I just implemented mouse over handling.
I came across a problem and wanted to ask about something.
See attached pic., as an example.
Is this a mockup or a real indicator? If it's real, how did you add the popup with scrolling?
As NETIndicator is not a form, adding controls are not possible (there is also no Invoke/BeginInvoke available, so controls cannot be added to the UI thread from another thread).
One possibility would be adding a form from the indicator.
OnPaintChart has "object sender" as a first parameter, but it's not a form. It's type is "GxQ=.7hw=".
Is it possible to share the source from the indicator in your screenshot?
Thanks!
Hi BeardPower!
I see the problem you are facing! But no need to sound an alarm. First thing first there is API method which allows you to use chart as control. Also you can Invoke after you retrieve a chart as Control. This is part of indicator's code you saw on picture, use it as an exapmle:
Control chrt = new Control();
{
chrt.MouseMove += rect_Enter;
chrt.MouseDown += Rect_clickDown;
chrt.MouseUp += Rect_clickUp;
if (win != null) // where is "win" is System.Windows.Forms.Panel
{
chrt.Invoke((MethodInvoker)(delegate { chrt.Controls.Add(win); }));
win.Hide();
}
}
I hope you use VS for creating add-ons for PTMC. That way creating popup with scrolling is a trivial task.
Hope this helps! Let me know if you need any extra help!
Regards!
BTW BeardPower! As far as I know PTMC DevOps team is planing to launch MARKET for all available add-ons and integrations. So this is how .net developers (and perhaps JS developers in the forthcoming future) will get extra reward. For the time beeing a Codebase is available for posting a porfolio, you more than welcome to fulfill community!
First thing first there is API method which allows you to use chart as control. Also you can Invoke after you retrieve a chart as Control. This is part of indicator's code you saw on picture, use it as an exapmle:
Ah, you rock, man! Totally appreciated!
I totally missed on that API method.
I hope you use VS for creating add-ons for PTMC.
Yes, I do.
As far as I know PTMC DevOps team is planing to launch MARKET for all available add-ons and integrations. So this is how .net developers (and perhaps JS developers in the forthcoming future) will get extra reward.
Yeah, I read about that in the forum. I'm curious what they have up their sleeves and how it will turn out.
As I understood, it's a marketplace like the Unity Asset store or something.
For the time beeing a Codebase is available for posting a porfolio, you more than welcome to fulfill community!
The stuff in CodeBase has to be free, including source code right? Are there any requirements like what has to be included (e.g. 32 Bit and 64 Bit versions, source code etc.)?
Cheers!
Glad to help, BeardPower!
I will keep you update if any news are coming to my table, untill then you are welcome to ask any assist!
Regards!
Hi Burhay Vlad,
Thanks for your detailed explanation!
I saw some screenshots in this thread https://protrader.org/forum/algostudio/functionali... Looks awesome!
Many developers are adopting Visual Studio Code as their IDE, which is Open Source. There is also the possibility to increase the power of VS Code through Extensions. VC is implemented with Electron, which tends to be a little slow, but it's really awesome. I'm using VC for coding in Haxe, but there are also plugins for .Net. A big advantage of VC is it's cross-platform ability.
Maybe this could also be an option for PTMC/AlgoStudio.
In terms of charge, codebase is not suitable place amid a lack of code protection methods. Upcoming market solution is a better option and we are all waiting for it as it eases transfer, and will let us focus on coding and idea generating.
Yeah, unfortunately code protection is a weak point of .Net. It would be great, if the modules could be encrypted and decrypted/loaded from AlgoStudio/PTMC. Like some exe packer with encryption functionality.
I will keep you update if any news are coming to my table, untill then you are welcome to ask any assist!
That's very kind of you, thanks!
Are you with PTMC? I recognized, that there are some members here, which are with PTMC, but not marked with that little "C" icon near their names/nicknames. :)
Cheers!