title: Way to call method depending on variable?
body: <p>I already have a working, but in my oppinion not beautiful solution for a part of a long script.</p>
  <p>My script uses several similar methods, that differ too much to combine. However I came to a point where I want to call one of those methods depending on a given variable.</p>
  <p>The names of the methods are build up like this:</p>
  <pre><code>def read_A():
      #doing sth
  def read_B():
      #doing sth else
  def read_C():
  </code></pre>
  <p>etc.</p>
  <p>Now I would like to call those methods in a pythonic way, when the letter (<code>'A'</code>, <code>'B'</code>, <code>'C'</code>, ...) is given as a variable.</p>
  <p>A non-pythonic solution would be:</p>
  <pre><code>if var == &quot;A&quot;:
      read_A()
  if var == &quot;B&quot;:
      read_B() .....
  </code></pre>
  <p>And I hope to find a more pythonic solution that allows me to call those methods simply like this:</p>
  <pre><code>var = &quot;A&quot;
  read_var()      #This would call the method 'read_A()'
  </code></pre>
  <p>Please mind that the code above is only an image of what I hope to do, it is not a working example!</p>