title: Resolve "ValueError: Unknown format code 'f' for object of type 'str'" within an imported module
body: <p>I'm using a python toolbox which has recently been ported to Python 3.x (<a href="https://github.com/GEMScienceTools/gmpe-smtk" rel="nofollow noreferrer">https://github.com/GEMScienceTools/gmpe-smtk</a>).</p>
  
  <p>The toolbox is working smoothly, but when I try to extract the produced data as before in the Python 2.7 version using the command <code>resid1.pretty_print("C:/Python37/PGAandSA_Appendix.csv", sep=",")</code>, I'm greeted with the following error <code>ValueError: Unknown format code 'f' for object of type 'str'</code>. </p>
  
  <p>The error is said to correspond to line 705 of an imported python module. The line of code is :</p>
  
  <p><code>For key in event["Sites"].__dict__:
                  data.append("{:.4f}".format(getattr(event["Sites"], key)[i]))</code> </p>
  
  <p>The module is found in the following directory: <code>C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\smtk-3.5.0-py3.7.egg\smtk\residuals\gmpe_residuals.py</code></p>
  
  <p>I'm assuming I will have to edit the code within this line. If anyone could explain the modification I will have to make and why it would be much appreciated. I've been made aware editing an imported python module is dangerous, so elaboration of as to why would also be helpful (surely I can just change the code back to the original or use a fresh install?).</p>
  
  <p>Thanks!</p>