From 7877ec8708f93e062d633654e33e764be2016983 Mon Sep 17 00:00:00 2001 From: Dave Skender <8432125+DaveSkender@users.noreply.github.com> Date: Mon, 1 Apr 2024 21:43:04 -0400 Subject: [PATCH 01/13] add quickstart blurb --- docs/pages/guide.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/docs/pages/guide.md b/docs/pages/guide.md index f10007f1..c5fd354d 100644 --- a/docs/pages/guide.md +++ b/docs/pages/guide.md @@ -47,6 +47,8 @@ layout: page > See [Python documentation](https://packaging.python.org/en/latest/tutorials/installing-packages/) for more help with installing packages. +>🚩 If you're still having trouble getting started, see our [QuickStart guide](https://github.com/DaveSkender/Stock.Indicators.Python.QuickStart#readme) for step-by-step instructions for setting up your environment and for calculating your first indicator using this library. + ### Prerequisite data Most indicators require that you provide historical quote data and additional configuration parameters. From 9714cde8bcd25e0a427fa0c1b10b6cc2df045b23 Mon Sep 17 00:00:00 2001 From: Dave Skender <8432125+DaveSkender@users.noreply.github.com> Date: Mon, 1 Apr 2024 23:18:42 -0400 Subject: [PATCH 02/13] ignore hash in html proofer --- .github/workflows/test-docs-links.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/test-docs-links.yml b/.github/workflows/test-docs-links.yml index 94d41980..89380644 100644 --- a/.github/workflows/test-docs-links.yml +++ b/.github/workflows/test-docs-links.yml @@ -68,6 +68,7 @@ jobs: run: | htmlproofer _site \ --no-enforce-https \ + --allow_hash_href \ --ignore-status-codes "0,302,403,406,408,429,503,999" \ --swap-urls "https\://python.stockindicators.dev:http\://127.0.0.1:4000" \ --ignore-urls "/fonts.gstatic.com/" From 60742e40fb5d9dcf454921dc26f6b6a5a62f8686 Mon Sep 17 00:00:00 2001 From: Dave Skender <8432125+DaveSkender@users.noreply.github.com> Date: Mon, 1 Apr 2024 23:31:32 -0400 Subject: [PATCH 03/13] correct flag --- .github/workflows/test-docs-links.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test-docs-links.yml b/.github/workflows/test-docs-links.yml index 89380644..b1e62733 100644 --- a/.github/workflows/test-docs-links.yml +++ b/.github/workflows/test-docs-links.yml @@ -68,7 +68,7 @@ jobs: run: | htmlproofer _site \ --no-enforce-https \ - --allow_hash_href \ + --check_external_hash false \ --ignore-status-codes "0,302,403,406,408,429,503,999" \ --swap-urls "https\://python.stockindicators.dev:http\://127.0.0.1:4000" \ --ignore-urls "/fonts.gstatic.com/" From 6268efb079257b54cc71240633ed7d7dbf3973ad Mon Sep 17 00:00:00 2001 From: Dave Skender <8432125+DaveSkender@users.noreply.github.com> Date: Tue, 2 Apr 2024 02:13:45 -0400 Subject: [PATCH 04/13] tweak --- .github/workflows/test-docs-links.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test-docs-links.yml b/.github/workflows/test-docs-links.yml index b1e62733..33dc3f94 100644 --- a/.github/workflows/test-docs-links.yml +++ b/.github/workflows/test-docs-links.yml @@ -68,7 +68,7 @@ jobs: run: | htmlproofer _site \ --no-enforce-https \ - --check_external_hash false \ + --check_external_hash=false \ --ignore-status-codes "0,302,403,406,408,429,503,999" \ --swap-urls "https\://python.stockindicators.dev:http\://127.0.0.1:4000" \ --ignore-urls "/fonts.gstatic.com/" From 196b413112617f82775b4c093a682a4ce002c788 Mon Sep 17 00:00:00 2001 From: Dave Skender <8432125+DaveSkender@users.noreply.github.com> Date: Tue, 2 Apr 2024 02:48:03 -0400 Subject: [PATCH 05/13] update packages --- .github/workflows/test-docs-links.yml | 7 +++++++ docs/GemFile.lock | 14 ++++++-------- 2 files changed, 13 insertions(+), 8 deletions(-) diff --git a/.github/workflows/test-docs-links.yml b/.github/workflows/test-docs-links.yml index 33dc3f94..ff8188c6 100644 --- a/.github/workflows/test-docs-links.yml +++ b/.github/workflows/test-docs-links.yml @@ -63,6 +63,13 @@ jobs: BUNDLE_GEMFILE: ${{github.workspace}}/docs/GemFile run: bundle exec jekyll serve --detach + - name: HTML Proofer help + working-directory: docs + run: htmlproofer --help + + # reminder, to get args info: + # gem install html-proofer + # htmlproofer --help - name: Test for broken URLs working-directory: docs run: | diff --git a/docs/GemFile.lock b/docs/GemFile.lock index 0367df37..a8e9f95a 100644 --- a/docs/GemFile.lock +++ b/docs/GemFile.lock @@ -21,7 +21,7 @@ GEM addressable (2.8.6) public_suffix (>= 2.0.2, < 6.0) base64 (0.2.0) - bigdecimal (3.1.6) + bigdecimal (3.1.7) coffee-script (2.4.1) coffee-script-source execjs @@ -31,10 +31,9 @@ GEM concurrent-ruby (1.2.3) connection_pool (2.4.1) cssminify2 (2.0.1) - dnsruby (1.70.0) + dnsruby (1.72.0) simpleidn (~> 0.2.1) - drb (2.2.0) - ruby2_keywords + drb (2.2.1) em-websocket (0.5.3) eventmachine (>= 0.12.9) http_parser.rb (~> 0) @@ -106,7 +105,7 @@ GEM nokogiri (>= 1.4) htmlcompressor (0.4.0) http_parser.rb (0.8.0) - i18n (1.14.1) + i18n (1.14.4) concurrent-ruby (~> 1.0) jekyll (3.9.5) addressable (~> 2.4) @@ -242,11 +241,11 @@ GEM jekyll (>= 3.5, < 5.0) jekyll-feed (~> 0.9) jekyll-seo-tag (~> 2.1) - minitest (5.22.2) + minitest (5.22.3) mutex_m (0.2.0) net-http (0.4.1) uri - nokogiri (1.16.2) + nokogiri (1.16.3) mini_portile2 (~> 2.8.2) racc (~> 1.4) octokit (4.25.1) @@ -262,7 +261,6 @@ GEM ffi (~> 1.0) rexml (3.2.6) rouge (3.30.0) - ruby2_keywords (0.0.5) rubyzip (2.3.2) safe_yaml (1.0.5) sass (3.7.4) From a447d49774256aff0ed27a178a5268e9fd9d40dd Mon Sep 17 00:00:00 2001 From: Dave Skender <8432125+DaveSkender@users.noreply.github.com> Date: Tue, 2 Apr 2024 02:52:04 -0400 Subject: [PATCH 06/13] tweak --- .github/workflows/test-docs-links.yml | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/.github/workflows/test-docs-links.yml b/.github/workflows/test-docs-links.yml index ff8188c6..74dc6d67 100644 --- a/.github/workflows/test-docs-links.yml +++ b/.github/workflows/test-docs-links.yml @@ -35,7 +35,9 @@ jobs: bundle install - name: Setup HTML Proofer - run: gem install html-proofer + run: | + gem install html-proofer + htmlproofer --help - name: Replace "data-src" uses: jacobtomlinson/gha-find-replace@v3 @@ -63,19 +65,13 @@ jobs: BUNDLE_GEMFILE: ${{github.workspace}}/docs/GemFile run: bundle exec jekyll serve --detach - - name: HTML Proofer help - working-directory: docs - run: htmlproofer --help - - # reminder, to get args info: - # gem install html-proofer - # htmlproofer --help + # see help in setup step - name: Test for broken URLs working-directory: docs run: | htmlproofer _site \ --no-enforce-https \ - --check_external_hash=false \ + --allow-hash-href \ --ignore-status-codes "0,302,403,406,408,429,503,999" \ --swap-urls "https\://python.stockindicators.dev:http\://127.0.0.1:4000" \ --ignore-urls "/fonts.gstatic.com/" From 9234494f05489c301a6fbb72149a16c2e91f553a Mon Sep 17 00:00:00 2001 From: Dave Skender <8432125+DaveSkender@users.noreply.github.com> Date: Tue, 2 Apr 2024 03:00:04 -0400 Subject: [PATCH 07/13] tweak --- .github/workflows/test-docs-links.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test-docs-links.yml b/.github/workflows/test-docs-links.yml index 74dc6d67..ed1a9fa4 100644 --- a/.github/workflows/test-docs-links.yml +++ b/.github/workflows/test-docs-links.yml @@ -71,7 +71,7 @@ jobs: run: | htmlproofer _site \ --no-enforce-https \ - --allow-hash-href \ + --no-check-external-hash \ --ignore-status-codes "0,302,403,406,408,429,503,999" \ --swap-urls "https\://python.stockindicators.dev:http\://127.0.0.1:4000" \ --ignore-urls "/fonts.gstatic.com/" From cd692f4069fcae64a37dd287b629d081c27ec54d Mon Sep 17 00:00:00 2001 From: Dave Skender <8432125+DaveSkender@users.noreply.github.com> Date: Tue, 2 Apr 2024 03:21:30 -0400 Subject: [PATCH 08/13] tweak --- docs/pages/guide.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/pages/guide.md b/docs/pages/guide.md index c5fd354d..ac81d224 100644 --- a/docs/pages/guide.md +++ b/docs/pages/guide.md @@ -47,7 +47,8 @@ layout: page > See [Python documentation](https://packaging.python.org/en/latest/tutorials/installing-packages/) for more help with installing packages. ->🚩 If you're still having trouble getting started, see our [QuickStart guide](https://github.com/DaveSkender/Stock.Indicators.Python.QuickStart#readme) for step-by-step instructions for setting up your environment and for calculating your first indicator using this library. +> [!INFO] +> If you're still having trouble getting started, see our [QuickStart guide](https://github.com/DaveSkender/Stock.Indicators.Python.QuickStart#readme) for step-by-step instructions for setting up your environment and for calculating your first indicator using this library. ### Prerequisite data From 336acb7aa5bff2d01842136733cba30685166c90 Mon Sep 17 00:00:00 2001 From: Dave Skender <8432125+DaveSkender@users.noreply.github.com> Date: Tue, 2 Apr 2024 03:22:33 -0400 Subject: [PATCH 09/13] change to tip-type --- docs/pages/guide.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/pages/guide.md b/docs/pages/guide.md index ac81d224..5521956c 100644 --- a/docs/pages/guide.md +++ b/docs/pages/guide.md @@ -47,7 +47,7 @@ layout: page > See [Python documentation](https://packaging.python.org/en/latest/tutorials/installing-packages/) for more help with installing packages. -> [!INFO] +> [!TIP] > If you're still having trouble getting started, see our [QuickStart guide](https://github.com/DaveSkender/Stock.Indicators.Python.QuickStart#readme) for step-by-step instructions for setting up your environment and for calculating your first indicator using this library. ### Prerequisite data From 14c1ff6fe63a98c501ae6a6b461dcb81fc9354fc Mon Sep 17 00:00:00 2001 From: Dave Skender <8432125+DaveSkender@users.noreply.github.com> Date: Tue, 2 Apr 2024 03:23:59 -0400 Subject: [PATCH 10/13] use note type; okay, I'm done changing it, for real --- docs/pages/guide.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/pages/guide.md b/docs/pages/guide.md index 5521956c..f701b5d6 100644 --- a/docs/pages/guide.md +++ b/docs/pages/guide.md @@ -47,7 +47,7 @@ layout: page > See [Python documentation](https://packaging.python.org/en/latest/tutorials/installing-packages/) for more help with installing packages. -> [!TIP] +> [!NOTE] > If you're still having trouble getting started, see our [QuickStart guide](https://github.com/DaveSkender/Stock.Indicators.Python.QuickStart#readme) for step-by-step instructions for setting up your environment and for calculating your first indicator using this library. ### Prerequisite data From af2f3d7caf69c951d466367a0a4b222fbddc24b8 Mon Sep 17 00:00:00 2001 From: Dave Skender <8432125+DaveSkender@users.noreply.github.com> Date: Tue, 2 Apr 2024 03:40:53 -0400 Subject: [PATCH 11/13] last one ... --- docs/pages/guide.md | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/docs/pages/guide.md b/docs/pages/guide.md index f701b5d6..ca6c5da3 100644 --- a/docs/pages/guide.md +++ b/docs/pages/guide.md @@ -29,7 +29,7 @@ layout: page Check that you've installed the following prerequisite software: - > Install the latest **Python** and **.NET SDK** for best performance. + > Install **Python** and the **.NET SDK**. Use the latest versions for better performance. | Installer | Min | Latest | Download | |---| :---: | :---: | --- | @@ -41,14 +41,16 @@ layout: page 2. Find and install the **stock-indicators** Python package into your environment. ```bash - # pip example + # bash CLI command pip install stock-indicators ``` > See [Python documentation](https://packaging.python.org/en/latest/tutorials/installing-packages/) for more help with installing packages. - -> [!NOTE] -> If you're still having trouble getting started, see our [QuickStart guide](https://github.com/DaveSkender/Stock.Indicators.Python.QuickStart#readme) for step-by-step instructions for setting up your environment and for calculating your first indicator using this library. + > + > **More help**: if you're still having trouble getting started, see our + > **[QuickStart guide](https://github.com/DaveSkender/Stock.Indicators.Python.QuickStart#readme)** + > for step-by-step instructions to setup up your environment, + > and for calculating your first indicator using this library. ### Prerequisite data From 24f19d37b50409fe348206b112fcd10110f08d1f Mon Sep 17 00:00:00 2001 From: Dave Skender <8432125+DaveSkender@users.noreply.github.com> Date: Tue, 2 Apr 2024 04:10:48 -0400 Subject: [PATCH 12/13] i'm just going to merge this so I stop changing it --- docs/pages/guide.md | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/docs/pages/guide.md b/docs/pages/guide.md index ca6c5da3..f5b7d0cb 100644 --- a/docs/pages/guide.md +++ b/docs/pages/guide.md @@ -46,11 +46,11 @@ layout: page ``` > See [Python documentation](https://packaging.python.org/en/latest/tutorials/installing-packages/) for more help with installing packages. - > - > **More help**: if you're still having trouble getting started, see our - > **[QuickStart guide](https://github.com/DaveSkender/Stock.Indicators.Python.QuickStart#readme)** - > for step-by-step instructions to setup up your environment, - > and for calculating your first indicator using this library. + +> **More help**: if you're still having trouble getting started, see our +> **[QuickStart guide](https://github.com/DaveSkender/Stock.Indicators.Python.QuickStart#readme)** +> for step-by-step instructions to setup up your environment, +> and for calculating your first indicator using this library. ### Prerequisite data @@ -123,9 +123,6 @@ Note that: 1. `date` is always required, while each ohlcv values are optional. 2. ohlcv can be provided by `float`, `Decimal` and `str` representing number, but these are always stored as `Decimal`. -> If you're having trouble converting into `Quote` format, see our GitHub discussion on -> [Converting Pandas DataFrame to iterable Quotes]({{site.dotnet.repo}}/discussions/1165) for more information and troubleshooting support. - ### Where can I get historical quote data? There are many places to get stock market data. Check with your brokerage or other commercial sites. If you're looking for a free developer API, see our ongoing [discussion on market data]({{site.dotnet.repo}}/discussions/579) for ideas. @@ -161,7 +158,12 @@ quotes_list = [ ] ``` -You can also use `numpy.vectorize()`, its gain is too slight and hard to apply in this case. +You can also use experiment with `numpy.vectorize()`, but we don't like it much. It's performance gains are small in comparison to the added code complexity. + +For a quickstart that includes converting quotes from **Pandas DataFrame**, see our online _ReplIt_ code example for the [Williams Fractal indicator](https://replit.com/@daveskender/Stock-Indicators-for-Python-Williams-Fractal). + +> If you're still having trouble converting into `Quote` format, see our GitHub discussion on +> [Converting Pandas DataFrame to iterable Quotes]({{site.dotnet.repo}}/discussions/1165) for more community discussion and troubleshooting support. ### Using custom quote classes From c91c8b55df8dd1bb797bea28c99f6da2541f519c Mon Sep 17 00:00:00 2001 From: Dave Skender <8432125+DaveSkender@users.noreply.github.com> Date: Tue, 2 Apr 2024 04:15:01 -0400 Subject: [PATCH 13/13] Update guide.md Signed-off-by: Dave Skender <8432125+DaveSkender@users.noreply.github.com> --- docs/pages/guide.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/pages/guide.md b/docs/pages/guide.md index f5b7d0cb..f848a4a1 100644 --- a/docs/pages/guide.md +++ b/docs/pages/guide.md @@ -158,7 +158,7 @@ quotes_list = [ ] ``` -You can also use experiment with `numpy.vectorize()`, but we don't like it much. It's performance gains are small in comparison to the added code complexity. +You can also use experiment with `numpy.vectorize()`, but we don't like it much. Its small performance gains aren't worth the added code complexity in this use case. For a quickstart that includes converting quotes from **Pandas DataFrame**, see our online _ReplIt_ code example for the [Williams Fractal indicator](https://replit.com/@daveskender/Stock-Indicators-for-Python-Williams-Fractal).