Net Liquidity formula:
Net Liquidity = Federal Reserve Balance sheet - Treasury General Account - Reverse Repo
Twitter thread by Max Anderson:
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 |
using System; | |
using System.IO; | |
using System.Media; | |
namespace WavFileTest | |
{ | |
class Program | |
{ | |
static void Main(string[] args) | |
{ |
Net Liquidity formula:
Net Liquidity = Federal Reserve Balance sheet - Treasury General Account - Reverse Repo
Twitter thread by Max Anderson:
function get-recent-tga () | |
{ | |
$date = (Get-Date).AddDays(-14).ToString('yyyy-MM-dd') | |
$result = Invoke-RestMethod -Method Get -Uri ('https://api.fiscaldata.treasury.gov/services/api/fiscal_service/v1/accounting/dts/dts_table_1?filter=record_date:gte:{0},account_type:eq:Treasury General Account (TGA) Closing Balance&fields=record_date,open_today_bal' -f $date) | |
# $result.data | Sort-Object -Property record_date | Select-Object -Last 1 | |
$result.data[-1] |
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 |
In a previous note I demonstrated polymorphism in Scheme using Chez Scheme's compile time values and properties.
The code in that example is pretty raw; you might not want to code each generic in that manner. One approach is to decouple the signature/method table. We can do this by factoring out some code into a 'make-generic' procedure:
(define (make-generic table) (lambda (stx) (lambda (lookup)