Ignore:
Timestamp:
04/27/16 17:17:00 (5 years ago)
Author:
bburlacu
Message:

#2288: Remove TinySet.cs in favor of a more general method for generating k-combinations. Improve target variation experiment generation. Refactored code and avoided some corner case exceptions.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/HeuristicLab.VariableInteractionNetworks/HeuristicLab.VariableInteractionNetworks/3.3/CreateTargetVariationExperimentDialog.Designer.cs

    r13788 r13806  
    3333      this.cancelButton = new System.Windows.Forms.Button();
    3434      this.okButton = new System.Windows.Forms.Button();
    35       this.binomialCoeffNumericUpDown = new System.Windows.Forms.NumericUpDown();
     35      this.combinationGroupSizeNumericUpDown = new System.Windows.Forms.NumericUpDown();
    3636      this.label1 = new System.Windows.Forms.Label();
    37       this.label2 = new System.Windows.Forms.Label();
     37      this.warningLabel = new System.Windows.Forms.Label();
    3838      ((System.ComponentModel.ISupportInitialize)(this.repetitionsNumericUpDown)).BeginInit();
    39       ((System.ComponentModel.ISupportInitialize)(this.binomialCoeffNumericUpDown)).BeginInit();
     39      ((System.ComponentModel.ISupportInitialize)(this.combinationGroupSizeNumericUpDown)).BeginInit();
    4040      this.SuspendLayout();
    4141      //
     
    9898      this.okButton.Click += new System.EventHandler(this.okButton_Click);
    9999      //
    100       // binomialCoeffNumericUpDown
     100      // combinationGroupSizeNumericUpDown
    101101      //
    102       this.binomialCoeffNumericUpDown.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
     102      this.combinationGroupSizeNumericUpDown.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
    103103            | System.Windows.Forms.AnchorStyles.Right)));
    104       this.binomialCoeffNumericUpDown.Location = new System.Drawing.Point(128, 38);
    105       this.binomialCoeffNumericUpDown.Maximum = new decimal(new int[] {
     104      this.combinationGroupSizeNumericUpDown.Location = new System.Drawing.Point(128, 38);
     105      this.combinationGroupSizeNumericUpDown.Maximum = new decimal(new int[] {
    106106            1000000,
    107107            0,
    108108            0,
    109109            0});
    110       this.binomialCoeffNumericUpDown.Minimum = new decimal(new int[] {
     110      this.combinationGroupSizeNumericUpDown.Minimum = new decimal(new int[] {
    111111            1,
    112112            0,
    113113            0,
    114114            0});
    115       this.binomialCoeffNumericUpDown.Name = "binomialCoeffNumericUpDown";
    116       this.binomialCoeffNumericUpDown.Size = new System.Drawing.Size(185, 20);
    117       this.binomialCoeffNumericUpDown.TabIndex = 4;
    118       this.binomialCoeffNumericUpDown.ThousandsSeparator = true;
    119       this.binomialCoeffNumericUpDown.Value = new decimal(new int[] {
     115      this.combinationGroupSizeNumericUpDown.Name = "combinationGroupSizeNumericUpDown";
     116      this.combinationGroupSizeNumericUpDown.Size = new System.Drawing.Size(185, 20);
     117      this.combinationGroupSizeNumericUpDown.TabIndex = 4;
     118      this.combinationGroupSizeNumericUpDown.ThousandsSeparator = true;
     119      this.combinationGroupSizeNumericUpDown.Value = new decimal(new int[] {
    120120            10,
    121121            0,
    122122            0,
    123123            0});
    124       this.binomialCoeffNumericUpDown.Validated += new System.EventHandler(this.binomialCoefficientNumericUpDown_Validated);
     124      this.combinationGroupSizeNumericUpDown.ValueChanged += new System.EventHandler(this.combinationGroupSizeNumericUpDown_Validated);
     125      this.combinationGroupSizeNumericUpDown.Validating += new System.ComponentModel.CancelEventHandler(this.combinationGroupSizeNumericUpDown_Validating);
     126      this.combinationGroupSizeNumericUpDown.Validated += new System.EventHandler(this.combinationGroupSizeNumericUpDown_Validated);
    125127      //
    126128      // label1
     
    129131      this.label1.Location = new System.Drawing.Point(26, 40);
    130132      this.label1.Name = "label1";
    131       this.label1.Size = new System.Drawing.Size(79, 13);
     133      this.label1.Size = new System.Drawing.Size(60, 13);
    132134      this.label1.TabIndex = 5;
    133       this.label1.Text = "&Binomial coeff.:";
     135      this.label1.Text = "&Group size:";
    134136      //
    135       // label2
     137      // warningLabel
    136138      //
    137       this.label2.ForeColor = System.Drawing.Color.Red;
    138       this.label2.Location = new System.Drawing.Point(26, 67);
    139       this.label2.Name = "label2";
    140       this.label2.Size = new System.Drawing.Size(287, 50);
    141       this.label2.TabIndex = 5;
    142       this.label2.Text = "Warning: depending on the binomial coefficient and the number of variables, this " +
    143     "can create very large experiments. ";
     139      this.warningLabel.ForeColor = System.Drawing.Color.Red;
     140      this.warningLabel.Location = new System.Drawing.Point(26, 67);
     141      this.warningLabel.Name = "warningLabel";
     142      this.warningLabel.Size = new System.Drawing.Size(287, 50);
     143      this.warningLabel.TabIndex = 5;
     144      this.warningLabel.TextAlign = System.Drawing.ContentAlignment.TopCenter;
    144145      //
    145146      // CreateTargetVariationExperimentDialog
     
    152153      this.Controls.Add(this.okButton);
    153154      this.Controls.Add(this.cancelButton);
    154       this.Controls.Add(this.label2);
     155      this.Controls.Add(this.warningLabel);
    155156      this.Controls.Add(this.label1);
    156157      this.Controls.Add(this.repetitionsLabel);
    157       this.Controls.Add(this.binomialCoeffNumericUpDown);
     158      this.Controls.Add(this.combinationGroupSizeNumericUpDown);
    158159      this.Controls.Add(this.repetitionsNumericUpDown);
    159160      this.Name = "CreateTargetVariationExperimentDialog";
    160161      this.Text = "Create Target Variation Experiment";
    161162      ((System.ComponentModel.ISupportInitialize)(this.repetitionsNumericUpDown)).EndInit();
    162       ((System.ComponentModel.ISupportInitialize)(this.binomialCoeffNumericUpDown)).EndInit();
     163      ((System.ComponentModel.ISupportInitialize)(this.combinationGroupSizeNumericUpDown)).EndInit();
    163164      this.ResumeLayout(false);
    164165      this.PerformLayout();
     
    172173        private System.Windows.Forms.Button cancelButton;
    173174        private System.Windows.Forms.Button okButton;
    174     private System.Windows.Forms.NumericUpDown binomialCoeffNumericUpDown;
     175    private System.Windows.Forms.NumericUpDown combinationGroupSizeNumericUpDown;
    175176    private System.Windows.Forms.Label label1;
    176     private System.Windows.Forms.Label label2;
     177    private System.Windows.Forms.Label warningLabel;
    177178  }
    178179}
Note: See TracChangeset for help on using the changeset viewer.