def parse_infile(infile, param):
    """"
    Parse input file for one of a body's initial conditions and return it.  This
    is useful for when a parameter is not outputted but one needs it later on
    for analysis.

    Parameters
    ----------
    infile : str
        path to the input file.  Something like body.in
    param : str
        body's parameter

    Returns
    -------
    param : float
        initial condition of interest
    """

    # Open log file and get lines
    with open(infile) as handle:
        lines = handle.readlines()

    # Loop over line, look for parameter
    for ii in range(0,len(lines)):

        # Remove whitespace
        line = lines[ii].strip(' \t\n\r')

        # Found it? Done!
        # Correct line, if it exists, will look something like this:
        # dParameter some_number # comments
        if line.startswith(param):
            words = line.split()
            return float(words[1])

    # Didn't find it, so why did you tell me to look for it?
    raise RuntimeError("Couldn't find %s in %s." % (param, infile))