From 625670c69e90e7754ca853b2e0e50c63d1b41e27 Mon Sep 17 00:00:00 2001 From: Oleg Sheynin Date: Fri, 6 Dec 2024 19:50:02 -0500 Subject: [PATCH] prepare sim for crypto (before added num_trades) - progress --- research/prepare_crypto_simdata.sh | 47 ++--------- research/prepare_eqt_simdata.sh | 127 +++++++++++++++++++++++++---- 2 files changed, 118 insertions(+), 56 deletions(-) diff --git a/research/prepare_crypto_simdata.sh b/research/prepare_crypto_simdata.sh index b839a4d..72b3c67 100755 --- a/research/prepare_crypto_simdata.sh +++ b/research/prepare_crypto_simdata.sh @@ -204,43 +204,7 @@ COMMIT; BEGIN; INSERT OR IGNORE INTO md_quotes SELECT - datetime(exchange_ts_ns / 1000000000, 'unixepoch') || '.' || printf('%06d', (exchange_ts_ns % 1000000000) / 1000) as tstmp, - time as tstamp_ns, - exchange_id, - instrument_id, - exchange_id as bid_exch, - bid_price as bid_px, - bid_quantity as bid_qty, - exchange_id as ask_exch, - ask_price as ask_px, - ask_quantity as ask_qty -from coinbase_md_booktops; -COMMIT; - -DETACH source_db; -EOF - -echo "Loading md_quotes ..." -sqlite3 ${ResultDbFile} <