parameters: (requestContext, seriesListFirstPos, seriesListSecondPos, func, xFilesFactor=None)
return_statement: return results
docstring: Iterates over a two lists and aggregates using specified function
    list1[0] to list2[0], list1[1] to list2[1] and so on.
    The lists will need to be the same length
  
    Position of seriesList matters. For example using "sum" function
    ``aggregateSeriesLists(list1[0..n], list2[0..n], "sum")``
    it would find sum for each member
    of the list ``list1[0] + list2[0], list1[1] + list2[1], list1[n] + list2[n]``.
  
    Example:
  
    .. code-block:: none
  
      &target=aggregateSeriesLists(mining.{carbon,graphite,diamond}.extracted,mining.{carbon,graphite,diamond}.shipped, 'sum')
  
    An example above would be the same as running :py:func:`aggregate <aggregate>` for each member of the list:
  
    .. code-block:: none
  
      ?target=aggregate(mining.carbon.extracted,mining.carbon.shipped, 'sum')
      &target=aggregate(mining.graphite.extracted,mining.graphite.shipped, 'sum')
      &target=aggregate(mining.diamond.extracted,mining.diamond.shipped, 'sum')
  
    This function can be used with aggregation functions ``average`` (or ``avg``), ``avg_zero``,
    ``median``, ``sum`` (or ``total``), ``min``, ``max``, ``diff``, ``stddev``, ``count``,
    ``range`` (or ``rangeOf``) , ``multiply`` & ``last`` (or ``current``).
docstring_summary: Iterates over a two lists and aggregates using specified function
    list1[0] to list2[0], list1[1] to list2[1] and so on.
    The lists will need to be the same length
docstring_tokens: Iterates over a two lists and aggregates using specified function list1 [ 0 ] to list2 [ 0 ] list1 [ 1 ] to list2 [ 1 ] and so on . The lists will need to be the same length
function: def aggregateSeriesLists(requestContext, seriesListFirstPos, seriesListSecondPos, func, xFilesFactor=None):
    """
    Iterates over a two lists and aggregates using specified function
    list1[0] to list2[0], list1[1] to list2[1] and so on.
    The lists will need to be the same length
  
    Position of seriesList matters. For example using "sum" function
    ``aggregateSeriesLists(list1[0..n], list2[0..n], "sum")``
    it would find sum for each member
    of the list ``list1[0] + list2[0], list1[1] + list2[1], list1[n] + list2[n]``.
  
    Example:
  
    .. code-block:: none
  
      &target=aggregateSeriesLists(mining.{carbon,graphite,diamond}.extracted,mining.{carbon,graphite,diamond}.shipped, 'sum')
  
    An example above would be the same as running :py:func:`aggregate <aggregate>` for each member of the list:
  
    .. code-block:: none
  
      ?target=aggregate(mining.carbon.extracted,mining.carbon.shipped, 'sum')
      &target=aggregate(mining.graphite.extracted,mining.graphite.shipped, 'sum')
      &target=aggregate(mining.diamond.extracted,mining.diamond.shipped, 'sum')
  
    This function can be used with aggregation functions ``average`` (or ``avg``), ``avg_zero``,
    ``median``, ``sum`` (or ``total``), ``min``, ``max``, ``diff``, ``stddev``, ``count``,
    ``range`` (or ``rangeOf``) , ``multiply`` & ``last`` (or ``current``).
    """
    if len(seriesListFirstPos) != len(seriesListSecondPos):
      raise InputParameterError(
        "seriesListFirstPos and seriesListSecondPos argument must have equal length")
    results = []
  
    for i in range(0, len(seriesListFirstPos)):
      firstSeries = seriesListFirstPos[i]
      secondSeries = seriesListSecondPos[i]
      aggregated = aggregate(requestContext, (firstSeries, secondSeries), func, xFilesFactor=xFilesFactor)
      if not aggregated: # empty list, no data found
        continue
      result = aggregated[0]  # aggregate() can only return len 1 list
      result.name = result.name[:result.name.find('Series(')] + 'Series(%s,%s)' % (firstSeries.name, secondSeries.name)
      results.append(result)
    return results
function_tokens: def aggregateSeriesLists ( requestContext , seriesListFirstPos , seriesListSecondPos , func , xFilesFactor = None ) : if len ( seriesListFirstPos ) != len ( seriesListSecondPos ) : raise InputParameterError ( "seriesListFirstPos and seriesListSecondPos argument must have equal length" ) results = [ ] for i in range ( 0 , len ( seriesListFirstPos ) ) : firstSeries = seriesListFirstPos [ i ] secondSeries = seriesListSecondPos [ i ] aggregated = aggregate ( requestContext , ( firstSeries , secondSeries ) , func , xFilesFactor = xFilesFactor ) if not aggregated : # empty list, no data found continue result = aggregated [ 0 ] # aggregate() can only return len 1 list result . name = result . name [ : result . name . find ( 'Series(' ) ] + 'Series(%s,%s)' % ( firstSeries . name , secondSeries . name ) results . append ( result ) return results