docs: def split(self, split_ratio=0.7, stratified=False, strata_field='label',
                random_state=None):
          """Create train-test(-valid?) splits from the instance's examples.
  
          Arguments:
              split_ratio (float or List of floats): a number [0, 1] denoting the amount
                  of data to be used for the training split (rest is used for validation),
                  or a list of numbers denoting the relative sizes of train, test and valid
                  splits respectively. If the relative size for valid is missing, only the
                  train-test split is returned. Default is 0.7 (for the train set).
              stratified (bool): whether the sampling should be stratified.
                  Default is False.
              strata_field (str): name of the examples Field stratified over.
                  Default is 'label' for the conventional label field.
              random_state (tuple): the random seed used for shuffling.
                  A return value of `random.getstate()`.
  
          Returns:
              Tuple[Dataset]: Datasets for train, validation, and
              test splits in that order, if the splits are provided.
          """
          train_ratio, test_ratio, val_ratio = check_split_ratio(split_ratio)
  
          # For the permutations
          rnd = RandomShuffler(random_state)
          if not stratified:
              train_data, test_data, val_data = rationed_split(self.examples, train_ratio,
                                                               test_ratio, val_ratio, rnd)
          else:
              if strata_field not in self.fields:
                  raise ValueError("Invalid field name for strata_field {}"
                                   .format(strata_field))
              strata = stratify(self.examples, strata_field)
              train_data, test_data, val_data = [], [], []
              for group in strata:
                  # Stratify each group and add together the indices.
                  group_train, group_test, group_val = rationed_split(group, train_ratio,
                                                                      test_ratio, val_ratio,
                                                                      rnd)
                  train_data += group_train
                  test_data += group_test
                  val_data += group_val
  
          splits = tuple(Dataset(d, self.fields)
                         for d in (train_data, val_data, test_data) if d)
  
          # In case the parent sort key isn't none
          if self.sort_key:
              for subset in splits:
                  subset.sort_key = self.sort_key
          return splits