How to reference a chart's indicators when coding in MultiCharts?
Welcome to futures io.
(If you already have an account, login at the top of the page)
futures io is the largest futures trading community on the planet, with over 100,000 members. At futures io, our goal has always been and always will be to create a friendly, positive, forward-thinking community where members can openly share and discuss everything the world of trading has to offer. The community is one of the friendliest you will find on any subject, with members going out of their way to help others. Some of the primary differences between futures io and other trading sites revolve around the standards of our community. Those standards include a code of conduct for our members, as well as extremely high standards that govern which partners we do business with, and which products or services we recommend to our members.
At futures io, our focus is on quality education. No hype, gimmicks, or secret sauce. The truth is: trading is hard. To succeed, you need to surround yourself with the right support system, educational content, and trading mentors – all of which you can find on futures io, utilizing our social trading environment.
With futures io, you can find honest trading reviews on brokers, trading rooms, indicator packages, trading strategies, and much more. Our trading review process is highly moderated to ensure that only genuine users are allowed, so you don’t need to worry about fake reviews.
We are fundamentally different than most other trading sites:
We are here to help. Just let us know what you need.
We work extremely hard to keep things positive in our community.
We do not tolerate rude behavior, trolling, or vendors advertising in posts.
We firmly believe in and encourage sharing. The holy grail is within you, we can help you find it.
We expect our members to participate and become a part of the community. Help yourself by helping others.
You'll need to register in order to view the content of the threads and start contributing to our community. It's free and simple.
How to reference a chart's indicators when coding in MultiCharts?
Novice question: I have added studies to a chart and would like to build a strategy (signal) to trade based on them. For example, I have "Mov Avg 1 Line" on my chart. I would like to place a BUY STP order 1 cent above that signal's value (assuming price is currently lower than that value), and update the BUY STP price whenever that indicator's value changes (at the close of each bar, when the MA gets recalculated).
I'm sure there will be a few challenges but the first one is how to reference the price of that indicator, which has already been added to the chart? Or do I need to reproduce that indicator within the code?
I will need to code the following logic:
If Close is lower than "Mov Avg 1 Line" value, place BUY STP at "Mov Avg 1 Line" value + 1 tick
I can tell my next problem will be how to place a BUY STP at a certain price, in advance, and then update that order at the close of each bar, since it seems most example strategies use "buy next bar at market" which is not what I want. Thanks guys!
you will have to reproduce the code within the signal and can't reference the indicators on the chart directly.
When you open the code for the "Mov Avg 1 Line" the top lines are the ones necessary for calculating the average.
Change var0 will something more meaningful like vAverage, so you can find your way around your code better.
The code below is a demonstration on how you could code what you have in mind and is not meant for live trading:
Regards,
ABCTG
The following user says Thank You to ABCTG for this post:
That's incredibly helpful, thank you. I was just using a Powerlanguage tutorial on your website yesterday so it's very cool to be talking to you on here. This gives me a lot to work with for now.
Jesse
The following user says Thank You to jesse514 for this post: