- ago
I updated to B50 but I still can't get option trade placed in Dummy Broker.
0
418
Solved
31 Replies

Reply

Bookmark

Sort
Glitch8
 ( 11.81% )
- ago
#1
What do you mean, it is placed. It's in FinalOrder status.
0
- ago
#2
Can you please explain what that status indicates?

I mean that the trade is staying in the Order Manager, Is not showing in the Account Manager, and the Account Manager show 0 positions in the Dummy Account. Usually, if I place a non-option order to the Dummy Broker, it appears right away.
0
Glitch8
 ( 11.81% )
- ago
#3
The FinalOrder status is what happens when an order is placed on the final bar of the trading day. The Order sits in Final Order status for a certain period of time before getting submitted as a market order to the broker.

It's described in detail in the Order Manager help topic in WL8.
0
Best Answer
- ago
#4
I still have not been able to place an option trade in the Dummy Broker via strategy. I tried the manual method, and this is what I got.



0
Cone8
 ( 25.44% )
- ago
#5
Wrong symbol format.
0
- ago
#6
Yikes!
0
- ago
#7
I'm still getting error auto placing trade in WL Dummy account. This is true even if I first stage the auto-trade and then click to Place.



I get the same error if I try to place trade manually (I think I entered it correctly this time ;) 



I am able to auto trade position into IB Dummy Broker from same strategy without a problem.

0
Cone8
 ( 25.44% )
- ago
#8
If you're using WL8 Build 50, I don't know what to tell you. It works perfectly here.



See if you can get a 30-minute chart of that or any option contract.
0
- ago
#9
I am running the latest build.

I can get all different frequency intraday bars in a chart for this symbol. Data is being sourced from IB.
0
Cone8
 ( 25.44% )
- ago
#10
Okay, I see why now.
In your other "can't trade options" post there are instructions you ignored.

Hint: Which Streaming Provider did you select for the Order Manager?
0
- ago
#11
I see where I had an oversight. In setting up the strategy in the SM, I failed to deselect the default streaming provider (Yahoo!) and replace it with IB. I appears that WL carries that selection with the trade, so that even if I first stage it and then try to place by click, it keeps the Yahoo! designation, even when IB is selected at the top of the Order manager.

As you pointed out, my image shows Yahoo! selected at the top of the Order Manager. I never noticed this or intentionally selected it, but I suspect it became the default when I allowed it to be the default in my SM setup.

I will insure the correct streaming setting in the SM going forward. Everything is working now. Thanks for your catch.!
1
Cone8
 ( 25.44% )
- ago
#12
It will probably help to know that the last Streaming Provider that you select in any tool becomes the default provider for newly-opened windows like charts and the Order Manager.
0
- ago
#13
Yes, that is good to know. This is the first time I'm running intraday data from the Strategy Monitor, and I never paid much attention to the streaming setting when setting values for new strategy in SM. I will now!
0
- ago
#14
Actually, I figured out what happened. I normally use 30 min bars for options trading. and select "Polling" in setup as suggested. This selection leaves the "Streaming Provider" selection inactive (greyed out, and not changeable). While testing, I moved to 1 min bars to see trades more quickly, and changed selection to "Streaming," as recommended. This activates the "Streaming Provider" setting, which was previously defaulted to Yahoo! (and unable to be changed).

It was moving to 1 min bars that created a change in functionality that I didn't notice, since I had never had to set the "Streaming Provider" selection before.
0
- ago
#15
I am testing Tradier as streaming and historical provider with WL Dummy as broker. My intraday trades are being held in FInalOrder status in the Order Manager.



QUOTE:
Buy 13 QQQ240326C00439000 Invesco QQQ Trust Market 0 FinalOrder 0 0 3/20/2024 08:18:32 Test Intraday Trading EMA - dev15, QQQ-SPY - Tradier, 5 Minute, Dummy Broker, Account 6, US Stocks Account 6

