title: Split excel data by key using javaScript
body: <p>I am pulling data from Excel using JavaScript. The output looks like this.</p>
  <pre><code>{
      
      &quot;Responsible&quot;: &quot;Grey&quot;,
      &quot;Goal&quot;: 0.823,
      &quot;Jan&quot;: 0.8621397507374327,
      &quot;Feb&quot;: 0.8605700219733681,
      &quot;Mrz&quot;: 0.8870898346258058,
      &quot;Apr&quot;: 0.8529801908413164,
      &quot;Mai&quot;: 0.8507431241640211
    }
  </code></pre>
  <p>I want to split the data into the following :</p>
  <pre><code>         {   
              &quot;Responsible&quot;: &quot;Grey&quot;,
              &quot;Goal&quot;: 0.823,
              &quot;Month&quot;: 0.8621397507374327,  
            }
  
  
           {  
             &quot;Responsible&quot;: &quot;Grey&quot;,
              &quot;Goal&quot;: 0.823,
              &quot;Month&quot;: 0.8605700219733681,
           }
           
           {   
              &quot;Responsible&quot;: &quot;Grey&quot;,
              &quot;Goal&quot;: 0.823,
              &quot;Month&quot;: 0.8870898346258058, 
            }
  
  
           {  
             &quot;Responsible&quot;: &quot;Grey&quot;,
              &quot;Goal&quot;: 0.823,
              &quot;Month&quot;: 0.8529801908413164,
           }
  
           {  
             &quot;Responsible&quot;: &quot;Grey&quot;,
              &quot;Goal&quot;: 0.823,
               &quot;Month&quot;: 0.8507431241640211
           }
              
  </code></pre>
  <p>My code looks like this :</p>
  <pre><code>Ausgabe = [];     
  
  _.forEach(data, element =&gt; {  
    obj = {
       
      Responsible: element.Responsible,
      Goal: element[&quot;Goal \r\n2022&quot;]  ,
      Jan : element[&quot;Jan-22&quot;],
      Feb: element[&quot;Feb-22&quot;],
      Mrz : element[&quot;Mar-22&quot;],
      Apr : element[&quot;Apr-22&quot;],
      Mai : element[&quot;May-22&quot;],
      
    }
    Ausgabe.push(obj)
      
  
  })
  </code></pre>
  <p>The data is provided in the data field, which can be edited or overwritten and is returned by default at the end.</p>