Virtual Portfolio Management Platform Development
===
:::info
Goal: Let people have opportunities to practice how to manipulate their money in stock markets.
:::
###### tags: `Web Development` `Investment`
APIs
---
### Stock Price Fetching
+ [Tiingo](https://api.tiingo.com/documentation/general/overview)
## Website Features
### Account System
+ Accounts linked with Google Account: (Required)
- [Integrating Google Sign-In into your web app](https://developers.google.com/identity/sign-in/web/sign-in)
- [APIs of Sign In With Google](https://developers.google.com/identity/gsi/web/guides/overview)
- [Code Samples](https://developers.google.com/identity/sign-in/web)
+ Register with Email (Optional)
+ Sign in/out (Required)
### Stock Price Display with Selection Button
+ Candlestick Charts
- [Making a JS Candlestick Chart in Four Simple Steps](https://www.anychart.com/blog/2020/03/25/js-candlestick-chart-steps/)
- [Candlestick Charts with Google APIs in HTML](https://developers.google.com/chart/interactive/docs/gallery/candlestickchart)
+ Line Charts (Required)
+ Daily (Required) / Weekly / Monthly / quarterly Stock Price
+ Code Samples:
- [Chart Suites with Code](https://www.fusioncharts.com/charts) **<-- Must see**
### Dashboard & Reports (Home Page)
+ **Net Worth (淨值) in Area Chart:** (Required)
The assets and gains a person owns minus the losses.
- x axis: Day (Separate each month section with two gridlines, and mark the month name)
- y axis: Net Worth (NT$)
+ **Stock Portfolio in Pie Chart:** (Required)
Visualize different partitions of stocks users own.
+ **Current ROI / Price of Individuals in Histogram with Selection Button:**
Current market price relative to the bid price (買價).
- x axis: different stock symbols (put under bottoms of bars)
- y axis: ROI (%) / Price
- Zero horizontal line: Distinguish the gains and losses
* Gains: Red bar
* Losses: Green bar
+ **Monthly Total ROI in Line Chart**
- x axis: Month
- y axis: Total ROI (%)
+ **"Current Net Worth" and "Some Main Stocks" Displayed on the Left Menu**
#### _Definition_
+ **Return of Investment (ROI, 投資報酬率)**
- **[Annualized Rate of Return](https://www.investopedia.com/terms/a/annualized-rate.asp) (AROR, 年化報酬率):** (Required) (We might subtitute with "Weekly or Daily rate of Return")
* Formula:
$AROR = (\frac{P + G}{P}) ^ {\frac{1}{n}} - 1$
P = principal, or initial investment
G = gains or losses
n = number of years
- **[Internal Rate of Return](https://www.investopedia.com/terms/i/irr.asp) (IRR, 內部報酬率): <- Need couples of time to figure out**
* 當一個投資,有許多筆現金流在不同時間進進出出時,例如儲蓄險、定期定額基金,或是現金流較複雜的投資,這時就不能用前面簡單算報酬率的公式了,因為每一筆金流的時間長度都不一樣。
這時就要用IRR法來算報酬率。
* 原理:就是用 “猜” 的,透過不斷的猜測報酬率,去逼近真正的報酬率。
---
### Trading System (for Practicing your Strategy with Paper Money)
+ **NT$100,000** in Each Initial Account
+ **Market Orders (市價訂單)** (Required)
- Buy stocks
- Sell stocks
+ **Limit Orders (限價訂單)** (Optional)
- Buy limit
- Sell limit
- Buy stop
- Sell stop
+ [Terms Definition](https://www.investopedia.com/investing/basics-trading-stock-know-your-orders/)
### Trading Strategy Recommendation
:::info
When it is a nice time point to enter or leave the stock market, send notifications to users.
:::
#### Momentum Strategy
+ Moving Average Crossover (We can use)
+ Dual Moving Average Crossover
+ Turtle Trading
#### Reversion Strategy
+ Mean Reversion Strategy (We can use)
+ Pairs trading Strategy:
If there's a specific correlation between two stock prices.
#### Code Samples
+ [Stock Portfolio App - demo on Heroku](https://github.com/ptyadana/django-WEB-stock-portfolio-management)
+ [Python For Finance: Algorithmic Trading](https://www.datacamp.com/community/tutorials/finance-python-trading?utm_source=adwords_ppc&utm_campaignid=12492439802&utm_adgroupid=122563403721&utm_device=c&utm_keyword=python%20finance&utm_matchtype=b&utm_network=g&utm_adpostion=&utm_creative=504158804788&utm_targetid=kwd-301111479313&utm_loc_interest_ms=&utm_loc_physical_ms=9040380&gclid=Cj0KCQjwnoqLBhD4ARIsAL5JedLy9_vs1c-SIBolKopyhPC548EW36bSXQXC5LlM9MyIiyEpYl60c54aApuUEALw_wcB)
## Deployment
+ **Domain Name:**
financarefree.com (NT$298 in first year)
- [GoDaddy](https://tw.godaddy.com/domainsearch/find?checkAvail=1&domainToCheck=financarefree.com)
+ [How to Upload Your Website To The Internet](https://www.youtube.com/watch?v=kvyWeTXCSKk)
{"metaMigratedAt":"2023-06-16T12:09:43.614Z","metaMigratedFrom":"Content","title":"Virtual Portfolio Management Platform Development","breaks":true,"contributors":"[{\"id\":\"ba4b976f-0f52-40bb-a9be-312b412753d3\",\"add\":5151,\"del\":591}]"}