Example #1
0
        private void FeatureCB_SelectedIndexChanged(object sender, EventArgs e)
        {
            ComboBox current       = sender as ComboBox;
            int      selectedIndex = current.SelectedIndex;

            FuzyChart.ChartAreas["ChartFuzzy"].AxisX.Title            = getNameAttribute(selectedIndex);
            FuzyChart.ChartAreas["ChartFuzzy"].AxisX.Minimum          = getMinAttribute(selectedIndex) - (getScatterAttribute(selectedIndex) / 20);
            FuzyChart.ChartAreas["ChartFuzzy"].AxisX.Maximum          = getMaxAttribute(selectedIndex) + (getScatterAttribute(selectedIndex) / 20);
            FuzyChart.ChartAreas["ChartFuzzy"].AxisX.IntervalAutoMode = IntervalAutoMode.VariableCount;
            FuzyChart.Series.Clear();

            addMinLine(selectedIndex);
            addMaxLine(selectedIndex);


            List <Term> sourceTerms = getTerm(selectedIndex);

            for (int i = 0; i < sourceTerms.Count(); i++)
            {
                int      indexRecognize = getIndexinTermSet(sourceTerms[i]) + 1;
                double[] paramss        = getTermParams(sourceTerms[i]);
                int      typeTerm       = gettypeTerm(sourceTerms[i]);

                drawTerm(sourceTerms[i], indexRecognize, typeTerm, NamesOfTerms[selectedIndex][i]);
            }

            FuzyChart.Invalidate();
            FuzyChart.Visible  = true;
            SaveToPngB.Enabled = true;
            //  MessageBox.Show(FuzyChart.Legends[0].CellColumns.Count.ToString());
        }
Example #2
0
 private void SaveToPngB_Click(object sender, EventArgs e)
 {
     if (saveFileDialog1.ShowDialog() == DialogResult.OK)
     {
         FuzyChart.SaveImage(saveFileDialog1.FileName, ChartImageFormat.EmfDual);
     }
 }