Class MekaInstances

  • All Implemented Interfaces:
    IMekaInstances, java.lang.Iterable<IMekaInstance>, java.util.Collection<IMekaInstance>, java.util.List<IMekaInstance>, org.api4.java.ai.ml.core.dataset.IDataset<IMekaInstance>, org.api4.java.ai.ml.core.dataset.IDataSource<IMekaInstance>, org.api4.java.ai.ml.core.dataset.schema.IInstanceSchemaHandler, org.api4.java.ai.ml.core.dataset.schema.ILabeledInstanceSchemaHandler, org.api4.java.ai.ml.core.dataset.supervised.ILabeledDataset<IMekaInstance>, org.api4.java.ai.ml.core.dataset.supervised.ILabeledDataSource<IMekaInstance>, org.api4.java.common.attributedobjects.IListDecorator<weka.core.Instances,​weka.core.Instance,​IMekaInstance>, org.api4.java.common.reconstruction.IReconstructible

    public class MekaInstances
    extends java.lang.Object
    implements IMekaInstances, org.api4.java.common.attributedobjects.IListDecorator<weka.core.Instances,​weka.core.Instance,​IMekaInstance>, org.api4.java.common.reconstruction.IReconstructible
    • Constructor Summary

      Constructors 
      Constructor Description
      MekaInstances​(org.api4.java.ai.ml.core.dataset.supervised.ILabeledDataset<? extends org.api4.java.ai.ml.core.dataset.supervised.ILabeledInstance> dataset)  
      MekaInstances​(weka.core.Instances dataset)  
      MekaInstances​(weka.core.Instances dataset, org.api4.java.ai.ml.core.dataset.schema.ILabeledInstanceSchema schema)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void addInstruction​(org.api4.java.common.reconstruction.IReconstructionInstruction instruction)  
      IMekaInstances createCopy()  
      IMekaInstances createEmptyCopy()  
      boolean equals​(java.lang.Object obj)  
      org.api4.java.common.reconstruction.IReconstructionPlan getConstructionPlan()  
      java.lang.reflect.Constructor<? extends IMekaInstance> getConstructorForDecoratingItems()  
      java.lang.Object[][] getFeatureMatrix()  
      int getFrequency​(IMekaInstance instance)  
      weka.core.Instances getInstances()  
      org.api4.java.ai.ml.core.dataset.schema.ILabeledInstanceSchema getInstanceSchema()  
      java.lang.Object[] getLabelVector()  
      weka.core.Instances getList()  
      java.lang.Class<weka.core.Instance> getTypeOfDecoratedItems()  
      java.lang.Class<IMekaInstance> getTypeOfDecoratingItems()  
      int hashCode()  
      void removeColumn​(int columnPos)  
      void removeColumn​(java.lang.String columnName)  
      void removeColumn​(org.api4.java.ai.ml.core.dataset.schema.attribute.IAttribute attribute)  
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

        clone, finalize, getClass, notify, notifyAll, wait, wait, wait
      • Methods inherited from interface java.util.Collection

        parallelStream, removeIf, stream, toArray
      • Methods inherited from interface org.api4.java.ai.ml.core.dataset.IDataset

        getClassOfInstances
      • Methods inherited from interface org.api4.java.ai.ml.core.dataset.schema.IInstanceSchemaHandler

        getAttribute, getListOfAttributes, getNumAttributes
      • Methods inherited from interface org.api4.java.ai.ml.core.dataset.schema.ILabeledInstanceSchemaHandler

        getLabelAttribute, getRelationName
      • Methods inherited from interface org.api4.java.common.attributedobjects.IListDecorator

        add, add, addAll, addAll, clear, contains, containsAll, get, getDecorationForElement, indexOf, isEmpty, iterator, lastIndexOf, listIterator, listIterator, remove, remove, removeAll, retainAll, set, size, subList, toArray, toArray
      • Methods inherited from interface java.lang.Iterable

        forEach
      • Methods inherited from interface java.util.List

        replaceAll, sort, spliterator
    • Constructor Detail

      • MekaInstances

        public MekaInstances​(weka.core.Instances dataset)
      • MekaInstances

        public MekaInstances​(weka.core.Instances dataset,
                             org.api4.java.ai.ml.core.dataset.schema.ILabeledInstanceSchema schema)
      • MekaInstances

        public MekaInstances​(org.api4.java.ai.ml.core.dataset.supervised.ILabeledDataset<? extends org.api4.java.ai.ml.core.dataset.supervised.ILabeledInstance> dataset)
    • Method Detail

      • removeColumn

        public void removeColumn​(int columnPos)
        Specified by:
        removeColumn in interface org.api4.java.ai.ml.core.dataset.IDataset<IMekaInstance>
      • createEmptyCopy

        public IMekaInstances createEmptyCopy()
                                       throws org.api4.java.ai.ml.core.exception.DatasetCreationException
        Specified by:
        createEmptyCopy in interface org.api4.java.ai.ml.core.dataset.IDataset<IMekaInstance>
        Specified by:
        createEmptyCopy in interface org.api4.java.ai.ml.core.dataset.IDataSource<IMekaInstance>
        Specified by:
        createEmptyCopy in interface org.api4.java.ai.ml.core.dataset.supervised.ILabeledDataset<IMekaInstance>
        Specified by:
        createEmptyCopy in interface IMekaInstances
        Throws:
        org.api4.java.ai.ml.core.exception.DatasetCreationException
      • hashCode

        public int hashCode()
        Specified by:
        hashCode in interface java.util.Collection<IMekaInstance>
        Specified by:
        hashCode in interface java.util.List<IMekaInstance>
        Overrides:
        hashCode in class java.lang.Object
      • equals

        public boolean equals​(java.lang.Object obj)
        Specified by:
        equals in interface java.util.Collection<IMekaInstance>
        Specified by:
        equals in interface java.util.List<IMekaInstance>
        Overrides:
        equals in class java.lang.Object
      • getFrequency

        public int getFrequency​(IMekaInstance instance)
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
      • getTypeOfDecoratingItems

        public java.lang.Class<IMekaInstance> getTypeOfDecoratingItems()
        Specified by:
        getTypeOfDecoratingItems in interface org.api4.java.common.attributedobjects.IListDecorator<weka.core.Instances,​weka.core.Instance,​IMekaInstance>
      • getTypeOfDecoratedItems

        public java.lang.Class<weka.core.Instance> getTypeOfDecoratedItems()
        Specified by:
        getTypeOfDecoratedItems in interface org.api4.java.common.attributedobjects.IListDecorator<weka.core.Instances,​weka.core.Instance,​IMekaInstance>
      • getConstructorForDecoratingItems

        public java.lang.reflect.Constructor<? extends IMekaInstance> getConstructorForDecoratingItems()
        Specified by:
        getConstructorForDecoratingItems in interface org.api4.java.common.attributedobjects.IListDecorator<weka.core.Instances,​weka.core.Instance,​IMekaInstance>
      • getList

        public weka.core.Instances getList()
        Specified by:
        getList in interface org.api4.java.common.attributedobjects.IListDecorator<weka.core.Instances,​weka.core.Instance,​IMekaInstance>
        Specified by:
        getList in interface IMekaInstances
      • createCopy

        public IMekaInstances createCopy()
                                  throws org.api4.java.ai.ml.core.exception.DatasetCreationException,
                                         java.lang.InterruptedException
        Specified by:
        createCopy in interface org.api4.java.ai.ml.core.dataset.IDataset<IMekaInstance>
        Specified by:
        createCopy in interface org.api4.java.ai.ml.core.dataset.IDataSource<IMekaInstance>
        Specified by:
        createCopy in interface IMekaInstances
        Throws:
        org.api4.java.ai.ml.core.exception.DatasetCreationException
        java.lang.InterruptedException
      • getLabelVector

        public java.lang.Object[] getLabelVector()
        Specified by:
        getLabelVector in interface org.api4.java.ai.ml.core.dataset.supervised.ILabeledDataset<IMekaInstance>
      • getInstanceSchema

        public org.api4.java.ai.ml.core.dataset.schema.ILabeledInstanceSchema getInstanceSchema()
        Specified by:
        getInstanceSchema in interface org.api4.java.ai.ml.core.dataset.schema.IInstanceSchemaHandler
        Specified by:
        getInstanceSchema in interface org.api4.java.ai.ml.core.dataset.schema.ILabeledInstanceSchemaHandler
      • getFeatureMatrix

        public java.lang.Object[][] getFeatureMatrix()
        Specified by:
        getFeatureMatrix in interface org.api4.java.ai.ml.core.dataset.IDataset<IMekaInstance>
      • removeColumn

        public void removeColumn​(java.lang.String columnName)
        Specified by:
        removeColumn in interface org.api4.java.ai.ml.core.dataset.IDataset<IMekaInstance>
      • removeColumn

        public void removeColumn​(org.api4.java.ai.ml.core.dataset.schema.attribute.IAttribute attribute)
        Specified by:
        removeColumn in interface org.api4.java.ai.ml.core.dataset.IDataset<IMekaInstance>
      • getConstructionPlan

        public org.api4.java.common.reconstruction.IReconstructionPlan getConstructionPlan()
        Specified by:
        getConstructionPlan in interface org.api4.java.common.reconstruction.IReconstructible
      • addInstruction

        public void addInstruction​(org.api4.java.common.reconstruction.IReconstructionInstruction instruction)
        Specified by:
        addInstruction in interface org.api4.java.common.reconstruction.IReconstructible