Add tide-forecasting example under gists/tides - #50
Merged
Conversation
Relocate the example from gist_tides/ to gists/tides/ and append the complete tides_nns.py inside a collapsible block in the README so it can be replicated without opening a second file. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01MxVLKYqazC2uuAW3P3MbAm
Fix a grammar slip, reframe "gist" wording as "example" now that it lives in the repo, and keep the savefig comment in sync between the script and its embedded copy. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01MxVLKYqazC2uuAW3P3MbAm
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a self-contained example,
gists/tides/, that reproduces Lord Kelvin's tide forecast from the raw water-level series using NNS.ARMA — no astronomy or hand-tuned harmonic constituents. Achieves R² ≈ 0.965 on a held-out two-week window.Inspired by John Mount's Lord Kelvin, Data Scientist.
Contents
tides_nns.py— runnable script (~2 min, dominated byNNS.ARMA.optim).README.md— historical framing, results, a note on the one non-obvious line (filter seasonal periods before slicing), and the full script embedded in a collapsible block for copy-paste replication.tides_forecast.png— generated figure.Notes
ruff check(the example is covered by the repo-wide lint).nnspackage or tests.🤖 Generated with Claude Code
Generated by Claude Code