time-series

How to use aryule() in Matlab to extend a number series?

I have a series of numbers. I calculated the "auto-regression" between them using Yule-Walker method. But now how do I extend the series? Whole working is as follows: a) the series I use: 143.85 141.95 141.45 142.30 140.60 140.00 138.40 137.10 138.90 139.85 138.75 139.85 141.30 139.45 140.15 140.80 142.50 143.00 142.35 143.00 142...

Finding similarities in a multidimensional array

Consider a sales department that sets a sales goal for each day. The total goal isn't important, but the overage or underage is. For example, if Monday of week 1 has a goal of 50 and we sell 60, that day gets a score of +10. On Tuesday, our goal is 48 and we sell 46 for a score of -2. At the end of the week, we score the week like this: ...

Downsize Growing Time-Related Mysql Table

We have a database with the time related data in it. As you can imagine it growths (and slows down) with time. There is 50% read and 25% inserts and 25% update action on the present (this months) data, 100% read on the older data. The good thing is, the older data also becomes less important. The bad thing is that sometimes we need t...

Time series in R

Hi, I am tracking my body weight in a spread sheet but I want to improve the experience by using R. I was trying to find some information about time series analysis in R but I was not succesful. The data I have here is in the following format: date -> weight -> body-fat-percentage -> water-percentage e.g. 10/08/09 -> 84.30 -> 18.20 -...

storing massive ordered time series data in bigtable derivatives

I am trying to figure out exactly what these new fangled data stores such as bigtable, hbase and cassandra really are. I work with massive amounts of stock market data, billions of rows of price/quote data that can add up to 100s of gigabytes every day (although these text files often compress by at least an order of magnitude). This d...

How to use correlogram to estimate variance?

From a book of computer simulation, I got this two equation. The first is to calculate correlogram, the second is how to use correlogram to estimate variance. The common approach to estimate variance of observation is often not incorrect in computer simulation because observations are often related. My question is, the value I calcu...

R lag over missing data

Is there a variant of lag somewhere that keeps NAs in position? I want to compute returns of price data where data could be missing. Col 1 is the price data Col 2 is the lag of price Col 3 shows p - lag(p) - the return from 99 to 104 is effectively missed, so the path length of the computed returns will differ from the true. Col 4 shows...

key-value store for time series data?

I've been using SQL Server to store historical time series data for a couple hundred thousand objects, observed about 100 times per day. I'm finding that queries (give me all values for object XYZ between time t1 and time t2) are too slow (for my needs, slow is more then a second). I'm indexing by timestamp and object ID. I've entertain...

Multivariate time series modelling in R

I want do fit some sort of multi-variate time series model using R. Here is a sample of my data: u cci bci cpi gdp dum1 dum2 dum3 dx 16.50 14.00 53.00 45.70 80.63 0 0 1 6.39 17.45 16.00 64.00 46.30 80.90 0 0 0 6.00 18.40 12.00 51.00 47.30 82.40 1 0 0 6.57 19.35 7.00 42.00...

Generating a lagged time series cross sectional variable in R

Hello - I am a new R user. I have a time series cross sectional dataset and, although I have found ways to lag time series data in R, I have not found a way to create lagged time-series cross sectional variables so that I can use them in my analysis. Thank you for your help. ...

Most meaningful way to compare multiple time series

I need to write a program that performs arithmetic (+-*/) on multiples time series of different date range (mostly from 2007-2009) and frequency (weekly, monthly, yearly...). I came up with - find the series with the highest freq. then fill in the other series with zeros so they have the same number of elements. then perform the operati...

Which multi-axes, multi-scale plotting tool to use?

I am looking for plotting tools capable of using more than one or two vertical axes with different scales, like for instance: The goal is to plot several time series with different ranges in a same plot. For instance, I could have: Time series 1 with range [-1, 1] Time series 2 with range [-10, +10] Time series 3 with range [0, 1500...

Standard error of the ARIMA constant

I am trying to manually calculate the standard error of the constant in an ARIMA model, if it is included. I have referred to Box and Jenkins (1994) text, specially Section 7.2, but my understanding is that the methods mentioned here calculates the variance-covariance matrix for the ARIMA parameters only, not the constant. Tried searchin...

Information criterions in exp smoothing models

What are the numbers of parameters to be penalized for when using information criterions(BIC or AIC or..) for selecting the best models? Let's say that we have 3 models: 1. Simple exponential smoothing 2. Holt's method(level+trend) 3. Holt Winters(L+T+S), where we have monthly seasonality. How many parameters for penalization does have e...

[r] How to parse milliseconds in R?

How do I use strptime or any other functions to parse timestamps with milliseconds in R? > time[1] [1] "2010-01-15 13:55:23.975" > strptime(time[1], format="%Y-%m-%d %H:%M:%S.%f") [1] NA > strptime(time[1], format="%Y-%m-%d %H:%M:%S") [1] "2010-01-15 13:55:23"` ...

R zoo series sliding window calculation

Given I have a zoo dataset, I'd like to perform a sliding operation against it with the result being another zoo dataset. > x Y (09/24/09 08:00:13) 3.1 (09/24/09 08:05:13) 4.2 (09/24/09 08:10:13) 4.5 (09/24/09 08:15:13) 9.4 (09/24/09 08:20:13) 9.8 (09/24/09 08:25:13) 7.7 (09/24/09 08:30:13) 13.3 (09/2...

Recommendations for TimeSeries db

preferably open source for storing tick info. ...

MATLAB: compute mean of each 1-minute interval of a time-series

I have a bunch of times-series each described by two components, a timestamp vector (in seconds), and a vector of values measured. The time vector is non-uniform (i.e. sampled at non-regular intervals) I am trying to compute the mean/SD of each 1-minutes interval of values (take X minute interval, compute its mean, take the next interva...

How to Get Current Weather via Web Services

I am attempting to get the current weather given a zip code or a set of latitude/longitude coordinates. It appears that best practice to do this (and how NOAA does it) is to get the XML feed for a weather station. Example: http://www.weather.gov/xml/current_obs/KEDW.xml The only problem is that NOAA doesn't provide a good way to fi...

HT create a new vector in data frame that takes correlation of existing vectors

I have a time series of two indexes, with each row representing the closing price on the same day. I'd like to go to row 30 and lookback over the last 30 'days' and calculate the pearson correlation. And then store that value in a new vector. Then, repeat the calculation for the entire time series. It is a trivial task in Excel, so I'm...