Login Page - Create Account

Support Board


Date/Time: Fri, 23 Feb 2024 17:07:25 +0000



Automically moving an OCO limit order

View Count: 93

[2024-02-11 04:59:19]
User_1.0 - Posts: 86
There are lots of posts discussing the function to automatically move an attached stop order to BE or trail once the price reaches a ceratin point.

On the contrary, are there any functions/programs to be able to automatically move an limit order to a predetermined price, if the current price reaches a certain point?

For example:

Long Order entry @ $100
OCO Sell Limit @ $200
OCO Sell Stop @ $50

If the price hits $75, move existing OCO Sell Limit to $110. However, as long as the price stays above $50, keep the existing OCO Sell Limit @ $200.

Please note that this is different than what would be accomplished with a Triggered Stop-Limit, since I need to maintain the existing Sell Stop @ $50 in the example above, regardless of whether the price reached $75 or not.
[2024-02-12 16:13:52]
John - SC Support - Posts: 29333
You could use the "Trade Management by Study" study to do this. Refer to the following:
Attached Orders: Study Controlled Targets and Stops

We would recommend using the "Spreadsheet Formula" for the referenced study, where you would use a formula like the following:
=IF(C > 75, 110, 200)

This states that if the Close is greater than 75, then use a value of 110, else use a value of 200.

Although the "Spreadsheet Formula" has the name "Spreadsheet" in it, it uses the Alert Syntax. Refer to the following:
Study/Chart Alerts And Scanning: Available Main Price Graph Identifiers/Variables
For the most reliable, advanced, and zero cost futures order routing, use the Teton service:
Sierra Chart Teton Futures Order Routing
[2024-02-12 23:38:17]
User_1.0 - Posts: 86
Can you please clarify the following:

1. What do I specify under the option: Controlling Subgraph Reference

2. Where do I enter the "Spreadsheet Formula"?

3. Rather than going off the Close of the price, is it possible to specify the point of the price at any given time going forwards? If not, would you suggest that the only way to get it as accurate as possible would be to use very short interval candlesticks (like 1 min, or even less)?

4. If I want to use a value of 200 as long as the price stays above 75, but use a value of $110 if it drops below $75, would this be the correct formula:
=IF(C > 75, 200, 110).

5. And lastly to confirm, would using the formula above still leave the attached Sell Stop @ $50 regardless of the outcome?
[2024-02-13 17:02:09]
John - SC Support - Posts: 29333
1. The "Controlling Subgraph Reference" is the "Spreadsheet Formula" study.

2. The "Spreadsheet Formula" is a study with the first Input being "Formula". You enter the formula there.

3. The Close is the last price. It has dual meanings in Sierra Chart. One meaning is the actual Close of a bar, but since the current bar is always changing, the "close" of that bar is also the "Last" price.

4. Yes, that formula does what you want.

5. Yes, this will not affect the stop. In the "Trade Management by Study" study, you define if you want to move the Target or the Stop. In this case, you would specify the Target.
For the most reliable, advanced, and zero cost futures order routing, use the Teton service:
Sierra Chart Teton Futures Order Routing
[2024-02-19 02:33:15]
User_1.0 - Posts: 86
Will this still work if I "Hide" the Spreadsheet Formula Study?
[2024-02-19 02:50:15]
Sierra_Chart Engineering - Posts: 12922
Even if a study is hidden it is still calculated.
Sierra Chart Support - Engineering Level

Your definitive source for support. Other responses are from users. Try to keep your questions brief and to the point. Be aware of support policy:
https://www.sierrachart.com/index.php?l=PostingInformation.php#GeneralInformation

For the most reliable, advanced, and zero cost futures order routing, use the Teton service:
Sierra Chart Teton Futures Order Routing

To post a message in this thread, you need to log in with your Sierra Chart account:

Login

Login Page - Create Account