himself65 avatar

Stock Correlation

This is a well-structured financial analysis tool that finds stocks that move together using historical price data from Yahoo Finance. It routes between four sub-skills depending on what you ask: discovering correlated peers for a single ticker, analyzing the relationship between two specific stocks, clustering groups of tickers, or examining time-varying correlations. The peer discovery is thoughtfully designed to build universes dynamically using yfinance screeners rather than hardcoded lists, and it pulls from same-industry, sector, and adjacent thematic groups. Each sub-skill returns practical metrics like Pearson correlation, beta, R-squared, and spread z-scores with clear interpretation guides. Good for research and pair trading ideas, though the disclaimer is right that this is educational only.

skills.sh installs
3.7K
GitHub stars
3.5K
last updated
Aug 21, 2026

Install

$ npx -y skills add himself65/finance-skills --skill stock-correlation --agent claude-code

Installs into .claude/skills of the current project.

Files

Stock Correlation Analysis Skill

If your host has not already executed the shell probes below (for example, in Codex), run the commands inside the ! wrappers with its shell tool before choosing a setup path. Use the actual output; if shell access is unavailable, report that limitation.

Finds and analyzes correlated stocks using historical price data from Yahoo Finance via yfinance. Routes to specialized sub-skills based on user intent.

Important: This is for research and educational purposes only. Not financial advice. yfinance is not affiliated with Yahoo, Inc.


Step 1: Ensure Dependencies Are Available

Current environment status:

!`python3 -c "exec('try:\n import yfinance, pandas, numpy\n print(f\'yfinance={yfinance.__version__} pandas={pandas.__version__} numpy={numpy.__version__}\')\nexcept Exception:\n print(\'DEPS_MISSING\')')"`

If DEPS_MISSING, install required packages before running any code:

import subprocess, sys
subprocess.check_call([sys.executable, "-m", "pip", "install", "-q", "yfinance", "pandas", "numpy"])

Sponsors

Details

Repository
github.com/himself65/finance-skills
Categories
Debugging, Finance & Trading
First seen
May 16, 2026

More from himself65/finance-skills

All 25

Recommended

More Debugging
1tradermonty avatarvcp-screenertradermonty/claude-trading-skillsScreen S&P 500 stocks for Mark Minervini's Volatility Contraction Pattern (VCP) and detect historical VCPs in a single ticker's price path. Identifies Stage 2 u3.7Kskills.sh installs
2getsentry avatarsentry-sdk-setupgetsentry/sentry-for-aiSet up Sentry in any language or framework. Detects the user's platform and loads the right SDK skill. Use when asked to add Sentry, install an SDK, or set up e3.7Kskills.sh installs
3grafana avatark6-perf-test-websitegrafana/skillsUse when the user wants to performance-test, load-test, or stress-test a public website end-to-end with k6. Produces a hybrid (protocol + browser) test suite, S3.7Kskills.sh installs
4giuseppe-trisciuoglio avataraws-lambda-java-integrationgiuseppe-trisciuoglio/developer-kitProvides AWS Lambda integration patterns for Java with cold start optimization. Use when deploying Java functions to AWS Lambda, choosing between Micronaut and 3.7Kskills.sh installs
5giuseppe-trisciuoglio avataraws-lambda-php-integrationgiuseppe-trisciuoglio/developer-kitProvides AWS Lambda integration patterns for PHP with Symfony using the Bref framework. Creates Lambda handler classes, configures runtime layers, sets up SQS/S3.7Kskills.sh installs
6giuseppe-trisciuoglio avatargithub-issue-workflowgiuseppe-trisciuoglio/developer-kitProvides a structured 8-phase workflow for resolving GitHub issues in Claude Code. Covers fetching issue details, analyzing requirements, implementing solutions3.6Kskills.sh installs