July 30, 2024

Mean Variance Optimization

Mean Variance Optimization (MVO) is a well-established but rigorous technique used in managing financial portfolios. However, the covariance calculated by MVO often contains estimation errors. To address this, the Ledoit-Wolf Shrinkage operator is frequently recommended. This approach is used as a baseline in this paper(https://icaps23.icaps-conference.org/papers/finplan/FinPlan23_paper_4.pdf) First, I will explain Mean Variance Optimization, and then I will discuss the Ledoit-Wolf Shrinkage operator, which is an improved version of MVO. Minimize risks(variances) by given returns import numpy as np import yfinance as yf import scipy....

July 30, 2024

Reading paper list

Deep Reinforcement Learning for Optimal Portfolio Allocation https://icaps23.icaps-conference.org/papers/finplan/FinPlan23_paper_4.pdf 60 days look back in MVO MVO

February 1, 2024

Mplfinance tips

Plotting Financial Data with Market Color Overrides import polars as pl import mplfinance as mpf df = pl.read_csv("df.csv", try_parse_dates=True) df = df.to_pandas() df = df.set_index("datetime") # Plot the data without market color overrides mpf.plot(df,volume=False,type='candle',style='yahoo',figscale=1.4) # Initialize the MCOverrides column with the base market colors (black and white) mc = mpf.make_marketcolors(base_mpf_style='classic') # Get the target column target = df["target"] # Initialize the column with all values set to `mc` df['MCOverrides'] = [mc] * len(df) # Override the market colors based on the target value df....

January 20, 2024

This is a image test for visual formatting

Bold the title of header I only blog about things that I may want to search for and review later. Bold the title of header Bold the title of header Bold the title of header Bold the title of header Bold the title of header Bold the title of header Bold the title of header Bold the title of header Bold the title of header Bold the title of header

January 12, 2024

How I generate thumbnail image

hugginface stable diffusion https://huggingface.co/spaces/stabilityai/stable-diffusion my prompt is Sepia renaissance “title of the article” This cover image is also generated by AI. Prompt is polar bear sepia my prompt is Sepia renaissance “title of the article” This cover image is also generated by AI. Prompt is polar bear sepia