title: Python: Identify patterns in time series based data
body: <p>I have a dataset of following format:</p>
  
  <pre><code>11/26/2015 14:00:00 N234    11004066    27.05
  11/26/2015 14:01:00 N234    11004066    27.07
  11/26/2015 14:02:00 N234    11004066    27.04
  11/26/2015 14:03:00 N234    11004066    27.02
  11/26/2015 14:04:00 N234    11004066    27.00
  11/26/2015 14:05:00 N234    11004066    26.94
  11/26/2015 14:06:00 N234    11004066    26.92
  11/26/2015 14:07:00 N234    11004066    26.90
  </code></pre>
  
  <p>For each quantity in correlation with time series I want to find what pattern given data column follows. I want to use semi or unsupervised neural networks approach but I am new to it. In order to classify Patterns I have written a code but I am having problems integrating it further with ANN concepts.</p>
  
  <pre><code>    #-----------------------------------------------------------------------  --------
  # Pattern regognition
  # 1. shift either increased or decreased
  #-------------------------------------------------------------------------------
  def shiftPattern(n, mean, var, shift = 0.5, u = 3, increase = 'T'):
  '''Pattern to increase and decrease whith shift parameter'''
  data = array(normal(n,mean,var))
  shift = array([None]*n)
  shifts = array([0]*u + [1]*(n-u))
  if increase == 'T':
  shift = data + shifts
  else:
  shift = data - shifts
  return shift
  #-------------------------------------------------------------------------------
  # 2. Trend either increased or decreased
  #-------------------------------------------------------------------------------
  def trendPattern(n, mean, var, slop):
  '''trend either increasing or decreasing with slop'''
  data = array(normal(n,mean,var))
  slops = array(range(1,(n+1)))*slop
  trend = data + slops
  return trend
  #-------------------------------------------------------------------------------
  # 3. Cyclic pattern
  #-------------------------------------------------------------------------------
  def cyclicPattern(n,mean, var, cycleAmplitude, cycleLength):
  Control Chart Pattern Recognition using Artificial Neural Network for Multivariate Autocorrelated Processes
  Ashenafi Muluneh, (2014) Page 65
  '''Cyclic pattern with cycle amplitude add cycle length'''
  data = array(normal(n,mean,var))
  cycle = data + cycleAmplitude*sin(float(2*pi)*array(range(1,(n+1)))/cycleLength)
  return cycle
  #-------------------------------------------------------------------------------
  # 4. Syatematic pattern
  #-------------------------------------------------------------------------------
  def systematicPattern(n, mean, var, delta):
  '''Syatematic variable with delts'''
  data = array(normal(n,mean,var))
  dummy = array([(-1)**i for i in range(1,(n+1))])
  systematic = data + dummy*delta*var
  return systematic
  </code></pre>
  
  <p>I would really appreciate if someone can help me integrating this code with a neural network to identify patterns.</p>