generate_plot#

This script loads the updated reproduction decile returns DataFrame from the designated DATA_DIR and uses the function plot_cumulative_returns from calc_metrics to plot the cumulative returns for each decile portfolio. It also loads the merged bond data and uses plot_avg_yield_tr_ytm to plot the average ‘yield’ and average ‘tr_ytm_match’ over time. The resulting plots are saved as PNG files in OUTPUT_DIR.

Usage: Run this script directly (e.g., via python plot_cumulative_returns_script.py) to generate and save the cumulative returns and average yield/tr_ytm_match charts.

Module Contents#

Functions#

Data#

API#

generate_plot.DATA_DIR#

‘Path(…)’

generate_plot.OUTPUT_DIR#

‘Path(…)’

generate_plot.main()#