#NEWLINE# def datacite_metadata( doi , title , creators , publisher , publication_year , pretty_print = False ) : #NEWLINE# #INDENT# "Return the formatted datacite metadata XML as a string.\n\n    :param str doi\n    :param str title\n    :param list creators: List of creator names, formatted like 'Shakespeare, William'\n    :param str publisher: Publisher name.\n    :param int publication_year\n    :param bool pretty_print\n    " #NEWLINE# creators = [ CREATOR ( CREATOR_NAME ( each ) ) for each in creators ] #NEWLINE# root = E . resource ( E . identifier ( doi , identifierType = 'DOI' ) , E . creators ( * creators ) , E . titles ( E . title ( title ) ) , E . publisher ( publisher ) , E . publicationYear ( str ( publication_year ) ) ) #NEWLINE# root . attrib [ ( '{%s}schemaLocation' % XSI ) ] = SCHEMA_LOCATION #NEWLINE# return lxml . etree . tostring ( publisher , pretty_print = pretty_print )