<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def format(self):
 """ Get the subtag code conventional format according to RFC 5646 section 2.1.1. :return: string -- subtag code conventional format. """

        subtag = self.data['subtag']
        if self.data['type'] == 'region':
            return subtag.upper()
        if self.data['type'] == 'script':
            return subtag.capitalize()
        return subtag