title: How to write dataframe data into json file as json non array objects?
body: <p>I have data in Pandas dataframe and I am able to write the dataframe data into JSON file by calling:</p>
  
  <pre><code>df.to_json('filepath', orient='records')
  </code></pre>
  
  <p>This writes data into json file as an <strong>array</strong> of JSON objects.</p>
  
  <blockquote>
    <p>[{"col 1":"a","col 2":"b"},{"col 1":"c","col 2":"d"}]</p>
  </blockquote>
  
  <p>I want data in the json file to be as below i.e. just comma seperated JSON objects <strong>without array</strong></p>
  
  <blockquote>
    <p>{"col 1":"a","col 2":"b"},{"col 1":"c","col 2":"d"}</p>
  </blockquote>
  
  <p>Would appreciate any help. I am new to python and not able to find the way. Thank you.</p>