Buy 16 SPY240326C00516000 SPDR S&P 500 Market 0 FinalOrder 0 0 3/20/2024 08:18:32 Test Intraday Trading EMA - dev15, QQQ-SPY - Tradier, 5 Minute, Dummy Broker, Account 6, US Stocks Account 6


After re-reading this post and related ones, and user docs, it sounds like this "feature" only applies to IB, but I am not using IB as a broker or provider for this strategy. Is the issue that the option symbol is not in compact OSI form and needs to be converted?

In case it might matter, I have the delay set to 0 in IB configurator and I thought this feature was supposed to be ignored.

QUOTE:
For Build 40 "Final Order" processing will be bypassed if the value set in the IB configuration is zero or less.

See Post #12.
0
Cone8
 ( 25.44% )
- ago
#16
QUOTE:
it sounds like this "feature" only applies to IB
Not correct. It applies to all brokers.

The IB Provider just has a special setting that lets you change how long you wait to place the final order. If a broker doesn't override it, it will be placed 15 minutes after the close.
0
- ago
#17
As I noted, it's set to 0 in IB. So why is it not being overridden?

Addendum

Also, the position is being processed intraday. FinalOrder apparently was applied on the last bar of the last SM run, not at 4 PM market close. How does that make sense?

This issue was discussed starting on Post 11 at https://www.wealth-lab.com/Discussion/Can-I-disable-quot-Final-Order-quot-9909

The resolution in Post 12 seems not to be working.
0
Cone8
 ( 25.44% )
- ago
#18
QUOTE:
As I noted, it's set to 0 in IB. So why is it not being overridden?
Didn't you also note that you're using the Dummy Broker and not IB?

QUOTE:
Also, the position is being processed intraday.
It sounds like the wrong market is assigned to the symbol you're trading. Does it match any records in the Symbols section of Markets & Symbols? If so, what market is it assigned to?

I don't see how Post #12 is related to anything about this. What connection are you making?
0
- ago
#19
QUOTE:
Didn't you also note that you're using the Dummy Broker and not IB?

Yes, i did. In Post #12 you wrote

QUOTE:
Not correct. It applies to all brokers.


Did you mean to include the Dummy Broker in that response?

QUOTE:
I don't see how Post #12 is related to anything about this. What connection are you making?


It's tied to the link that preceded it, which is a different discussion directly related https://www.wealth-lab.com/Discussion/Can-I-disable-quot-Final-Order-quot-9909

See post 12 in that discussion.
0
- ago
#20
QUOTE:
It sounds like the wrong market is assigned to the symbol you're trading. Does it match any records in the Symbols section of Markets & Symbols? If so, what market is it assigned to?

I don't see anything there that relates to these symbols, options for SPY and QQQ.



BTW, the FinalOrder orders are still sitting in the Order Manager, 4 hours after being placed. The strategy has not generated any new signals during that time, presumably because it's waiting for the FInalOrder ones to be processed.
0
Cone8
 ( 25.44% )
- ago
#21
Post 12 in the other conversation was:
For Build 40 "Final Order" processing will be bypassed if the value set in the IB configuration is zero or less."

We were talking about IB as the broker. IB settings are for IB only.

The Dummy Broker will use the "base broker" settings. So an order marked as a 'Final Order' won't be placed until 15 minutes after the close.

The problem appears to be that something is triggering that logic to mark an order as "Final Order" when it should not, intermittently.
0
- ago
#22
OK. Let me know if there's any info I can send to help troubleshoot.
QUOTE:
The problem appears to be that something is triggering that logic to mark an order as "Final Order" when it should not, intermittently.

Why do you think it is intermittent?
0
Glitch8
 ( 11.81% )
- ago
#23
A Transaction should get flagged as "FinalOrder" only if its entry date time of day is equal to the time of day of the market close.
0
Cone8
 ( 25.44% )
