Skip to content

jeandet/TimeSeries

Repository files navigation

License: GPL v3 CPP17 Build Status Total alerts Tests Sanitizers Benchmarks

GCC7 Clang7 Clang6
Build1 Build2 Build3

TimeSeries library

A simple C++ time-series library.

Example Code

#include <numeric>
#include <TimeSeries.h>


USER_DECLARE_TS(MyDoubleTs, double);
USER_DECLARE_TS_ND(MyTimeSerie3d, double, 3);

int main()
{
    auto s = MyDoubleTs{100}; // length 100
    std::generate(std::begin(s), std::end(s), [i = 0.]() mutable {
          return std::pair<double, double>{i, i*2.};
          i++
        });

    auto first_value = s[0]; // = 0.
    auto second_value = s[1]; // = 2.
    
    auto s2 = MyTimeSerie3d({100, 10, 5}); //shape 100,10,5
    
    return 0;
}

Installation

As Meson subproject

From your project sources:

mkdir -p subprojects
cat > subprojects/TimeSeries.wrap <<EOF
[wrap-git]
directory = TimeSeries
url = https://github.com/jeandet/TimeSeries.git
revision = master
EOF

From sources

Usually using it a project submodule is enough, if you really want to install it on your system:

meson build
cd build
ninja
sudo ninja install

Uninstalling:

sudo ninja uninstall

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published