Skip to content

TA-Lib RT is a fork of TA-Lib that provides additional API for incremental calculation of indicators without reprocessing whole data.

Notifications You must be signed in to change notification settings

razorback16/ta-lib-rt

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 

Repository files navigation

TA-Lib RT

TA-Lib RT (Real Time) is a fork of TA-Lib that provides additional API for incremental calculation of indicators without reprocessing whole data. Binary compatibility with original code is possible but isn't provided in this release.

In a nutshell each indicator function ( for example: int TA_[MYINDICATOR](indexArguments, dataArguments, optArguments, outArguments); ) got 5 more additional functions. 3 main functions:

  • int TA_[MYINDICATOR]_StateInit(void** _state, optArguments); - allocates indicator-dependant object that contains a state of its last calculation.
  • int TA_[MYINDICATOR]_State(void* _state, dataArguments, outArguments); - calculates indicator based on state given. Note: dataArguments here aren't arrays but signle values. This function should be called in a loop for all data values.
  • int TA_[MYINDICATOR]_StateFree( void** _state ); - destroys state object and frees its previously allocated memory.

And 2 helper functions:

  • int TA_[MYINDICATOR]_StateSave( void* _state, FILE* _file ); - serialize state object to file.
  • int TA_[MYINDICATOR]_StateLoad( void** _state, FILE* _file ); - read state object from file.

There is also support of dynamic indicator functions resolution via TA_FuncInfo with help of TA_GetInitNewStateFuncPtr(), TA_GetCallFuncStateFuncPtr(), TA_GetFreeStateFuncPtr(), TA_GetSaveStateFuncPtr() and TA_GetLoadStateFuncPtr().

Please refer to wiki and examples for details.

Current version is alpha and only C++ API is tested

About

TA-Lib RT is a fork of TA-Lib that provides additional API for incremental calculation of indicators without reprocessing whole data.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C 47.7%
  • Makefile 26.3%
  • Java 19.9%
  • C++ 4.6%
  • Perl 0.7%
  • QMake 0.4%
  • Other 0.4%