Skip to content

Instantly share code, notes, and snippets.

import io
import requests
import pandas as pd
def trade_quote(symbol, expiration, date):
url = "http://127.0.0.1:25510/v2/bulk_hist/option/trade_quote"
querystring = { "root": symbol, "exp": expiration, "start_date": date, "end_date": date, "use_csv":"true" }
import pandas as pd
import treasury_gov_pandas.datasets.mts.mts_table_4.load
import streamlit as st
import plotly.express as px
import numpy as np
df = treasury_gov_pandas.datasets.mts.mts_table_4.load.load()
# convert null values to 0 in the column 'current_month_net_rcpt_amt'
import os
import glob
import pandas as pd
from bokeh.plotting import figure, show
from bokeh.models import ColumnDataSource, HoverTool
from bokeh.transform import linear_cmap
from bokeh.palettes import Viridis256
from bokeh.io import output_notebook
from bokeh.plotting import figure, show
import bokeh.models
import bokeh.palettes
import bokeh.transform
import pandas as pd
from bokeh.plotting import figure, show
import bokeh.models
import bokeh.palettes
import bokeh.transform
import pandas as pd
import pandas as pd
import treasury_gov_pandas
from bokeh.plotting import figure, show
from bokeh.models import NumeralTickFormatter, HoverTool
import bokeh.models
import bokeh.palettes
import bokeh.transform
# ----------------------------------------------------------------------
df = treasury_gov_pandas.update_records(
import yfinance_download
from bokeh.plotting import figure, show
import bokeh.models
import bokeh.palettes
import bokeh.transform
df = yfinance_download.update_records('^GSPC', interval='1d')
import yfinance_download
spx = yfinance_download.update_records('^GSPC', interval='1wk')
ndq = yfinance_download.update_records('^IXIC', interval='1wk')
# ndq = yfinance_download.update_records('^NDX', interval='1wk')
# ----------------------------------------------
import yfinance_download
from bokeh.plotting import figure, show
from bokeh.models import NumeralTickFormatter, HoverTool
import bokeh.models
import bokeh.palettes
import bokeh.transform
# https://www.ffiec.gov/npw/FinancialReport/FinancialDataDownload
# $result_bhcf = Import-Csv .\BHCF.csv
# $result_rssd = Import-Csv .\RSSD.csv
Write-Host 'Importing CSV...' -ForegroundColor Yellow -NoNewline
# $result = Import-Csv -Delimiter '^' -Path BHCF20221231.txt