Software Open Access

# Nonlinear measures for dynamical systems

Schölzel, Christopher

### Citation Style Language JSON Export

{
"publisher": "Zenodo",
"DOI": "10.5281/zenodo.3814723",
"language": "eng",
"title": "Nonlinear measures for dynamical systems",
"issued": {
"date-parts": [
[
2019,
6,
16
]
]
},
"abstract": "<p><strong>NOnLinear measures for Dynamical Systems (nolds)</strong></p>\n\n<p>Nolds is a small numpy-based library that provides an implementation and a learning resource for nonlinear measures for dynamical systems based on one-dimensional time series. Currently the following measures are implemented:</p>\n\n<p><em>sample entropy</em> (<code>sampen</code>)</p>\n\n<p>Measures the complexity of a time-series, based on approximate entropy</p>\n\n<p><em>correlation dimension</em> (<code>corr_dim</code>)</p>\n\n<p>A measure of the <em>fractal dimension</em> of a time series which is also related to complexity.</p>\n\n<p><em>Lyapunov exponent</em> (<code>lyap_r</code>, <code>lyap_e</code>)</p>\n\n<p>Positive Lyapunov exponents indicate chaos and unpredictability. Nolds provides the algorithm of Rosenstein et al. (<code>lyap_r</code>) to estimate the largest Lyapunov exponent and the algorithm of Eckmann et al. (<code>lyap_e</code>) to estimate the whole spectrum of Lyapunov exponents.</p>\n\n<p><em>Hurst exponent</em> (<code>hurst_rs</code>)</p>\n\n<p>The hurst exponent is a measure of the &quot;long-term memory&quot; of a time series. It can be used to determine whether the time series is more, less, or equally likely to increase if it has increased in previous steps. This property makes the Hurst exponent especially interesting for the analysis of stock data.</p>\n\n<p><em>detrended fluctuation analysis (DFA)</em> (<code>dfa</code>)</p>\n\n<p>DFA measures the Hurst parameter <em>H</em>, which is very similar to the Hurst exponent. The main difference is that DFA can be used for non-stationary processes (whose mean and/or variance change over time).</p>\n\n<p>&nbsp;</p>\n\n<p><strong>Example</strong></p>\n\n<pre><code class=\"language-python\">import nolds\nimport numpy as np\n\nrwalk = np.cumsum(np.random.random(1000))\nh = nolds.dfa(rwalk)</code></pre>\n\n<p>&nbsp;</p>\n\n<p><strong>Requirements</strong></p>\n\n<p>Nolds supports Python 2 (&gt;= 2.7) and 3 (&gt;= 3.4) from one code source. It requires the package <a href=\"http://numpy.scipy.org/\">numpy</a>.</p>\n\n<p>These are the only hard requirements, but some functions will need other packages:</p>\n\n<ul>\n\t<li>If you want to use the RANSAC algorithm for line fitting, you will also need the package <a href=\"http://scikit-learn.org/stable/\">sklearn</a>.</li>\n\t<li>For the true random numbers generated by <code>nolds.qrandom</code> you need the package <a href=\"https://pypi.python.org/pypi/quantumrandom/1.9.0\">quantumrandom</a>.</li>\n\t<li>The plotting functions in <code>nolds.examples</code> require the package <a href=\"https://matplotlib.org/\">matplotlib</a>.</li>\n</ul>\n\n<p>&nbsp;</p>\n\n<p><strong>Installation</strong></p>\n\n<p>Nolds is available through PyPI and can be installed using pip:</p>\n\n<pre><code class=\"language-bash\">pip install nolds</code></pre>\n\n<p>You can test your installation by running some sample code with:</p>\n\n<pre><code class=\"language-bash\">python -m nolds.examples lyapunov-logistic</code></pre>\n\n<p>Alternatively, if you do not have <a href=\"https://matplotlib.org/\">matplotlib</a> installed, you can run the unittests with:</p>\n\n<pre><code class=\"language-bash\">python -m unittest nolds.test_measures</code></pre>\n\n<p>If you only have the download from this Zenodo publication available, you can unzip the archive and run the following command inside the folder:</p>\n\n<pre><code class=\"language-bash\">python setup.py install</code></pre>\n\n<p>&nbsp;</p>\n\n<p><strong>Documentation</strong></p>\n\n<p>Nolds is designed as a learning resource for the measures mentioned above. Therefore the corresponding functions feature extensive documentation that not only explains the interface but also the algorithm used and points the user to additional reference code and papers. The documentation can be found in the code, but it is also available as <a href=\"https://cschoel.github.io/nolds/\">HTML-Version</a> and on <a href=\"http://nolds.readthedocs.io/\">Read the Docs</a>.</p>\n\n<p>The relevant measures can be found in the file <code>nolds/measures.py</code>.</p>\n\n<p>&nbsp;</p>\n\n<p><strong>Contact information</strong></p>\n\n<p>If you have any questions, suggestions or corrections, you can find my current email address in <a href=\"https://orcid.org/0000-0001-8627-0594\">my ORCID record</a>.</p>",
"author": [
{
"family": "Sch\u00f6lzel, Christopher"
}
],
"version": "0.5.2",
"type": "article",
"id": "3814723"
}
495
14
views