Super Simple Stocks is library and application that allows to do basic stock market operations.
Operations:
- For a given stock,
- Given any price as input, calculate the dividend yield
- Given any price as input, calculate the P/E ratio
- Record a trade, with timestamp, quantity, buy or sell indicator and price
- Calculate the GBCE All Share Index using the geometric mean of the Volume Weighted Stock Price for all stocks
- Java 8 SDK
- Maven 3 (required for first build)
To build and test, go to sss folder and run
mvn clean install
To test
mvn test
To run integration tests
mvn verify
- Run Super Simple Stocks Application. To do this locate sssc and run from that folder
cd sssc
mvn exec:java -Dexec.mainClass="com.github.kilork.sssc.App"
- Use interactive dialog to perform operations
Stock Symbol | Type | Last Dividend | Fixed Dividend | Par Value |
---|---|---|---|---|
TEA | Common | 0 | 100 | |
POP | Common | 8 | 100 | |
ALE | Common | 23 | 60 | |
GIN | Preferred | 8 | 2% | 100 |
JOE | Common | 13 | 250 |