Skip to content

Create a Jupyter Notebook for printing basic portfolio analysis #1

@dtmunir

Description

@dtmunir

Overview

Analyzing one's portfolio and understanding the risk is one of the first steps in having a good investing strategy. Since my trading strategy involves trading both options and equities, we will start by first creating a breakdown of how concentrated the portfolio is in each individual company.

Goals

  1. To build a Jupyter notebook with a set of easy to use functions that can be used every morning to assess the current concentration of the portfolio
  2. To calculate what percentage of the current portfolio value is in each individual company today (stocks + options)
  3. To extrapolate what will happen if all the current options end up being exercised as per the prices right now to the concentration.

Eg. Let's say I have the following positions

Ticker Type QTY

AAPL Equity 1000
FB Equity 500
SHOP Equity 100
SHOP PUT 1050 April 16 -3

We want to build a portfolio_status function that when run prints out a table with the following columns:

  • Ticker
  • Total Equities Market Value
  • Total Options Market Value
  • Total Market Value (Add Col 2 + Col3)
  • Mkt Val % (The market value of this line as a % of the total market value of all lines)
  • Post Expiry Market Value (Calculate what happens to the options if on the expiry date, the market price of the equity is the same as the current price)
  • P.E Mkt Val % (The post-expiry market value of this line as a % of the post-expiry mkt value of all lines)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions