Git Product home page Git Product logo

tatk-rs's Introduction

Donate with Bitcoin! Donate with Ethereum! Donate with BNB!
crates.io version crates.io downloads

TATK, Technical Analysis Toolkit

The objective of this crate is analyzing signals and indicators of data and providing additional tools for accurate analysis. There are several other wonderful crates that implement similar algorithms, however they did not meet my personal needs or had minor errors in their calculations.

Features

  • Momentum / Moving Averages
    • Simple Moving Average (SMA)
    • Exponential Moving Average (EMA)
    • Double Exponential Moving Average (DEMA)
    • McGinley Dynamic Indicator (MD)
    • On-Balance Volume (OBV)
    • Rate of Change (ROC)
  • Oscillators
    • Relative Strength Index (RSI)
    • Moving Average Convergence and Divergence (MACD)
    • Bollinger Bands (BBands)
    • True Range (TR)
    • Average True Range (ATR)
  • Others
    • Linear Regression (LineReg)
    • Variance (Var(X))
    • Standard Deviation (SD/STDEV)
    • Cross (Cross), checks two lines for Golden or Death cross.
  • Macros, Traits, and Derives

Documentation

Most of the documentation can be accessed by clicking the following link: docs.rs. That documentation is automatically generated and also accessible from crates.io.

Traits

The following traits are either used by the crate on indicators or to be defined by the user for additional functionality.

  • Indicator
    • Stats - Basic statistics for the indicator such as: sum, mean, variance, and standard deviation.
    • Period - Period of window of the data for the indicator.
    • Next - Add a new data point to the indicator to recalculate value.
  • User Defined
    • AsValue - Alternative value that can be passed to an Indicators Next.
    • Open - Opening value for the data type.
    • Close - Closing value for the data type.
    • Low - Lowest value for the data type.
    • High - Highest value for the data type.
    • Volume - Total volume for the data type.
  • Others
    • Hl2 - Average of the Highest and Lowest values, requires High and Low to be defined.
    • Hlc3 - Average of the Highest, Lowest, and Close values, requires High, Low, and Close to be defined.
    • Ohlc4 - Average of the Open, Highest, Lowest, and Close values, requires Open, High, Low, and Close to be defined.

Examples

Following examples can be ran with: cargo run --example short_id

  • Simple Moving Average (SMA): sma.rs
  • Exponential Moving Average (EMA): ema.rs
  • Double Exponential Moving Average (DEMA): dema.rs
  • Moving Average Convergence Divergence (MACD): macd.rs
  • Relative Strength Indicator (RSI): rsi.rs
  • Bollinger Bands (BBands): bbands.rs
  • Average True Range (ATR): atr.rs
  • McGinley Dynamic Indicator (MD): md.rs
  • On-Balance Volume (OBV): obv.rs
  • Rate of Change (ROC): roc.rs
  • Linear Regression (LineReg): linereg.rs
  • Traits (Traits): user_traits.rs

Tips Appreciated!

Wallet addresses are provided below, or click the badges above!

Ethereum (ETH): 0x7d75f6a9c021fcc70691fec73368198823fb0f60
Bitcoin (BTC):  bc1q75w3cgutug8qdxw3jlmqnkjlv9alt3jr7ftha0
Binance (BNB):  0x7d75f6a9c021fcc70691fec73368198823fb0f60

tatk-rs's People

Contributors

ohkthx avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

Forkers

shabbirhasan1

tatk-rs's Issues

Canonical struct naming?

Hey, I just found this crate after you mentioned you rolled your own crate on ta-rs. Nice!

One thing I saw is that you use non-canonical struct names (all uppercase).

From the Rust API Guidelines on naming:

In UpperCamelCase, acronyms and contractions of compound words count as one word: use Uuid rather than UUID, Usize rather than USize or Stdin rather than StdIn.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.