Class Controller

java.lang.Object
es.upm.fi.cig.multictbnc.gui.Controller

public class Controller extends Object
Controller used to initialise the elements of the GUI and allow the interaction between the logic of the application and the GUI.
  • Constructor Details

    • Controller

      public Controller()
  • Method Details

    • changeDatasetReader

      public void changeDatasetReader()
      A dataset reader was selected in the comboBox. Shows its correspondent options.
    • changeDatasetReaderClassification

      public void changeDatasetReaderClassification()
      A dataset reader for the classification dataset was selected in the comboBox. Shows its correspondent options.
    • changeDatasetReaderClassificationStrategy

      public void changeDatasetReaderClassificationStrategy()
      An strategy for the extraction of sequences to classify was selected. Shows its correspondent options.
    • changeDatasetReaderStrategy

      public void changeDatasetReaderStrategy()
      An strategy for the extraction of sequences was selected. Shows its correspondent options.
    • changeModel

      public void changeModel()
      A model was selected in the comboBox. Shows its correspondent hyperparameters.
    • changeParameterLearningAlgBN

      public void changeParameterLearningAlgBN()
      A parameter learning algorithm for BNs was selected in the comboBox. Its corresponding parameters are shown.
    • changeParameterLearningAlgCTBN

      public void changeParameterLearningAlgCTBN()
      A parameter learning algorithm for CTBNs was selected in the comboBox. Shows its correspondent parameters.
    • changeScoreFunction

      public void changeScoreFunction()
      A score function was selected in the comboBox. Shows its correspondent parameters.
    • changeStructureLearningAlg

      public void changeStructureLearningAlg()
      A structure learning algorithm was selected in the comboBox. Shows its correspondent parameters.
    • classify

      public void classify()
      Performs classification over a provided dataset with a previously trained model.
    • datasetClassificationModified

      public void datasetClassificationModified()
      The information of the dataset used for classification was modified, so its DatasetReader is warned. This is useful to avoid the reloading of the same dataset.
    • datasetModified

      public void datasetModified()
      The information of the dataset for training/evaluation was modified, so its DatasetReader is warned. This is useful to avoid the reloading of the same dataset.
    • evaluate

      public void evaluate()
      Evaluates the selected model.
    • initialize

      public void initialize()
      Initialises the controller.
    • selectCrossValidation

      public void selectCrossValidation()
      Cross-validation method was selected. Shows its correspondent parameters.
    • selectHoldOutValidation

      public void selectHoldOutValidation()
      Hold-out-validation method was selected. Shows its correspondent parameters.
    • selectTestDataset

      public void selectTestDataset()
      Test dataset method was selected. Shows its correspondent parameters.
    • setFolderDataset

      public void setFolderDataset() throws FileNotFoundException
      Opens a dialog to select the folder where the dataset for training and evaluation is located.
      Throws:
      FileNotFoundException - if the provided files were not found
    • setFolderDatasetClassification

      public void setFolderDatasetClassification() throws FileNotFoundException
      Opens a dialog to select the folder where the dataset on which classification is performed is located.
      Throws:
      FileNotFoundException - if the provided files were not found
    • setFolderTestDataset

      public void setFolderTestDataset() throws FileNotFoundException
      Opens a dialog to select the folder where the dataset for testing is located.
      Throws:
      FileNotFoundException - if the provided files were not found
    • setStage

      public void setStage(javafx.stage.Stage stage)
      Establishes the stage used by the application to show dialogs.
      Parameters:
      stage - a Stage
    • trainModel

      public void trainModel()
      Trains the selected model.