From 30847ffd4cc29a8d049877029d037abf9c1ff3c5 Mon Sep 17 00:00:00 2001 From: Artem Veremey Date: Wed, 21 Apr 2021 22:25:25 -0700 Subject: [PATCH 01/11] Updating poetry action and version --- .github/workflows/test.yml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index fceaff60738..52d673da809 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -49,8 +49,9 @@ jobs: architecture: x64 - name: Install Poetry - uses: snok/install-poetry@v1.1.1 + uses: snok/install-poetry@v1.1.4 with: + version: 1.1.6 virtualenvs-create: true virtualenvs-in-project: true @@ -102,8 +103,9 @@ jobs: architecture: x64 - name: Install Poetry - uses: snok/install-poetry@v1.1.1 + uses: snok/install-poetry@v1.1.4 with: + version: 1.1.6 virtualenvs-create: true virtualenvs-in-project: true From 0ee59c8439bef4f87eda9bad8ede6059021287d2 Mon Sep 17 00:00:00 2001 From: didier Date: Thu, 22 Apr 2021 22:21:27 +0100 Subject: [PATCH 02/11] Add fa-score --- .../fundamental_analysis/fa_controller.py | 9 +++++ .../financial_modeling_prep_view.py | 35 +++++++++++++++++++ poetry.lock | 35 +++++++------------ pyproject.toml | 1 + requirements.txt | 1 + 5 files changed, 59 insertions(+), 22 deletions(-) diff --git a/gamestonk_terminal/fundamental_analysis/fa_controller.py b/gamestonk_terminal/fundamental_analysis/fa_controller.py index 2cad209fd82..5de204ab675 100644 --- a/gamestonk_terminal/fundamental_analysis/fa_controller.py +++ b/gamestonk_terminal/fundamental_analysis/fa_controller.py @@ -9,6 +9,7 @@ from gamestonk_terminal.fundamental_analysis import alpha_vantage_controller as from gamestonk_terminal.fundamental_analysis import business_insider_view as biw from gamestonk_terminal.fundamental_analysis import ( financial_modeling_prep_controller as fmpc, + financial_modeling_prep_view as fmpv, ) from gamestonk_terminal.fundamental_analysis import finviz_view from gamestonk_terminal.fundamental_analysis import market_watch_view @@ -26,6 +27,7 @@ class FundamentalAnalysisController: "help", "q", "quit", + "score", "screener", "income", "balance", @@ -83,6 +85,9 @@ class FundamentalAnalysisController: print("") print(" screener screen info about the company [Finviz]") print(" mgmt management team of the company [Business Insider]") + print( + " score investing score from Warren Buffett, Joseph Piotroski and Benjamin Graham [FMP]" + ) print("") print("Market Watch API") print(" income income statement of the company") @@ -137,6 +142,10 @@ class FundamentalAnalysisController: """ Process screener command """ finviz_view.screener(other_args, self.ticker) + def call_score(self, other_args: List[str]): + """ Process score command """ + fmpv.valinvest_score(other_args, self.ticker) + def call_income(self, other_args: List[str]): """ Process income command """ market_watch_view.income(other_args, self.ticker) diff --git a/gamestonk_terminal/fundamental_analysis/financial_modeling_prep_view.py b/gamestonk_terminal/fundamental_analysis/financial_modeling_prep_view.py index 68e22a86281..f5bda9f8a17 100644 --- a/gamestonk_terminal/fundamental_analysis/financial_modeling_prep_view.py +++ b/gamestonk_terminal/fundamental_analysis/financial_modeling_prep_view.py @@ -5,6 +5,7 @@ import argparse from typing import List from datetime import datetime import pandas as pd +import valinvest import FundamentalAnalysis as fa # Financial Modeling Prep from gamestonk_terminal import config_terminal as cfg from gamestonk_terminal.dataframe_helpers import clean_df_index @@ -15,6 +16,40 @@ from gamestonk_terminal.helper_funcs import ( ) +def valinvest_score(other_args: List[str], ticker: str): + """Value investing tool based on Warren Buffett, Joseph Piotroski and Benjamin Graham thoughts [Source: FMP] + + Parameters + ---------- + other_args : List[str] + argparse other args + ticker : str + Fundamental analysis ticker symbol + """ + + parser = argparse.ArgumentParser( + add_help=False, + prog="score", + description=""" + Value investing tool based on Warren Buffett, Joseph Piotroski and Benjamin Graham thoughts [Source: FMP] + """, + ) + + try: + ns_parser = parse_known_args_and_warn(parser, other_args) + if not ns_parser: + return + + valstock = valinvest.Fundamental(ticker, cfg.API_KEY_FINANCIALMODELINGPREP) + score = 100 * (valstock.fscore() / 9) + print(f"Score: {score:.2f}".rstrip("0").rstrip(".") + " %") + print("") + + except Exception as e: + print(e, "\n") + return + + def profile(other_args: List[str], ticker: str): """Financial Modeling Prep ticker profile diff --git a/poetry.lock b/poetry.lock index a5b4f1f7f8e..d232c41a1fd 100644 --- a/poetry.lock +++ b/poetry.lock @@ -2837,6 +2837,14 @@ python-versions = "*" [package.dependencies] six = "*" +[[package]] +name = "valinvest" +version = "0.0.2" +description = "A value investing tool based on Warren Buffett, Joseph Piotroski and Benjamin Graham thoughts" +category = "main" +optional = false +python-versions = ">=3.6" + [[package]] name = "wcwidth" version = "0.2.5" @@ -2962,7 +2970,7 @@ prediction = ["fbprophet", "tensorflow", "pmdarima", "transformers", "flair", "t [metadata] lock-version = "1.1" python-versions = "^3.6.8" -content-hash = "2b31cd4c709b83d1a6f1d516036c84dc611cc487ae5d499905658454fa8dba40" +content-hash = "2088d5cb7d1789cabe8d0f0f211ec599f56e630b4997527b9838d3ecf517f04c" [metadata.files] absl-py = [ @@ -3295,51 +3303,30 @@ entrypoints = [ ] ephem = [ {file = "ephem-3.7.7.1-cp27-cp27m-macosx_10_6_intel.whl", hash = "sha256:0a6d6ed003383f702695094399728052981c567d423b25aa7163b3fd40de3d5a"}, - {file = "ephem-3.7.7.1-cp27-cp27m-macosx_10_9_x86_64.whl", hash = "sha256:3cbc4f643329c4f64de63584e636625fa9f11b50209386ed99cbf508abe19488"}, {file = "ephem-3.7.7.1-cp27-cp27m-manylinux2010_i686.whl", hash = "sha256:e73b9997d7b844fabff988d7f66c3bad4e76ec8975ec9c60ec988037bb5c04b1"}, {file = "ephem-3.7.7.1-cp27-cp27m-manylinux2010_x86_64.whl", hash = "sha256:7619297a1103f6b3dac0c609bfa7c31e17678fb1a02653347ec030487e412031"}, - {file = "ephem-3.7.7.1-cp27-cp27m-win32.whl", hash = "sha256:7756218a8b72ca50ee4f290b80828073412e7d7023389df5ead5d14839175bda"}, - {file = "ephem-3.7.7.1-cp27-cp27m-win_amd64.whl", hash = "sha256:b8f9fb5b4184523b98f6629c6c927aeeba80d61df21f07af2844cdae45e1a294"}, {file = "ephem-3.7.7.1-cp27-cp27mu-manylinux2010_i686.whl", hash = "sha256:37fd1abbebb821381d2865064a6fa9484ffdcd2161cf92193da8d42da79aa7db"}, {file = "ephem-3.7.7.1-cp27-cp27mu-manylinux2010_x86_64.whl", hash = "sha256:ff4e1584cc232d8bc4aea405346eeb8a24b0fbe84c6331d4edb5d4456d19f1c3"}, {file = "ephem-3.7.7.1-cp35-cp35m-macosx_10_6_intel.whl", hash = "sha256:c6081a9791e9de6511cddbeb9529bd5550fdb6f9e2a8dc9c2ec85911d67c6d11"}, - {file = "ephem-3.7.7.1-cp35-cp35m-macosx_10_9_x86_64.whl", hash = "sha256:d1d1ac8dc9be47dc6c7ec62800ca6557d03e8be3716c2a10ea0c8f1198c0a701"}, {file = "ephem-3.7.7.1-cp35-cp35m-manylinux2010_i686.whl", hash = "sha256:7f781d73e49caf7989c503a948471f1c8c1f738a450d557413999fb732f4dba3"}, {file = "ephem-3.7.7.1-cp35-cp35m-manylinux2010_x86_64.whl", hash = "sha256:f0959882bf73c8fe1cb801f42b0989e0ecb9d84b99eb8b8f70d61d16767a1e8a"}, - {file = "ephem-3.7.7.1-cp35-cp35m-manylinux2014_aarch64.whl", hash = "sha256:06029db6b26f1764ed009360de8530f6cd759411232b3001df1b69ba6afa871d"}, - {file = "ephem-3.7.7.1-cp35-cp35m-manylinux2014_s390x.whl", hash = "sha256:562baaeb3a46cf2248f97d2ad80092d747024e5dea62ebe50386a04b8e506c10"}, {file = "ephem-3.7.7.1-cp35-cp35m-win32.whl", hash = "sha256:2bcd953cced045e4232bcb71d60f6ba237f7944c880e83e74cc959449b192dee"}, {file = "ephem-3.7.7.1-cp35-cp35m-win_amd64.whl", hash = "sha256:fd0b922387df1ad8721f2fafd5dca51ce7105238f968e1532a177b781b8cae0e"}, {file = "ephem-3.7.7.1-cp36-cp36m-macosx_10_6_intel.whl", hash = "sha256:e10c2c8afbb9e927d46d9bf3562441da2173ff196790a75ad0e5c5ee920d5922"}, - {file = "ephem-3.7.7.1-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:592264e512b5658402e93903343eb26502c6f327df8a71847f3dcaea73908f32"}, {file = "ephem-3.7.7.1-cp36-cp36m-manylinux2010_i686.whl", hash = "sha256:8d586d970c42d62b1fc757a1c7c10679416a43e9e4a77391a05907159ce346f8"}, {file = "ephem-3.7.7.1-cp36-cp36m-manylinux2010_x86_64.whl", hash = "sha256:1a8ea6a045ff669011f8ecdeffadfc5eaa519fb56ab8dd40508910e9db5ec7b0"}, - {file = "ephem-3.7.7.1-cp36-cp36m-manylinux2014_aarch64.whl", hash = "sha256:c25993d6554820ff11fdd8f2ddb75bf99e70db01327f09700bf8811201e9daef"}, - {file = "ephem-3.7.7.1-cp36-cp36m-manylinux2014_s390x.whl", hash = "sha256:9180d953ff4cbe89fc9ccc78aea73f290c0166b8ddb01e9c837b4639a7492ec8"}, {file = "ephem-3.7.7.1-cp36-cp36m-win32.whl", hash = "sha256:72fdb72c813fc9780726aa732eb2193bbe1663549265ca5a746899215ecfbffd"}, {file = "ephem-3.7.7.1-cp36-cp36m-win_amd64.whl", hash = "sha256:f5af029f8814aa8617e73b2ddcad2bd1c682ca13c31ee3b6f5825dd5cb43e777"}, {file = "ephem-3.7.7.1-cp37-cp37m-macosx_10_6_intel.whl", hash = "sha256:e61c68f1c7d304a130bb6b88c1fca6600bbc1a1df6ca9a109b6eba4c6cbd3376"}, - {file = "ephem-3.7.7.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:fdf5f3ed8bd46ce2bf1145b26aec65a2c08ea7c97cf42b6b439af6e7bc6dc94d"}, {file = "ephem-3.7.7.1-cp37-cp37m-manylinux2010_i686.whl", hash = "sha256:31e2a17ca6f8d6bd44832574fea5461938ba034e52bf551e15e1a4c8f8c6c4fb"}, {file = "ephem-3.7.7.1-cp37-cp37m-manylinux2010_x86_64.whl", hash = "sha256:1ff5abefa230d5ab40846f1cb27d4f5583d46044fecf10e17bfb559bdc766a47"}, - {file = "ephem-3.7.7.1-cp37-cp37m-manylinux2014_aarch64.whl", hash = "sha256:5ef34e3cfea0683998e867d7b8de642081e8821fafbd5e1d2dcab503c119c4a2"}, - {file = "ephem-3.7.7.1-cp37-cp37m-manylinux2014_s390x.whl", hash = "sha256:e2aca9edb59ee2bb3c8c36f17177966bc762da04af994450c8ad61a20fb6acdd"}, {file = "ephem-3.7.7.1-cp37-cp37m-win32.whl", hash = "sha256:71ea3935c658ee184575fd4cc2aa3e7fd6d6bac4a1ccff9ee5549cee67ff0385"}, {file = "ephem-3.7.7.1-cp37-cp37m-win_amd64.whl", hash = "sha256:34fd228105b89fefd20608420861a75a184db1edeaf0056cf2f85d2a2f768aee"}, {file = "ephem-3.7.7.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:189fcaeacb44dc5a1684ad489542f126d99d4a85e87d2fe73864c902f0bc2c71"}, {file = "ephem-3.7.7.1-cp38-cp38-manylinux2010_i686.whl", hash = "sha256:a5ddf46ced515e4b81dfd22e6408fd06a329c31c6abb10af48d392641c490b0e"}, {file = "ephem-3.7.7.1-cp38-cp38-manylinux2010_x86_64.whl", hash = "sha256:3530bee3eb7458d86d4c399f51f5b73ad7ea0441f0b2fb03de41d623789935af"}, - {file = "ephem-3.7.7.1-cp38-cp38-manylinux2014_aarch64.whl", hash = "sha256:77193de077e5fff453756144dee978e5fd6978c5c03ce3f67a09bb237e78f9d4"}, - {file = "ephem-3.7.7.1-cp38-cp38-manylinux2014_s390x.whl", hash = "sha256:095ad42e8df6a5c91e0aeb5a68d76c0800b0283f72fc5f76e6df370ae1fb5537"}, {file = "ephem-3.7.7.1-cp38-cp38-win32.whl", hash = "sha256:33ad1a71b204aff123250b04e0ff2d5c3b8e9c6c814bf2c675d7752ce5896c02"}, {file = "ephem-3.7.7.1-cp38-cp38-win_amd64.whl", hash = "sha256:4bc5140cc7218a53ee6d949110f6ed413b8e3165294100515cd0fb29aa8e3637"}, - {file = "ephem-3.7.7.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:7aa88d2a6d216c2044be2a3b3cb184e9c8a5022f12464220694017ea9d75209d"}, - {file = "ephem-3.7.7.1-cp39-cp39-manylinux2010_i686.whl", hash = "sha256:1a9822bde93205c67fd3399b26868204b67d9e4442af21a764307e51ea6dc672"}, - {file = "ephem-3.7.7.1-cp39-cp39-manylinux2010_x86_64.whl", hash = "sha256:15dd3dbb3864fb853388e39ac3c915c72873507f54ee6b3ede0033b03465d8ba"}, - {file = "ephem-3.7.7.1-cp39-cp39-manylinux2014_aarch64.whl", hash = "sha256:5763919cdf38cd0488172711da504c3be003b7c104ccd2516cc496ff05f146ae"}, - {file = "ephem-3.7.7.1-cp39-cp39-manylinux2014_s390x.whl", hash = "sha256:cdea23a7caa1178b322e6e76484d40bd021672446ff51b512f35581e0f1b32b7"}, - {file = "ephem-3.7.7.1-cp39-cp39-win32.whl", hash = "sha256:c3cbc973b334892972445cec3deb99aafd0c57cb4e50679d5f12fc8c51b4e65f"}, - {file = "ephem-3.7.7.1-cp39-cp39-win_amd64.whl", hash = "sha256:1af920c382980fe3566a31f36bd712973e1ca6049cbe07b4624214d5e1f144bc"}, {file = "ephem-3.7.7.1.tar.gz", hash = "sha256:36b51a8dc7cfdeb456dd6b8ab811accab8341b2d562ee3c6f4c86f6d3dbb984e"}, ] fbprophet = [ @@ -4940,6 +4927,10 @@ urllib3 = [ user-agent = [ {file = "user_agent-0.1.9.tar.gz", hash = "sha256:8f1ad46cc4aef9f99515ea1c74bb8cacc43e23074c335b2ba2db7735ebe9c0d5"}, ] +valinvest = [ + {file = "valinvest-0.0.2-py3-none-any.whl", hash = "sha256:37fadaf30c69e0487fed8d9cc93bb792ca8cf36fed0839e0e755a84738166ab9"}, + {file = "valinvest-0.0.2.tar.gz", hash = "sha256:9614aaf8019e015c20ea48867ede8a6ea10e1c6410e787314066d7b2e5aeb7dc"}, +] wcwidth = [ {file = "wcwidth-0.2.5-py2.py3-none-any.whl", hash = "sha256:beb4802a9cebb9144e99086eff703a642a13d6a0052920003a230f3294bbe784"}, {file = "wcwidth-0.2.5.tar.gz", hash = "sha256:c4d647b99872929fdb7bdcaa4fbe7f01413ed3d98077df798530e5b04f116c83"}, diff --git a/pyproject.toml b/pyproject.toml index 45e9f245261..d0f9c731ebc 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -60,6 +60,7 @@ pyportfolioopt = "^1.4.1" selenium = "^3.141.0" python-coinmarketcap = "^0.2" oandapyV20 = "^0.6.3" +valinvest = "^0.0.2" [tool.poetry.dev-dependencies] pytest = "^6.2.2" diff --git a/requirements.txt b/requirements.txt index 15e7172d368..654cd4398b4 100644 --- a/requirements.txt +++ b/requirements.txt @@ -158,6 +158,7 @@ typing-extensions==3.7.4.3; python_version < "3.8" and python_version >= "3.6" update-checker==0.18.0; python_version >= "3.6" and python_version < "4.0" urllib3==1.26.4; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.5.0" and python_version < "4" and python_version >= "3.6" user-agent==0.1.9 +valinvest==0.0.2; python_version >= "3.6" wcwidth==0.2.5; python_version >= "3.6" and python_full_version >= "3.6.1" webencodings==0.5.1; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.5.0" and python_version >= "3.6" websocket-client==0.58.0; python_version >= "3.6" and python_full_version < "3.0.0" and python_version < "4.0" or python_version >= "3.6" and python_version < "4.0" and python_full_version >= "3.4.0" From cdeb2122dcdac79bf4fe4fffce7a5315c6bdbd38 Mon Sep 17 00:00:00 2001 From: DidierRLopes Date: Thu, 22 Apr 2021 22:24:48 +0100 Subject: [PATCH 03/11] Keep image resolution --- gamestonk_terminal/options/README.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/gamestonk_terminal/options/README.md b/gamestonk_terminal/options/README.md index 300574e5de9..7413f9a88aa 100644 --- a/gamestonk_terminal/options/README.md +++ b/gamestonk_terminal/options/README.md @@ -100,9 +100,10 @@ In order to run, the selenium webdriver must be installed. Currently, this runs on either Chrome or Firefox. The path to the driver should be defined in [config_terminal.py](#config_terminal.py). Note this may take more time than other commands to process. + ```` usage: info [-d DRIVER] ```` * -d/--driver : One of {chrome, firefox}. This indicates which driver you have installed. -![im](https://user-images.githubusercontent.com/18151143/115454584-efa83a00-a1ee-11eb-9d0f-2558ffa31579.png) \ No newline at end of file +opinfo From 1dcbb29b762cebb3eb69d1c36a057b2e898807bb Mon Sep 17 00:00:00 2001 From: DidierRLopes Date: Thu, 22 Apr 2021 22:31:00 +0100 Subject: [PATCH 04/11] Keep README in line with others --- gamestonk_terminal/cryptocurrency/README.md | 39 +++++++++------------ 1 file changed, 17 insertions(+), 22 deletions(-) diff --git a/gamestonk_terminal/cryptocurrency/README.md b/gamestonk_terminal/cryptocurrency/README.md index 78a1167ffbf..4a1b7b48fea 100644 --- a/gamestonk_terminal/cryptocurrency/README.md +++ b/gamestonk_terminal/cryptocurrency/README.md @@ -1,57 +1,52 @@ -# Cryptocurrency +# CRYPTOCURRENCY -This page gives an overview of the ability to load cryptocurrency data. - -Current crypto data is [Powered by CoinGecko API](#https://www.coingecko.com/en). -This is an awesome service that currently requires no API Key! - -Current functionality is aimed to be similar to loading a stock ticker. +This menu aims to explore crypto world, and the usage of the following commands along with an example will be exploited below. * [load](#load) + * load a given coin vs a given currency [CoinGecko] * [view](#view) + * plot the loaded crypto data * [top](#top) + * view top coins from coinmarketcap [coinmarketcap.com] + ## load -Load a given coin vs a given currency: ```` usage: load [-c --coin] [-d --days] [--vs] ```` + +Load a given coin vs a given currency. Currently only retrieves price, not volume or MarketCap. The current crypto data is [Powered by CoinGecko API](#https://www.coingecko.com/en), which is an awesome service that currently requires no API Key! + * -c/--coin The coin you wish to load. This can either be the symbol or the name. `load -c btc` and `load -c bitcoin` will load. The -c flag is optional, the above is equivalent to `load btc`. - * -d/--days The number of days to look. Defaults to 30 days. As per the API: Minutely data will be used for duration within 1 day, Hourly data will be used for duration between 1 day and 90 days, Daily data will be used for duration above 90 days. - * --vs The currency to look against. Defaults to "usd". -Currently only retrieves price, not volume or MarketCap. - -Example doge/eur for the past day: -```` -load -c doge -d 1 --vs eur -```` ## view -Plot the loaded crypto data. + ```` usage: view ```` -After loading the above 1 day dogecoin/eur. Running view plots the data: -![doge](https://user-images.githubusercontent.com/18151143/112690617-7832f500-8e52-11eb-84c4-253ab222a918.png) +Plot the loaded crypto data. + +![crypto_view](https://user-images.githubusercontent.com/25267873/115787452-20889a80-a3ba-11eb-9216-f7fd1ffc98cf.png) ## top -This command displays the top n cryptocurrencies from coinmarketcap.com. The list appears to be sorted by Mar ```` top [-n] [-s --sort SORTBY] [--descend] ```` + +This command displays the top n cryptocurrencies from coinmarketcap.com. + * -n: Number of coins to look at (after sort). Defaults to 10. * -s/--sort : Column to sort by. One of {Symbol,CMC_Rank,LastPrice,DayPctChange,MarketCap}. Defaults to sorting by the CMC rank. * --descend : Flag to change the sorting order. Sorts in ascending order (since default order is the Rank which starts at 1). -Example usage to get the CMC top 100, then show the top 4 highest Percent Day Change +crypto -![im](https://user-images.githubusercontent.com/18151143/115587223-6bf85700-a29b-11eb-9d96-cb4239b7c2d0.png) From 3cb643dbff1009b5b2824f754376698961b3ecc0 Mon Sep 17 00:00:00 2001 From: DidierRLopes Date: Thu, 22 Apr 2021 22:35:16 +0100 Subject: [PATCH 05/11] Add forex to ROADMAP --- ROADMAP.md | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/ROADMAP.md b/ROADMAP.md index ee6fca45d7e..eed825916c6 100644 --- a/ROADMAP.md +++ b/ROADMAP.md @@ -20,6 +20,7 @@ * [Credit Analysis](#Credit-Analysis) * [Cryptocurrencies](#Cryptocurrencies) * [Screener](#Screener) +* [Forex](#Forex) ## Additional @@ -63,6 +64,7 @@ ## Fundamental Analysis * [x] Rearrange FA menu to have AV and FMP as submenus (@didier) - [PR #166](https://github.com/DidierRLopes/GamestonkTerminal/pull/166) +* [x] Add Fundamental Analysis score (@didier) - [PR #383](https://github.com/DidierRLopes/GamestonkTerminal/pull/383) **NEXT** * [ ] Add Treasury Yield Curve data (@aia) - [PR #281](https://github.com/DidierRLopes/GamestonkTerminal/pull/281) @@ -209,6 +211,13 @@ ___ --- +## Forex +* [x] Add entire forex menu through Oanda (@alokan) - [PR #360](https://github.com/DidierRLopes/GamestonkTerminal/pull/360) + +**NEXT** + +--- + ## Backend **NEXT** From d9abafb2cae15a26a2c02949319c7846eb3b80db Mon Sep 17 00:00:00 2001 From: DidierRLopes Date: Thu, 22 Apr 2021 22:39:03 +0100 Subject: [PATCH 06/11] add fa-score readme --- gamestonk_terminal/fundamental_analysis/README.md | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/gamestonk_terminal/fundamental_analysis/README.md b/gamestonk_terminal/fundamental_analysis/README.md index 5c2c114b0ce..914675970e5 100644 --- a/gamestonk_terminal/fundamental_analysis/README.md +++ b/gamestonk_terminal/fundamental_analysis/README.md @@ -6,7 +6,9 @@ This menu aims to extract all fundamentals of a pre-loaded company, and the usag * screen info about the company [Finviz] * [mgmt](#mgmt) * management team of the company [Business Insider] - +* [score](#score) + * investing score from Warren Buffett, Joseph Piotroski and Benjamin Graham [FMP] + [MARKET WATCH](#MARKET_WATCH) * [income](#income) @@ -323,3 +325,12 @@ Prints the growth of several financial statement items and ratios over time. Thi * n : Number of latest years/quarters. Default 1. * q : Quarter fundamental data flag. Default False. + + +### score + +```text +usage: score +``` + +Value investing tool based on Warren Buffett, Joseph Piotroski and Benjamin Graham thoughts [Source: Financial Modeling Prep] From 4792aa698b0deb6495d2bacce2ac843fdd473d83 Mon Sep 17 00:00:00 2001 From: DidierRLopes Date: Thu, 22 Apr 2021 22:41:38 +0100 Subject: [PATCH 07/11] Update features readme --- gamestonk_terminal/README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/gamestonk_terminal/README.md b/gamestonk_terminal/README.md index 83f8c8b9402..49ae1f6510d 100644 --- a/gamestonk_terminal/README.md +++ b/gamestonk_terminal/README.md @@ -145,6 +145,7 @@ Command|Description ----- | --------- `screener` |screen info about the company ([Finviz](https://finviz.com/)) `mgmt` |management team of the company ([Business Insider](https://markets.businessinsider.com/)) +`score` |investing score from Warren Buffett, Joseph Piotroski and Benjamin Graham ([FMP](https://financialmodelingprep.com/)) [Market Watch API](https://markets.businessinsider.com/) | `income` |income statement of the company `balance` |balance sheet of the company @@ -272,6 +273,7 @@ Command|Description ------ | ------------ `load`| load cryptocurrency data `view`| load and view cryptocurrency data +`top` | view top coins from coinmarketcap   ## Comparison Analysis [»](comparison_analysis/README.md) From d1874bdbe074e622bf78955ecce2619b8e3ee328 Mon Sep 17 00:00:00 2001 From: DidierRLopes Date: Thu, 22 Apr 2021 22:45:32 +0100 Subject: [PATCH 08/11] Add Forex to features readme --- gamestonk_terminal/README.md | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/gamestonk_terminal/README.md b/gamestonk_terminal/README.md index 49ae1f6510d..211b0a008e7 100644 --- a/gamestonk_terminal/README.md +++ b/gamestonk_terminal/README.md @@ -17,6 +17,7 @@ * [FRED](#FRED-) * [Options](#Options-) * [Screener](#Screener-) +* [Forex](#Forex-) ## Main @@ -366,5 +367,26 @@ performance |performance (e.g. Perf Week, Perf YTD, Volatility M) technical |technical (e.g. Beta, SMA50, 52W Low, RSI, Change) signals |view filter signals (e.g. -s top_gainers) +  + + +## Forex [»](forex/README.md) +Command|Description +------ | -------- +summary |display a summary of your account +calendar |get information about past or upcoming events which may impact the price +list |list your order history +pending |get information about pending orders +cancel |cancel a pending order by ID +positions |get information about your positions +trades |see a list of open trades +closetrade |close a trade by ID +load |specify an instrument to use +candles |get a candlestick chart for the forex instrument +price |show the current price for the forex instrument +order |place a limit order +orderbook |display the orderbook if Oanda provides one for the forex instrument +positionbook |display the positionbook if Oanda provides one for the forex instrument +   From d76c5437add636bfc8666383c437e7307c01681d Mon Sep 17 00:00:00 2001 From: didier Date: Thu, 22 Apr 2021 22:52:12 +0100 Subject: [PATCH 09/11] Fix op/info command, although browser needs to pop up --- gamestonk_terminal/options/op_scrape_view.py | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/gamestonk_terminal/options/op_scrape_view.py b/gamestonk_terminal/options/op_scrape_view.py index 40bb5e1e0f9..7b9ee996fdf 100644 --- a/gamestonk_terminal/options/op_scrape_view.py +++ b/gamestonk_terminal/options/op_scrape_view.py @@ -63,14 +63,16 @@ def print_options_data(stock: str, other_args: List[str]): try: if browser == "chrome": - options = cOpts() - options.headless = True - driver = webdriver.Chrome(options=options, executable_path=path_to_driver) + # commenting this because it breaks when in usage + # the downside is that the browser will pop up to get the data + driver = webdriver.Chrome(executable_path=path_to_driver) elif browser == "firefox": - options = fOpts() - options.headless = True - driver = webdriver.Firefox(options=options, executable_path=path_to_driver) + # commenting this because it breaks when in usage + # the downside is that the browser will pop up to get the data + #options = fOpts() + #options.headless = True + driver = webdriver.Firefox(executable_path=path_to_driver) page = f"https://www.barchart.com/stocks/quotes/{stock}/overview" driver.get(page) From a105fc829dc23b68781d38f1595ae382a4737bce Mon Sep 17 00:00:00 2001 From: DidierRLopes Date: Thu, 22 Apr 2021 22:55:49 +0100 Subject: [PATCH 10/11] Update ROADMAP.md --- ROADMAP.md | 1 + 1 file changed, 1 insertion(+) diff --git a/ROADMAP.md b/ROADMAP.md index eed825916c6..5242e32bfb3 100644 --- a/ROADMAP.md +++ b/ROADMAP.md @@ -192,6 +192,7 @@ ___ ## Cryptocurrencies * [x] Add Coingecko (@jmaslek) - [PR #283](#https://github.com/DidierRLopes/GamestonkTerminal/pull/283) +* [x] view top coins from coinmarketcap (@jmaslek) - [PR #378](https://github.com/DidierRLopes/GamestonkTerminal/pull/378) **NEXT** * [ ] Add [Coinpaprika](https://coinpaprika.com/api/) From 0c9e1a29f83cc771e9003323e848761fbe68da37 Mon Sep 17 00:00:00 2001 From: didier Date: Thu, 22 Apr 2021 22:57:22 +0100 Subject: [PATCH 11/11] Black fix --- gamestonk_terminal/options/op_scrape_view.py | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/gamestonk_terminal/options/op_scrape_view.py b/gamestonk_terminal/options/op_scrape_view.py index 7b9ee996fdf..dbf5459181f 100644 --- a/gamestonk_terminal/options/op_scrape_view.py +++ b/gamestonk_terminal/options/op_scrape_view.py @@ -5,8 +5,9 @@ import argparse from typing import List from selenium import webdriver from bs4 import BeautifulSoup -from selenium.webdriver.chrome.options import Options as cOpts -from selenium.webdriver.firefox.options import Options as fOpts + +# from selenium.webdriver.chrome.options import Options as cOpts +# from selenium.webdriver.firefox.options import Options as fOpts import pandas as pd from tabulate import tabulate from gamestonk_terminal.config_terminal import ( @@ -65,13 +66,15 @@ def print_options_data(stock: str, other_args: List[str]): if browser == "chrome": # commenting this because it breaks when in usage # the downside is that the browser will pop up to get the data + # options = cOpts() + # options.headless = True driver = webdriver.Chrome(executable_path=path_to_driver) elif browser == "firefox": # commenting this because it breaks when in usage # the downside is that the browser will pop up to get the data - #options = fOpts() - #options.headless = True + # options = fOpts() + # options.headless = True driver = webdriver.Firefox(executable_path=path_to_driver) page = f"https://www.barchart.com/stocks/quotes/{stock}/overview"