title: How to do a group by operation on a list of json objects in python?
body: <p>I am working on a Python script where I need to group by a key in a list of JSON objects.</p>
  
  <p>I’ve a list of a large number of JSON objects in python in the following format:</p>
  
  <p>[{'name': xyz, 
     'territory': abc, 
      'parameter_a': 1,
      'parameter_b': 2, 
      'parameter_c': 3},
   …] </p>
  
  <p>Now I want to create a tag (say parameter_d) which should say the number in the grouped by count the number of times a specific territory (Say ‘abc’) has occurred in the whole list of json objects.
  E.g. Territory abc occurs 3 times in the list, so i want the parameter_d to hold values 1,2,3 for the different instances where the territory abc occurred.
   Thanks in advance for the help.</p>