Skip to content

Instantly share code, notes, and snippets.

View pannet1's full-sized avatar

pannet1 pannet1

View GitHub Profile
## WARNING: This is not meant to be used, this is just for demonstration purpose. Get official kite API access from Zerodha.
## USAGE:
# from kiteext_pro_open import KiteExt
# kite = KiteExt()
# kite.login_with_credentials(user_id, password, twofa_secret)
# print(kite.profile())
# print(kite.ltp(['NSE:TCS']))
# print(kite.quote(['NSE:TCS']))
# known issue: history api not working.
@MooneDrJune
MooneDrJune / ExtractMetaFromTradingSymbol.py
Last active November 10, 2023 15:40
Extract MetaData From Derivative Trading Symbol (Indian Market Specific)
from __future__ import annotations
import re, pandas as pd
from typing import Dict
from functools import lru_cache
from datetime import date, datetime as dt
DERIVATIVES_TRADINGSYMBOL_META = re.compile(
"(?P<instrument>[A-Z]+)(?P<expiry>[A-Z0-9]{5})(?P<instrument_type>[A-Z0-9.]+)"
)
OND_MAP = {"O": "Oct", "N": "Nov", "D": "Dec"}
@mkhoeini
mkhoeini / autoload_myspacevim.vim
Last active August 3, 2022 12:57
SpaceVim Config
function! myspacevim#before() abort
" let g:neomake_enabled_c_makers = ['clang']
" nnoremap jk <Esc>
endfunction
function! myspacevim#after() abort
" let g:ale_fixers = {
" \ 'javascript': [
" \ 'eslint',
" \ 'prettier',