title: Filter Array of object by multiple keys
body: <p>I have an array of objects with duplicates keys with javascript:</p>
  
  <pre><code>var transactions = [
            {
              id: 3,
              sourceAccount: 'A',
              targetAccount: 'B',
              amount: 100,
              category: 'eating_out',
              time: '2018-03-02T10:34:30.000Z'
            },
            {
              id: 1,
              sourceAccount: 'A',
              targetAccount: 'B',
              amount: 100,
              category: 'eating_out',
              time: '2018-03-02T10:33:00.000Z'
            },
            {
              id: 6,
              sourceAccount: 'A',
              targetAccount: 'C',
              amount: 250,
              category: 'other',
              time: '2018-03-02T10:33:05.000Z'
            },
            {
              id: 4,
              sourceAccount: 'A',
              targetAccount: 'B',
              amount: 100,
              category: 'eating_out',
              time: '2018-03-02T10:36:00.000Z'
            },
            {
              id: 2,
              sourceAccount: 'A',
              targetAccount: 'B',
              amount: 100,
              category: 'eating_out',
              time: '2018-03-02T10:33:50.000Z'
            },
            {
              id: 5,
              sourceAccount: 'A',
              targetAccount: 'C',
              amount: 250,
              category: 'other',
              time: '2018-03-02T10:33:00.000Z'
            }
          ];
  </code></pre>
  
  <p>and i need to filter o reduce the array based on "duplicate keys" lets says where
  sourceAccount: 'A',targetAccount: 'C' and amount: 250 and i need to create a new array of objects with the duplicate ones. Hopefully with pure JS!</p>
  
  <p>Edit</p>
  
  <p>Expected value</p>
  
  <pre><code>var expected = [
            {
              id: 3,
              sourceAccount: 'A',
              targetAccount: 'B',
              amount: 100,
              category: 'eating_out',
              time: '2018-03-02T10:34:30.000Z'
            },
            {
              id: 1,
              sourceAccount: 'A',
              targetAccount: 'B',
              amount: 100,
              category: 'eating_out',
              time: '2018-03-02T10:33:00.000Z'
            },
            {
              id: 4,
              sourceAccount: 'A',
              targetAccount: 'B',
              amount: 100,
              category: 'eating_out',
              time: '2018-03-02T10:36:00.000Z'
            },
            {
              id: 2,
              sourceAccount: 'A',
              targetAccount: 'B',
              amount: 100,
              category: 'eating_out',
              time: '2018-03-02T10:33:50.000Z'
            }
          ];
  </code></pre>
  
  <p>As far all my intents y need to specified the value of the key, but it can be dynamically, so the idea is to map the array into a new array where sourceAccount, targetAccount, category and amount are the same value, without knowing the value before.</p>