Xrf fit

PEP8: 2 spaces between top-level functions [link] (http://legacy.python.org/dev/peps/pep-0008/#blank-lines)