

def create_dataset(self, dataset_id, friendly_name=None, description=None, access=None):
    'Create a new BigQuery dataset.\n\n        Parameters\n        ----------\n        dataset_id : str\n            Unique ``str`` identifying the dataset with the project (the\n            referenceID of the dataset, not the integer id of the dataset)\n        friendly_name: str, optional\n            A human readable name\n        description: str, optional\n            Longer string providing a description\n        access : list, optional\n            Indicating access permissions (see\n            https://developers.google.com/bigquery/docs/reference/v2/datasets#resource)\n\n        Returns\n        -------\n        Union[bool, dict]\n            ``bool`` indicating if dataset was created or not, or response\n            from BigQuery if swallow_results is set for False\n        '
    try:
        datasets = self.bigquery.datasets()
        dataset_data = self.dataset_resource(dataset_id, friendly_name=friendly_name, description=description, access=access)
        response = datasets.insert(projectId=self.project_id, body=dataset_data).execute()
        if self.swallow_results:
            return True
        else:
            return response
    except HttpError as e:
        logger.error('Cannot create dataset {0}, {1}'.format(dataset_id, e))
        if self.swallow_results:
            return False
        else:
            return {
                
            }

dataset/ETHPy150Open tylertreat/BigQuery-Python/bigquery/client.py BigQueryClient.create_dataset/original