4
$\begingroup$

I am looking at a multivariate time series data, which looks like this:

enter image description here

I am trying to create a threshold, so that when a huge peak comes up (like the one in the picture), it will output an alert.

The resource that I've found suggested Hotelling's T2 to calculate the threshold. https://blog.pivotal.io/data-science-pivotal/products/multivariate-time-series-forecasting-for-virtual-machine-capacity-planning

So, does anyone know if there's any packages or functions for Hotelling's T2 in python. I've checked pandas, numpy and statsmodels, but can't find any. Not sure if it's under a different name or something.

Thanks for the help

$\endgroup$
1
$\begingroup$

spm1d package contains many statistics, especially for multivariate time series data like yours.

for example Hotelling’s T2 test see: http://www.spm1d.org/doc/Stats1D/multivariate.html

$\endgroup$
1
  • $\begingroup$ We are looking for long answers. This is rather a comment. As soon as you have enough reputation you can comment everywhere. $\endgroup$ – Ferdi Mar 13 '17 at 7:35
0
$\begingroup$

One option could be to install:

  • Python package rpy2
  • R package Hotelling
  • Anaconda if you haven't already

Then you can use a Jupyter Notebook to run both Python and R in the same Notebook. Once you've started the Jupyter Notebook, run:

%load_ext rpy2.ipython
%R require(Hotelling)

And you should be able to run the analysis you need.

$\endgroup$

Not the answer you're looking for? Browse other questions tagged or ask your own question.