parameters: (spec)
return_statement: return pivoted
docstring: Utility method that will return a dictionary keyed off variable names
docstring_summary: Utility method that will return a dictionary keyed off variable names
docstring_tokens: Utility method that will return a dictionary keyed off variable names
function: def pivot_spec(spec):
          """
          Utility method that will return a dictionary keyed off variable names
          """
          pivoted = {}
          for element_data in spec.get('spec', []):
              if 'variable' in element_data:
                  pivoted[element_data['variable']] = element_data
          return pivoted
function_tokens: def pivot_spec ( spec ) : pivoted = { } for element_data in spec . get ( 'spec' , [ ] ) : if 'variable' in element_data : pivoted [ element_data [ 'variable' ] ] = element_data return pivoted