forked from jgalligan1993/Generating-Trend-Indicators-in-kdb
-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathschema.q
37 lines (27 loc) · 1.62 KB
/
schema.q
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
///Trade and Quote Exchanges
//Coinbase
trade_Coinbase:([] time:"p"$();date:`$();sym:`$();exch:`$();side:`$();ts:"f"$();tp:"f"$());
quote_Coinbase:([] time:"p"$();date:`$();sym:`$();exch:`$();ap:"f"$();bp:"f"$());
//Kraken
trade_Kraken:([] time:"p"$();date:`$();sym:`$();exch:`$();side:`$();ts:"f"$();tp:"f"$());
quote_Kraken:([] time:"p"$();date:`$();sym:`$();exch:`$();ap:"f"$();bp:"f"$());
//Bitfinex
trade_Bitfinex:([] time:"p"$();date:`$();sym:`$();exch:`$();side:`$();ts:"f"$();tp:"f"$());
quote_Bitfinex:([] time:"p"$();date:`$();sym:`$();exch:`$();ap:"f"$();bp:"f"$());
//HitBTC
trade_HitBTC:([] time:"p"$();date:`$();sym:`$();exch:`$();side:`$();ts:"f"$();tp:"f"$());
quote_HitBTC:([] time:"p"$();date:`$();sym:`$();exch:`$();ap:"f"$();bp:"f"$());
///Trade only Exchanges
//Bitmex
trade_Bitmex:([] time:"p"$();date:`$();sym:`$();exch:`$();side:`$();ts:"f"$();tp:"f"$());
//Bitstamp
trade_Bitstamp:([] time:"p"$();date:`$();sym:`$();exch:`$();side:`$();ts:"f"$();tp:"f"$());
//Gemini
trade_Gemini:([] time:"p"$();date:`$();sym:`$();exch:`$();side:`$();ts:"f"$();tp:"f"$());
//Huobi
trade_Huobi:([] time:"p"$();date:`$();sym:`$();exch:`$();side:`$();ts:"f"$();tp:"f"$());
//distionaries to be used by .u.upd func in tickerpant
tradeDict:`COINBASE`KRAKEN`HITBTC`BITFINEX!`quote_Coinbase`quote_Kraken`quote_HitBTC`quote_Bitfinex;
quoteDict:`COINBASE`KRAKEN`HITBTC`BITFINEX`BITMEX`BITSTAMP`GEMINI`HUOBI!`trade_Coinbase`trade_Kraken`trade_Bitfinex`trade_HitBTC`trade_Bitmex`trade_Bitstamp`trade_Gemini`trade_Huobi;
//sample .u.upd
//.u.upd:{$[x=`trade;tradeDict[y[3]] insert y; quoteDict[y[3]] insert y]}