Interface IMultilabelCrossValidation

  • All Known Implementing Classes:
    RandomMultilabelCrossValidation

    public interface IMultilabelCrossValidation
    Represents an algorithm that realizes a split of a given multilabel instances in folds, given a seed, custom information about the split represented as a string, and the fold that is left out for testing.
    • Method Summary

      All Methods Instance Methods Abstract Methods Default Methods 
      Modifier and Type Method Description
      default java.lang.String generateSplittingInfo​(double... portions)
      Generate a string representation that represents only the split info part of the split string.
      default java.lang.String generateSplittingString​(double... portions)
      Generate a String that represents a split of a data set into portions from the given portions sizes (must add up to <1).
      java.lang.String getName()
      Get the name of the implementing multilabel cross validation technique.
      java.lang.String getSplitSeparator()
      Get the separator used to separate single portions of a split in a given splitInfo.
      weka.core.Instances getTestSplit​(weka.core.Instances data, int seed, int fold, java.lang.String splitInfo)
      Gets a test split from the given data based on the seed.
      weka.core.Instances getTrainSplit​(weka.core.Instances data, int seed, int fold, java.lang.String splitInfo)
      Gets a train split from the given data based on the seed.
    • Method Detail

      • getTestSplit

        weka.core.Instances getTestSplit​(weka.core.Instances data,
                                         int seed,
                                         int fold,
                                         java.lang.String splitInfo)
        Gets a test split from the given data based on the seed. The given fold is the test fold.
        Parameters:
        data - The data from which to derive the split
        seed - The seed possibly used by the implementation class to derive the split
        fold - The number of the fold which is the testing fold
        splitInfo - Information about the split for the class executing the split (e.g. portion sizes of folds)
        Returns:
        A test Instances derived from the given instances
      • getTrainSplit

        weka.core.Instances getTrainSplit​(weka.core.Instances data,
                                          int seed,
                                          int fold,
                                          java.lang.String splitInfo)
        Gets a train split from the given data based on the seed. The given fold is the test fold, which is the left out fold for this case.
        Parameters:
        data - The data from which to derive the split
        seed - The seed possibly used by the implementation class to derive the split
        fold - The number of the fold which is the testing fold (left out fold)
        splitInfo - Information about the split for the class executing the split (e.g. portion sized of folds)
        Returns:
        A train Instances derived from the given instances
      • generateSplittingString

        default java.lang.String generateSplittingString​(double... portions)
        Generate a String that represents a split of a data set into portions from the given portions sizes (must add up to <1).
        Parameters:
        portions - The portions sizes of the split
        Returns:
        The String representation of the split
      • generateSplittingInfo

        default java.lang.String generateSplittingInfo​(double... portions)
        Generate a string representation that represents only the split info part of the split string.
        Parameters:
        portions - portions sized of the split
        Returns:
        String representation of the splitInfo part of the split
      • getName

        java.lang.String getName()
        Get the name of the implementing multilabel cross validation technique.
        Returns:
        The name of the technique
      • getSplitSeparator

        java.lang.String getSplitSeparator()
        Get the separator used to separate single portions of a split in a given splitInfo. E.g. if the splitInfo represents data portions, it could be 0.7/0.3 with "/" being the split separator.
        Returns:
        The slit separator used by the specific implementation of this interface