- ago
#24
QUOTE:
Why do you think it is intermittent?
Because I've never seen it happen when it should not have. I consider it intermittent (or better, "very rare") because I only know about 2 cases (yours and the one in the other thread) that it has occurred when it seems that it shouldn't have.

But the logic is very clear - as Glitch said.
0
- ago
#25
OK. Thanks for clarifying. It doesn't look like it's intermittent on *my* side.

I just ran in SW (instead of SM) and got 2 signals to buy. I placed the orders from the Signals window and got the same result. I guess that doesn't prove anything since running at this time of day the last bar is 4:00 PM, market time. However, would you expect that behavior if using the Dummy Broker? And if so, how long before it would be processed. It's been more than 15 minutes since order was placed, but not filled.

It may not be intermittent. It may just be that mjj3 and I have an unusual configuration, are doing something unusual, or something is different on our machines. Just to be sure, I restarted my PC but same issue.

FWIW, my code is managing processing of external symbols on the last bar. I can email you the Strategy if you want to see if you can replicate the issue.
0
Cone8
 ( 25.44% )
- ago
#26
Before you send code, the next time it happens just look at a chart for the symbol you're trading. Is the last bar 4pm? If the answer is yes, then check if your code is synchronizing the BarHistory that you're trading to the primary bars.

Also, the Timestamps on your "Final Orders" above are 06:59, 08:18, etc.
What time zone is that? (What time zone is your computer using? If it's EST or even CST, then that's the problem.)
0
- ago
#27
QUOTE:
Is the last bar 4pm?

Yes
QUOTE:
What time zone is your computer using?

Pacific Time
QUOTE:
check if your code is synchronizing the BarHistory that you're trading to the primary bars.

I'm not sure but I think it is by virtue of the fact that is passing bars as a value to the method.
CODE:
               _obars = RetrieveOptionBars(bars, contractSymbol);                if (_obars != null)                {                   _syms.Add(contractSymbol);                   _transaction = PlaceTrade(_obars, TransactionType.Buy, OrderType.Market, 0, _hash, "Buy At Market");

CODE:
      private BarHistory RetrieveOptionBars(BarHistory syncbars, string symbol)       {          BarHistory obars;          if (_dict.ContainsKey(symbol))          {          obars = _dict[symbol];          }          else          {             BarHistory barHistory = GetHistory(syncbars, symbol);             obars = barHistory;             _dict.Add(symbol, obars);          }          return obars;       }

0
Cone8
 ( 25.44% )
- ago
#28
I can't tell from your snippets what you're using for syncbars passed to GetHistory(), but if it's the primary symbol's chart BarHistory, then that's the right one.

QUOTE:
Is the last bar 4pm? Yes
It's 4pm in the middle of the trading day? Are you on delayed data?
If the last bar is 4pm, that's why you're getting a Final Order.
0
- ago
#29
QUOTE:
I can't tell from your snippets what you're using for syncbars passed to GetHistory()

This line was not sufficient?
CODE:
_obars = RetrieveOptionBars(bars, contractSymbol);


QUOTE:
It's 4pm in the middle of the trading day?

I don't understand this question.
QUOTE:
Are you on delayed data?

No
QUOTE:
If the last bar is 4pm, that's why you're getting a Final Order.

Sorry,, I don't understand. It's an intraday strategy running live. It generated a signal in the morning, market time, that yielded FInalOrder to the Order Manager and was not executed.

0
Cone8
 ( 25.44% )
- ago
#30
Here's the instruction:
...the next time it happens just look at a chart for the symbol you're trading. Is the last bar 4pm?

Re: _obars = RetrieveOptionBars(bars, contractSymbol);
I can make an assumption, but there is no reference to where bars are declared.
0
- ago
#31
OK. Next time I'll include anything that might be instantiating the variable. In this case it would have been the Execute(.....) method header.
0

Reply

Bookmark

Sort