FinFeatures
Advanced Financial Feature Engineering Library for Quantitative Finance and Algorithmic Trading
FinFeatures is a comprehensive Python library designed for financial technical analysis and feature engineering. It provides a wide range of technical indicators, statistical transformations, and utility functions optimized for quantitative finance applications.
🚀 Key Features
Technical Indicators
- Moving Averages: Simple (SMA) and Exponential (EMA) Moving Averages
- Momentum Indicators: RSI, MACD with Signal and Histogram
- Volatility Indicators: Bollinger Bands, Average True Range (ATR)
- Oscillators: Stochastic Oscillator, Williams %R
- Other Indicators: Commodity Channel Index (CCI)
Statistical Transformations
- Volatility Analysis: Rolling volatility with annualization options
- Returns Calculation: Simple and logarithmic returns
- Statistical Measures: Rolling correlation, beta, z-scores, skewness, kurtosis
- Normalization: MinMax, Z-score, and Robust scaling methods
Advanced Features
- Signal Generation: Automated buy/sell signal generation
- Multi-timeframe Analysis: Batch processing for multiple timeframes
- Memory Efficient: Optional in-place operations
- Type Safety: Full type hints and validation
- Robust Error Handling: Comprehensive input validation
📦 Installation
From PyPI (Recommended)
📊 Available Functions
Technical Indicators
| Function | Description | Key Parameters |
|---|---|---|
simple_moving_average() |
Simple Moving Average | window, min_periods |
exponential_moving_average() |
Exponential Moving Average | window |
relative_strength_index() |
RSI with Wilder's smoothing | window (default: 14) |
macd() |
MACD with signal and histogram | fast, slow, signal |
bollinger_bands() |
Bollinger Bands with position | window, num_std |
average_true_range() |
Average True Range | window (default: 14) |
stochastic_oscillator() |
Stochastic %K and %D | k_window, d_window |
williams_r() |
Williams %R | window (default: 14) |
commodity_channel_index() |
Commodity Channel Index | window (default: 20) |
Statistical Transformations
| Function | Description | Key Parameters |
|---|---|---|
rolling_volatility() |
Rolling volatility calculation | window, annualize |
percent_change() |
Simple/log returns | periods, method |
rolling_correlation() |
Rolling correlation | column1, column2, window |
rolling_beta() |
Rolling beta calculation | asset_col, market_col, window |
z_score() |
Rolling z-score | window |
rolling_skewness() |
Rolling skewness | window |
rolling_kurtosis() |
Rolling kurtosis | window |
price_normalization() |
Various normalization methods | method, window |
Convenience Functions
| Function | Description |
|---|---|
basic_feature_set() |
Apply basic technical indicators |
premium_feature_set() |
Apply comprehensive indicator set |
multi_timeframe_sma() |
SMA for multiple timeframes |
generate_sma_signals() |
Generate trading signals |
🔧 Configuration
Default Parameters
Custom Indicator Pipeline
Trend indicators
df = ff.multi_timeframe_sma(df, price_col, windows=) df = ff.exponential_moving_average(df, price_col, window=12) df = ff.exponential_moving_average(df, price_col, window=26)
Momentum indicators
df = ff.relative_strength_index(df, price_col, window=14) df = ff.macd(df, price_col)
Volatility indicators
df = ff.bollinger_bands(df, price_col, window=20) df = ff.rolling_volatility(df, price_col, window=20)
Generate signals
df = ff.generate_sma_signals(df, price_col, fast_window=10, slow_window=30)
return df
🤝 Contributing
Contributions are welcome! Please feel free to submit a Pull Request. For major changes, please open an issue first to discuss what you would like to change.
Development Setup
🐛 Bug Reports
If you encounter any bugs, please file an issue on GitHub Issues with:
- A clear description of the bug
- Steps to reproduce
- Expected vs actual behavior
- Your environment details
📄 License
This project is licensed under the MIT License - see the LICENSE file for details.
🙏 Acknowledgments
- Built with pandas and numpy
- Inspired by various financial analysis libraries
- Thanks to the quantitative finance community
📚 Additional Resources
Happy Trading! 📈
Made with ❤️ by Advait Dharmadhikari
Metadata
Release files for finfeatures 0.2.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| finfeatures-0.2.0.tar.gz | 9.9 MB | Without provenance | Details for finfeatures-0.2.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| finfeatures-0.2.0-py3-none-any.whl | Python 3 | none | any | Details for finfeatures-0.2.0-py3-none-any.whl |
Total release size: 21.5 MB
Release files / finfeatures-0.2.0.tar.gz
| Download URL | finfeatures-0.2.0.tar.gz |
|---|---|
| Size | 9.9 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
cbf22e57228b33aaf790f1722773de63435f754719d4a5f210a5d52274e42f77
|
|
BLAKE2b-256 checksum How to use checksums |
699eebaf1dbbf6bec8195f72d844cc2ddd8e6848622428057dc7af9ee16ba32c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.5
|
Release files / finfeatures-0.2.0-py3-none-any.whl
| Download URL | finfeatures-0.2.0-py3-none-any.whl |
|---|---|
| Size | 11.6 MB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
38ef2c6da1183bf33738f2f2bea81e0c3386097e0122bee1f2e7dc644521c67e
|
|
BLAKE2b-256 checksum How to use checksums |
e08fb6aab8e31e9176c94d56663e31bb45d3901031146a0aaf6d11f585c1f025
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.5
|
Security for finfeatures 0.2.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.