- Python Algorithmic Trading Cookbook
- Pushpak Dagade
- 178字
- 2021-06-11 18:29:25
Attributes of a financial instrument
Financial instruments have various attributes that give more insight into the instrument, such as the trading symbol, exchange, segment, tick size, and so on. Some of these attributes are also needed while placing orders. This recipe lists and explains all the attributes supported by the broker. All the attributes are static, meaning they don't change during the live trading hours.
Getting ready
Make sure the instruments object is available in your Python namespace. Refer to the Fetching the list of financial instruments recipe of this chapter to set it up.
How to do it…
List all the attributes of a financial instrument provided by the broker:
>>> list(instruments.columns)
We get the following output:
['instrument_token',
'exchange_token',
trading-symbol,
'name',
'last_price',
'expiry',
'strike',
'tick_size',
'lot_size',
'instrument_type',
'segment',
exchange]
How it works…
The Fetching a list of financial instruments recipe fetches all the instruments as a pandas.DataFrame object. Calling its columns attribute returns all the columns available. Each column is an attribute for every financial instrument. You can find more details at https://kite.trade/docs/connect/v3/market-quotes/#csv-response-columns.
- WordPress Theme Development Beginner's Guide(Third Edition)
- Windows 7寶典
- Java Web整合開發(fā)全程指南
- 信息物理系統(tǒng)(CPS)測(cè)試與評(píng)價(jià)技術(shù)
- Chef:Powerful Infrastructure Automation
- Visual Basic項(xiàng)目開發(fā)案例精粹
- ADuC系列ARM器件應(yīng)用技術(shù)
- 貫通Java Web輕量級(jí)應(yīng)用開發(fā)
- 大型機(jī)系統(tǒng)應(yīng)用基礎(chǔ)
- Learning OpenShift
- 機(jī)器人手工制作
- 工業(yè)控制系統(tǒng)安全
- Hadoop大數(shù)據(jù)開發(fā)基礎(chǔ)
- 多傳感器數(shù)據(jù)智能融合理論與應(yīng)用
- 白話機(jī)器學(xué)習(xí)算法