title: Can you define class properties in a loop?
body: <p>does anyone know if it's possible to define class properties while iterating over a list? For example: </p>
  
  <pre><code>class a ():
      def __init__(self, df):
          self.data = df
          property_names = ['a', 'b', 'c', 'd']
          property_values = [a, b, c, d]
  
          for i, j in zip(property_names, property_values):
              self.i = self.data.loc[self.data[col].isin(j)]
  </code></pre>
  
  <p>property_values in this example is a list of lists. </p>
  
  <p>I would like for the class to return self.a = df.loc[df[col].isin(a)], and so on. </p>
  
  <p>Thanks, </p>