def save_raw_data_from_data_queue(data_queue, filename, mode='<STR_LIT:a>', title='<STR_LIT>', scan_parameters=None):  
if not scan_parameters:<EOL><INDENT>scan_parameters = {}<EOL><DEDENT>with open_raw_data_file(filename, mode='<STR_LIT:a>', title='<STR_LIT>', scan_parameters=list(dict.iterkeys(scan_parameters))) as raw_data_file:<EOL><INDENT>raw_data_file.append(data_queue, scan_parameters=scan_parameters)<EOL><DEDENT>
Writing raw data file from data queue

    If you need to write raw data once in a while this function may make it easy for you.