Statistical Process Control 簡介
統計過程控制(Statistical Process Control)是一種借助數理統計方法的過程控制工具。它對生産過程進行分析評價,根據回報資訊及時發現系統性因素出現的征兆,并采取措施消除其影響,使過程維持在僅受随機性因素影響的受控狀态,以達到控制品質的目的。
在企業的生産制造過程中,我們常常需要采集生産資料,然後對資料進行處理,最後對處理好的資料、排程指令或者決策以報表和資料大屏等方式進行呈現,給與上司層合理科學的決策建議。
本項目主要采用Windows 10 + Visual Studio 2019 + Windows窗體應用(.Net Framework)實作六西格瑪模式資料決策和Chart報表子產品展示,主要用于繼續的學習和研究。
六西格瑪核心算法
算法參考公式 點我下載下傳 ,利用算法對資料進行處理後,結合Chart子產品即可實作Chart報表的展示。
Chart子產品核心代碼
1 //定義圖表區域
2 this.chartMain.ChartAreas.Clear();
3 ChartArea chartArea1 = new ChartArea("C1");
4 this.chartMain.ChartAreas.Add(chartArea1);
5 //定義存儲和顯示點的容器
6 this.chartMain.Series.Clear();
7 Series series1 = new Series("S1");
8 series1.ChartArea = "C1";
9 this.chartMain.Series.Add(series1);
10 //設定圖表顯示樣式
11 this.chartMain.ChartAreas[0].AxisY.Minimum = 0;
12 this.chartMain.ChartAreas[0].AxisY.Maximum = 100;
13 this.chartMain.ChartAreas[0].AxisX.Interval = 5;
14 this.chartMain.ChartAreas[0].AxisX.MajorGrid.LineColor = System.Drawing.Color.Silver;
15 this.chartMain.ChartAreas[0].AxisY.MajorGrid.LineColor = System.Drawing.Color.Silver;
16 //設定标題
17 this.chartMain.Titles.Clear();
18 this.chartMain.Titles.Add("S01");
19 this.chartMain.Titles[0].Text = "XXX顯示";
20 this.chartMain.Titles[0].ForeColor = Color.Green;
21 this.chartMain.Titles[0].Font = new System.Drawing.Font("Microsoft Sans Serif", 12F);
22 //設定圖表顯示樣式
23 this.chartMain.Series[0].Color = Color.Red;
24 if (this.cmbChartType.Text.ToString() == "折線圖")
25 {
26 this.chartMain.Titles[0].Text = string.Format("SPC子產品-[{0}]功能測試", "折線圖");
27 this.chartMain.Series[0].ChartType = SeriesChartType.Line;
28 }
29 else if (this.cmbChartType.Text.ToString() == "波形圖")
30 {
31 this.chartMain.Titles[0].Text = string.Format("SPC子產品-[{0}]功能測試", "波形圖");
32 this.chartMain.Series[0].ChartType = SeriesChartType.Spline;
33 }
34 this.chartMain.Series[0].Points.Clear();
View Code
實作效果
作者:Jeremy.Wu
出處:https://www.cnblogs.com/jeremywucnblog/
本文版權歸作者和部落格園共有,歡迎轉載,但未經作者同意必須保留此段聲明,且在文章頁面明顯位置給出原文連接配接,否則保留追究法律責任的權利。