Hi @Damon, I'am Manlin and just calling ask for help. I am beginner and just building a simple scalping algo but facing an issue that are causing us not be hedged.
The logic of buy-side order is correct I think. And after the buy-order filled, there are two situation trigger the Sell-order filled to lose my position, one is to sell it 3 ticks above my long position, the other is to close position with market price in order to stop loss. But the problem is the position becomes negative after a few minutes running. Since the logic is set as either sell 3 ticks higher or sell at market price, just want to close the existing position, so it should not have negative position there.
I attach the algo below, could you help me take a look?
Thank you!
Whole Algo:
Close position:
Answer by Damon · Nov 28, 2016 at 10:16 PM
Hello @mcai6
Can you please show me what you have for your ENTRY Buy Side logic management group block. Also, how are you populating the Entry Order Qty? Do you have internal conditional logic inside your DOB?
Regarding your EXIT Hedge Logic..... I would try patterning it after this sample of a OCO type Library Block logic:\
Link: https://community.tradingtechnologies.com/article...
A few other questions to ask:
- Why are you using a Value Accumulator Block as a pass through function to trigger the Buy DOB? You could use the discrete message from the Generator Block to do the same thing.
- Why are you not placing your DOB inside your BUY side order management virtualized group block? This could pose some difficulties downstream in your logic with keeping track of all the possible child order submissions.
Ask questions and share ideas about the TT® and X_TRADER® platforms.
First time here? See our Getting Started Guide and FAQs.
Single Order Container delete functionality 1 Answer
Help to understand Order Block vs Discrete Order Block 2 Answers
ADL Multiple Exit Orders – Profit Target, Break Even and Stop Loss Order Managment 2 Answers
How do I program ADL to delete my working order if I become "alone" at that price? 1 Answer
Can Stop Orders be Triggered by A Quantity Threshold as well as Price 9 Answers
© 2017 Trading Technologies International, Inc. All rights reserved.
Powered by AnswerHub