# Questions tagged [time-series]

A Time series is a sequence of data points with values measured at successive times (either in continuous time or at discrete time periods). Time series analysis exploits this natural temporal ordering to extract meaning and trends from the underlying data.

**1**

vote

**1**answer

13 views

### R: Calculate decile ranks by group

I have a dataframe crsppofo which contains monthly financial data with several variables. Of significance for my question are the following:
PERMNO monthyear BetaShr
1: 85814 199501 0.5
2: ...

**0**

votes

**0**answers

10 views

### Standardization of time-series data with scikit's StandardScaler and MinMaxScaler

Question about the right way of using StandardScaler on time-series data. I've got a time-series data that I want to put into RNN of shape (samples, time-step, features), I'm splitting the data into ...

**0**

votes

**0**answers

5 views

### Druid Timeseries Row Count Aggregation

I am currently calculating the average for a single dimension in a Druid data source using a timeseries query via pydruid. This is based on an example in the documentation (https://github.com/druid-io/...

**1**

vote

**1**answer

23 views

### Aggregating/resampling a pandas multiindex dataframe over many timeframes and forecasting ARIMA

I have multiple timeframes I want to track and predict values for (ARIMA forecasting 1 period ahead per timeframe), and my algorithm retrieves data on the lowest timeframe. Note: each timeframe is ...

**0**

votes

**0**answers

9 views

### How can slice the time-series data with multi-features to get continuous plot contains [train +test+prediction]?

I have the formatted dataset which looks like a matrix[NxM] where N = 40 total number of cycles(time-stamps) and M = 1440 pixels. For every cycle, I have 1440 pixel values corresponding to 1440 pixels....

**0**

votes

**0**answers

10 views

### Tensorflow.dataset sliding window pipeline performance

I'm implementing tf.data input pipeline for time-series classification problem; dataset itself is a >2M time-ordered record of 50 features; for any given time t prediction model ingests k-sized window ...

**0**

votes

**0**answers

13 views

### Feature extraction for multivariate time series data

I have a time series dataset with 24 features, including things such as:
-energy consumption
-inside temperature
-insdise humidity
-outside temperature
-other outside weather conditions.
I am ...

**0**

votes

**0**answers

14 views

### audio recognition: resize audio examples to the same length

I have an audio dataset featured with MFCCs and it is a 1D array numpy file.
There are 45K of examples in total, so it is a numpy file with 1 column and 45K row. In each row, there is a nested object ...

**0**

votes

**3**answers

38 views

### How to read a small percentage of lines of a very large CSV. Pandas - time series - Large dataset

I have a time series in a big text file.
That file is more than 4 GB.
As it is a time series, I would like to read only 1% of lines.
Desired minimalist example:
df = pandas.read_csv('...

**1**

vote

**2**answers

65 views

### Numpy: How to best align two sorted arrays?

In order to combine time series data, I am left with the following essential step:
>>> xs1
array([ 0, 10, 12, 16, 25, 29])
>>> xs2
array([ 0, 5, 10, 15, 20, 25, 30])
How to best ...

**0**

votes

**1**answer

15 views

### Keras LSTM problem, how set up correctly a neural network for time series?

i'm trying to undestand how lstm works for predict time series with Keras.
Here's my example.
I use an accelerometer and i have a 128.000 time series. I thought to take:
n_steps_in = 10.000
...

**-1**

votes

**0**answers

6 views

### Can someone provide me link for time series data for equipment monitoring,predictive maintenance?

Sensor data ,pump ,reactor data is acceptable.I had already gone through this data but it is overwhelming for me right now .

**1**

vote

**0**answers

17 views

### how to save trained ARIMA model to use later

I am using a univariate time series dataset to forecast. I am using ARIMA model to train. But it is a time-consuming process to train every time. Is there any process to save the trained ARIMA model ...

**2**

votes

**2**answers

34 views

### How to create a timeseries from a dataframe of event durations?

I have a dataframe full of bookings for one room (rows: booking_id, check-in date and check-out date that I want to transform into a timeseries indexed by all year days (index: days of year, feature: ...

**-1**

votes

**0**answers

28 views

### how to convert hour data to minute data?

My data is like below (20 data in one day)
date number name div a
0 2008-01-01 150.0 서울역(150) 승차 234.0
1 2008-01-01 150.0 서울역(150) 승차 -420.0
2 2008-01-01 150.0 서울역(150) ...

**1**

vote

**2**answers

42 views

### pandas resampling for for nighttime hours

I have a multivariate time series array. The timeseries is currently aggregated in 10 second intervals:
**Time**
2016-01-11 17:00:00
2016-01-11 17:00:10
2016-01-11 17:00:20
I want to resample so ...

**0**

votes

**0**answers

19 views

### How to convert JSON to Prometheus time-series friendly data in PowerShell

Using PowerShell to hit a third party API and return data in JSON I would like to format that response in a Prometheus time-series friendly format.
Prometheus formatting example:
<metric name>{...

**2**

votes

**1**answer

38 views

### Concatenate all dataframe columns into a single column

I have a dataframe that looks roughly like:
01/01/19 02/01/19 03/01/19 04/01/19
hour
1.0 27.08 47.73 54.24 ...

**0**

votes

**0**answers

24 views

### Recurrent Neural Network - Time Series prediction: On the number of output neurons and sequence length

Context
I am currently working with Gated Recurrent Units for time series prediction. Anyhow, my question should apply to all kinds of such recurrent networks.
In my data, I have timestamps of 15 ...

**0**

votes

**0**answers

8 views

### How to get fitted training data if I already had trained the ARIMA(python)?

I want to get fitted training data for train_monthly having only Price column in order to calculate Mean squared error for Training set.
I already went through this link but this answer was for R.
...

**0**

votes

**1**answer

11 views

### Why does auto_arima function from pmdarima package on python is much slower than auto.arima function available on R?

I work on a timeseries project with lot of timeseries and I want to settle it with an automatic function for arima/sarima model. I did it on R with auto.arima function which is very fast and now I'm ...

**2**

votes

**2**answers

36 views

### Postgresql: create a query that uses generate_series with an interval that correctly takes DST changes into account and flattens on true calendar days

As a followup to a comment on my question at Is this query that tries to get timeseries statuses with truncated dates even possible in regular relational databases? I have implemented a timeseries ...

**0**

votes

**2**answers

37 views

### complete time series by group in r

I have a dataframe
dat <- data.frame(c("G", "G", "G", "G"), c("G1", "G1", "G2", "G2"), c('2017-01-01', '2017-01-03', '2017-04-02', '2017-04-05'))
colnames(dat) <- c('Country', 'Place', 'date')
...

**0**

votes

**0**answers

13 views

### ARIMA forecast for timeseries is one step ahead

I'm trying to forecast timeseries with ARIMA. As you can see from the plot, the forecast is one step ahead of the expected values. I read in some other threads that this behavior is expected but how? ...

**0**

votes

**0**answers

209 views

### How to fix this error while using statsmodels“ ImportError: cannot import name 'factorial'”?

I have already gone through this answer
While importing auto_arima from pmdarima: ERROR : cannot import name 'factorial' from 'scipy.misc'
but couldn't fix the error,I do not ...

**0**

votes

**0**answers

16 views

### Can I concatenate a timeserie for price prediction based on passed input prices with another different input timeserie of passed volume?

I'm working to expand a working program that in python is downloading 5 years of daily stock data to train the next Open day price prediction using the past 60 opening days prices.
The original ...

**0**

votes

**0**answers

19 views

### Cluster around 50000 single variate time series

I have around 50000 single-variate different time series and each are having around 150000 datapoints (can vary from time series to series).
I want to cluster them efficiently.
I have tried ...

**0**

votes

**0**answers

15 views

### How to create an exogenous day of work week index variable from decomposition of daily time-series data?

I want to extract a day of work week index, that repeats itself every 5 days (business day). A monthly index would give 12 index values that repeat every 12 periods, instead of months I want to create ...

**0**

votes

**1**answer

32 views

### Apply timeseries decomposition (and anomaly detection) over a sliding/tiled window

Anomaly detection methods published and now abandoned by twitter have been separately forked and maintained in the anomalize package and the hrbrmstr/AnomalyDetection fork. Both have implemented ...

**0**

votes

**1**answer

20 views

### ggplot2 continuous color scale AND same datetime order as in data set

I want to combine two features of these plots - gradient colors and colorbar guide in a legend as seen in (1) and plot with same datetime order as in file as in (2).
(1) Does not display the data ...

**1**

vote

**2**answers

32 views

### Loess - y-coordinates not showing up correctly

I am using the dataset flu from astsa package and it contains monthly measurement-values from 1968 to 1978.
Now I would like to have a sequence of the same range (12*11=132) which contains exactly ...

**1**

vote

**0**answers

58 views

### time series prediction with variable-length input

My thesis is about cancer prediction in mice. I collected data from 35 mice. I measure the volume of the tumors every day after the beginning of cancer until the death of mice. The time of death ...

**0**

votes

**0**answers

16 views

### How can achieve LSTM/RNN history-based prediction by using Keras backend?

For my experiment, I have a formatted csv file with 1440 columns like following:
timestamps[row_index] | feature1 | feature2 | ... | feature1439 | feature1440 |
--------------------------------------...

**0**

votes

**0**answers

11 views

### How to apply INAR model to a simple time series model in Python

As a course project for Time Series Analysis, I used ARIMA for a very simple model - (Analyzing number of deaths in each episode of game of thrones and forecasting the number of deaths in the final ...

**0**

votes

**0**answers

14 views

### How to perform time-series analysis on MODIS NDVI dataset (MYD13Q1) in R?

i have a 15 year data from MODIS (MYD13Q1) which provides NDVI values for every 16 days. All this data is in tiff format. i want to analyze the changes that have occurred in the vegetation over the ...

**0**

votes

**0**answers

16 views

### Why I got 'The computed initial AR coefficients are not stationary' even after differencing my time series?

I wanted to know why did I got 'The computed initial AR coefficients are not stationary' even after specifying the differencing order as 1 while using ARIMA(1,1,1). The df['prod rate'] contains values ...

**0**

votes

**0**answers

18 views

### How to plot the line plot over time?

I want a line plot with the x-axis is the time changing by second and y-axis is the total amount of UID in the second.
My data frame(df) looks like this:
time UID
00:00:00 14389b0f
...

**0**

votes

**0**answers

10 views

### (python)pmdarima.auto_arima(pyramid.auto_arima) won't use d and D args automatically

I manually made 20 models and found out should use d=1 or D=1 for each model, but auto_arima never use difference args(even one model has no d or D at all, and all of the trials are like (1,0,1) x (0, ...

**0**

votes

**0**answers

17 views

### Why is meanf giving this output?

I have a daily timeseries loaded into ts().
daily_oil_data
Time Series:
Start = c(1986, 1)
End = c(2019, 5)
Frequency = 365
[1] 25.56000 26.00000 26.17667 26.35333 ...
When I run meanf on it, ...

**-1**

votes

**0**answers

20 views

### Is there a standard/“costumes” packages for data analysis and prediction in python?

I want to use python to do some data analysis.
In R, the structure was simple, the lm function was used for regression, and for time series analysis there's forecast for ARMA model and fGarch for ...

**1**

vote

**1**answer

31 views

### How to calculate correct batch size for LSTM?

I have a daily time series data like below.
CashIn CashOut
Date
2016-01-01 0.0 6500.0
2016-01-02 0.0 23110.0
2016-01-03 0.0 7070.0
2016-01-04 0.0 18520.0
...

**0**

votes

**0**answers

16 views

### “Error in kmin:kmax : result would be too long a vector”. In forecasting function select_and_forecast() with midas model

I'm try to do a midas forcasting in R with library midasr. I have the variable of low frequency is in quarter from 2009 Q1 to 2016 Q3 (PIB_agrocut), and my variable of high frequency is in month from ...

**-1**

votes

**0**answers

8 views

### Predicting song genre using LSTM

I have a dataset of songs based on genres. For example, a song may hold {5, 2, 3} as scores set for Sentimental, Rock and Jazz. In total there are 800 songs sequentially arranged. I want to predict ...

**1**

vote

**0**answers

25 views

### InfluxDB MAX value as time series

In InfluxDB, I have a time series of which I would like to determine the maximum value. Using the MAX() function does return the maximum, but as a single point consisting of the maximum value and ...

**1**

vote

**1**answer

27 views

### How to automate SARIMA model for time series forecasting?

I am trying to find the right parameters for p,d,q in time series forecasting using SARIMA. I need to forecast house prices for 1000 zip codes. The problem is that grid search takes too much time and ...

**1**

vote

**0**answers

29 views

### Python inverse diff function for multivariate time series

I’ve been working through this for a couple hours without any luck and decided to ask the community for help. I was able to difference the series through the diff() function and also manually ...

**-1**

votes

**1**answer

29 views

### Why is join on dates + filter on timestamps faster than joining on time-range in Spark?

I have a dataframe X containing some events (points in time, with timestamps) and another dataframe Y containing time-ranges (also specified by timestamps.)
Through experimentation and some reading I ...

**1**

vote

**3**answers

50 views

### Manipulating time series data in python: summing series and aggregating over a time period

I am trying to figure how to visualize some sensor data. I have data collected every 5 minutes for multiple devices, stored in a JSON structure that looks something like this (note that I don't have ...

**2**

votes

**2**answers

36 views

### Using xts with timespans crossing calendar dates: How to use period.apply (xts) or POSIXct datetime arguments in these cases in R?

I have a problem applying a function (min) to a specific repeating time-period. Basically my data looks like in that sample:
library(xts)
start <- as.POSIXct("2018-05-18 00:00")
tseq <- seq(...

**0**

votes

**0**answers

26 views

### Having trouble averaging data over hourly intervals and grouping by month

ImageI am dealing with quarter-hourly substation data and want to average the values per hour and group them by month. I want to plot the average hourly load for a 24 hour period for each month.
...