title: How can I convert each Pandas Data Frame row into an object including the column values as the attributes?
body: <p>Suppose I have a DataFrame including following columns &quot;NAME&quot;, &quot;SURNAME&quot;, &quot;AGE&quot; and I would like to create one object for each row, including those column values as its variables.</p>
  <pre><code>person = ConvertRow2Object(frame.iloc[0,:])
  print person.NAME //outputs Gary
  </code></pre>
  <p>How can I do it with a generic solution to any DataFrame with any kind of column names and data types?</p>