def create_output(name, mrn, ecg_filename, img_filename, mean_hr_bpm):
    """Interface between GUI and server
    This function is called by the GUI command function attached to the "Ok"
    button of the GUI.  As input, it takes the data entered into the GUI.
    It creates an output string that is sent back to the GUI that is
    printed in the console. If no data was entered, the field will return
    no data for name and a blank string for all other fields.
    Args:
        name (str): patient name entered in GUI
        mrn (str): patient id (medical record number) entered in GUI
        ecg_filename (str): filename of inputted ecg data
        img_filename (str): filename of inputed image file
    Returns:
        str: a formatted string containing patient information from the
            GUI
    """
    out_string = "Patient name: {}\n".format(name)
    out_string += "Patient MRN: {}\n".format(mrn)
    out_string += "ECG File Uploaded: {}\n".format(ecg_filename)
    out_string += "Image File Uploaded: {}\n".format(img_filename)
    out_string += "Patient Heart Rate: {}\n".format(mean_hr_bpm)
    return out_string