Jump to content
  • 0

Calculating the market price from bid/ask spread


Jat1990

Question

Hi all,

I'm using the API to make programmatic trades. 

The historical prices for the intervals are provided as open, high, low, close as expected. However the prices are the broker spread prices and not the market price.

For example, BAE Systems Plc (LSE) givesm e a close price bid of 520.5 and close price ask as 521.9 on Monday 24 May 2021 at 16:00 (1 hour intervals).

I would expect the mid-price ((520.5 + 521.9) / 2) of 521,2 to equal the market price at the time, but it does not. At 16:00, BAE price was 520.8.

 

Does anyone know how I can get the correct market price from the bid/ask spread?

 

Thanks

Link to comment

0 answers to this question

Recommended Posts

There have been no answers to this question yet

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • image.png

  • Posts

    • Lots of Open Source Stuff on Github, I've worked with the API for probably 10 years or so.    https://github.com/tg12
    • That is called "algorithmic trading" or "algotrading" and a wealth of books/videos is available about this subject, e.g. the /r/algotrading subreddit.
    • I recently came across a trading bot carnival on Bitget where users are encouraged to trade EIGEN, CATI, TON, and MOODENG to share from $50,000. Though this looks enticing but I was confused, is bot trading different from copy trading? He explained that both methods trade for you automatically. Specifically, copy trading lets you copy the trade of an experienced trader, whereas bot trading follows set rules or algorithms to make trades. He recommended both as great starting points for beginners like me to get a feel for the market. I recently started exploring copy trading and now I need to add bot trading along since I want to try out the carnival and if it is better I might stick to it or what do you think?
×
×
  • Create New...
us