title: Python Classes ( AttributeError: '' object has no attribute '')
body: <p>Having trouble understanding the problem in my code, new to classes (generally python too, so sorry if I name things wrong). I receive this error: </p>
  
  <p>I think my code is too long winded to include in here, so I made a simplified version to test the concept below. </p>
  
  <p>The question is, <strong>how can I create a new self object</strong>  "self4"? Which would then be available to other functions within the class. Currently I get this error.</p>
  
  <blockquote>
    <p>AttributeError: 'className' object has no attribute 'self4'</p>
  </blockquote>
  
  <pre><code>class className(object):
  
     def __init__(self, self1=1,self2=2,self3=3):
          self.self1=self1
          self.self2=self2
          self.self3=self3
  
     def evaluate(self, self5):
          print className.func1(self) + className.func2(self)
          self.self5=self5
          print className.func1(self)
  
     def func1(self):
         return self.self1 + self.self5
  
     def func2(self):
         self.self4 = self.self1+self.self2+self.self3
         return self.self4
  </code></pre>
  
  <p>filename <code>tester.py</code></p>
  
  <pre><code>import tester.py
  
  mst=tester.className()
  
  mst.evaluate()
  </code></pre>