<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def create_board(self, name, project_ids, preset="scrum", location_type='user', location_id=None):
 """Create a new board for the ``project_ids``. :param name: name of the board :type name: str :param project_ids: the projects to create the board in :type project_ids: str :param preset: What preset to use for this board. (Default: "scrum") :type preset: 'kanban', 'scrum', 'diy' :param location_type: the location type. Available in cloud. (Default: "user") :type location_type: 'user', 'project' :param location_id: the id of project that the board should be located under. Omit this for a 'user' location_type. Available in cloud. :type location_id: Optional[str] :return: The newly created board :rtype: Board """

        if self._options['agile_rest_path'] != GreenHopperResource.GREENHOPPER_REST_PATH:
            raise NotImplementedError('JIRA Agile Public API does not support this request')

        payload = {}
        if isinstance(project_ids, string_types):
            ids = []
            for p in project_ids.split(','):
                ids.append(self.project(p).id)
            project_ids = ','.join(ids)
        if location_id is not None:
            location_id = self.project(location_id).id
        payload['name'] = name
        if isinstance(project_ids, string_types):
            project_ids = project_ids.split(',')
        payload['projectIds'] = project_ids
        payload['preset'] = preset
        if self.deploymentType == 'Cloud':
            payload['locationType'] = location_type
            payload['locationId'] = location_id
        url = self._get_url(
            'rapidview/create/presets', base=self.AGILE_BASE_URL)
        r = self._session.post(
            url, data=json.dumps(payload))

        raw_issue_json = json_loads(r)
        return Board(self._options, self._session, raw=raw_issue_json)