The Portfolio Management System is a comprehensive Java-based application designed for managing and analyzing stock portfolios. It provides a wide range of functionalities, including portfolio creation, stock transactions recording, portfolio examination, and performance analysis.
- Create a Portfolio: Users can create multiple portfolios to manage different sets of stock investments.
- Examine a Portfolio: view detailed information about the stocks in a portfolio, including current holdings and transaction history.
- Calculate Portfolio Value: Determine the total value of a portfolio on a specified date.
- Add Stock to Portfolio: Purchase stocks to add to a portfolio by specifying the stock symbol, quantity, and purchase date.
- Sell Stock from Portfolio: Sell stocks from a portfolio, adjusting the portfolio's holdings accordingly.
- Calculate Investment: Analyze the total amount of money invested in a portfolio up to a specified date.
- Save/Load Portfolio: Portfolios can be saved to a file for later retrieval, allowing for persistent management over time.
- Graph: Plot a bar chart illustrating the performance of a stock or portfolio over a specified timeframe.
- Inspect Stock Performance: Check if a stock gained or lost on a specific day.
- Calculate X-Day Moving Average: Compute the moving average over a specified number of days for a given stock.
- Crossover Days: Identify the days within a specified period when a stock's closing price crossed over its opening price.
- Moving Crossover Days: Find the days where the stock's closing price crossed over its moving average within a specified period.
- Dollar Cost Averaging: Implement a dollar-cost averaging investment strategy by investing a fixed amount periodically in a portfolio.
- Value Based Investment: Invest a fixed amount in a portfolio containing multiple stocks with specified weights for each stock.
- Create a new portfolio
- Examine a portfolio
- Calculate portfolio value
- Add Stock to Portfolio
- Sell Stock from Portfolio
- Calculate Investment
- Save portfolio
- Load portfolio
- Graph
- Inspect Stock performance
- Calculate X-Day Moving Average
- Crossover Days
- Moving Crossover Days
- Dollar Cost Averaging
- Value Based Investment
- Exit
Select an option from the menu to perform the corresponding action. The system is designed to be intuitive and user-friendly, guiding you through each process step by step.
After launching the application, you will be presented with the main menu. From here, you can choose to create a new portfolio, examine existing portfolios, add or sell stocks, and perform various analyses on your stock holdings.
- Select "1. Create a new portfolio" from the main menu.
- Enter a name for your new portfolio when prompted.
- Select "4. Add Stock to Portfolio" from the main menu.
- Follow the prompts to specify the stock symbol, quantity, and purchase date.
- Select "10. Inspect Stock performance" from the main menu.
- Enter the stock symbol and the date you wish to inspect.
- Fixed Amount Investment: Invest a fixed amount into an existing portfolio containing multiple stocks with equal weights for each stock.
-
Fixed Amount Investment: You can now invest a fixed amount into an existing portfolio containing multiple stocks with specified weights for each stock. This allows for the purchase of fractional shares based on the specified amount. For example, create a FANG portfolio (Facebook, Apple, Netflix, Google) and invest $2000 with specified weights for each stock.
-
Start-to-Finish Dollar-Cost Averaging Operation: Implement "start-to-finish" dollar-cost averaging as a single operation. This feature enables you to create a portfolio of specified stocks and invest a fixed amount in the portfolio periodically (e.g., every 30 days) starting from a specific date until an end date, or indefinitely if the end date is not specified. Use the same specified weights for each transaction.
-
Handling Investments on Holidays: For periodic investment strategies, if a scheduled investment day falls on a holiday, the program will automatically select the next available day for investment, using end-of-day prices for stock purchases.
- The design supports the addition of other high-level, time-based long-term investment strategies in the future, making the system flexible and scalable for further enhancements.
Continue exploring other options from the menu to fully utilize the capabilities of the Portfolio Management System.
- Ensure you have Java JDK 8 or higher installed on your system.
- Clone the repository to your local machine: