{"id":357,"date":"2013-12-06T14:49:10","date_gmt":"2013-12-06T19:49:10","guid":{"rendered":"http:\/\/homepages.uc.edu\/~yaozo\/wordpress\/?p=357"},"modified":"2013-12-06T14:49:10","modified_gmt":"2013-12-06T19:49:10","slug":"matlab-fuzzy-clustering","status":"publish","type":"post","link":"https:\/\/zhuoyao.net\/index.php\/2013\/12\/06\/matlab-fuzzy-clustering\/","title":{"rendered":"Matlab Fuzzy Clustering"},"content":{"rendered":"<div itemprop=\"content\">\n<h3 id=\"bq_z_k1\">What Is Data Clustering?<\/h3>\n<p>Clustering of numerical data forms the basis of many classification and system modeling algorithms. The purpose of\u00a0<a name=\"zmw57dd0e7117\"><\/a>clustering is to identify natural groupings of data from a large data set to produce a concise representation of a system&#8217;s behavior.<\/p>\n<p>Fuzzy Logic Toolbox\u2122 tools allow you to find clusters in input-output training data. You can use the cluster information to generate a Sugeno-type fuzzy inference system that best models the data behavior using a minimum number of rules. The rules partition themselves according to the fuzzy qualities associated with each of the data clusters. Use the command-line function,\u00a0<tt>genfis2<\/tt>\u00a0to automatically accomplish this type of FIS generation.<\/p>\n<p><a name=\"btf9132\"><\/a><\/p>\n<h4 id=\"btf9132\">References<\/h4>\n<p><a name=\"bqo8_73\"><\/a>[1] Bezdec, J.C.,\u00a0<i>Pattern Recognition with Fuzzy Objective Function Algorithms,\u00a0<\/i>Plenum Press, New York, 1981.<\/p>\n<p><a name=\"bqo9aas\"><\/a>[2] Chiu, S., &#8220;Fuzzy Model Identification Based on Cluster Estimation,&#8221;\u00a0<i>Journal of Intelligent &amp; Fuzzy Systems<\/i>, Vol. 2, No. 3, Spet. 1994.<\/p>\n<\/div>\n<div itemprop=\"content\"><a name=\"FP43419\"><\/a><\/p>\n<h3 id=\"FP43419\">Fuzzy C-Means Clustering<\/h3>\n<p><em>Fuzzy c-means<\/em>\u00a0(FCM) is a data clustering technique wherein each data point belongs to a cluster to some degree that is specified by a membership grade. This technique was originally introduced by Jim Bezdek in 1981<a href=\"http:\/\/www.mathworks.com\/help\/fuzzy\/fuzzy-clustering.html#bqo8_73\">[1]<\/a>\u00a0as an improvement on earlier clustering methods. It provides a method that shows how to group data points that populate some multidimensional space into a specific number of different clusters.<\/p>\n<p>Fuzzy Logic Toolbox command line function\u00a0<tt>fcm<\/tt>\u00a0starts with an initial guess for the cluster centers, which are intended to mark the mean location of each cluster. The initial guess for these cluster centers is most likely incorrect. Additionally,\u00a0<tt>fcm<\/tt>\u00a0assigns every data point a membership grade for each cluster. By iteratively updating the cluster centers and the membership grades for each data point,\u00a0<tt>fcm<\/tt>iteratively moves the cluster centers to the right location within a data set. This iteration is based on minimizing an objective function that represents the distance from any given data point to a cluster center weighted by that data point&#8217;s membership grade.<\/p>\n<p>The command line function\u00a0<tt>fcm<\/tt>\u00a0outputs a list of cluster centers and several membership grades for each data point. You can use the information returned by\u00a0<tt>fcm<\/tt>\u00a0to help you build a fuzzy inference system by creating membership functions to represent the fuzzy qualities of each cluster.<\/p>\n<\/div>\n<div itemprop=\"content\"><a name=\"FP2044\"><\/a><\/p>\n<h3 id=\"FP2044\">Cluster Quasi-Random Data Using Fuzzy C-Means Clustering<\/h3>\n<p>You can use quasi-random two-dimensional data to illustrate how FCM clustering works. To load the data set and plot it, type the following commands:<\/p>\n<pre>load fcmdata.dat\nplot(fcmdata(:,1),fcmdata(:,2),'o')<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.mathworks.com\/help\/releases\/R2013b\/fuzzy\/fcm_data.gif\" width=\"568\" height=\"495\" \/><\/p>\n<p>Next, invoke the command-line function\u00a0<tt>fcm<\/tt>\u00a0to find two clusters in this data set until the objective function is no longer decreasing much at all.<\/p>\n<pre>[center,U,objFcn] = fcm(fcmdata,2);<\/pre>\n<p>Here, the variable\u00a0<tt>center<\/tt>\u00a0contains the coordinates of the two cluster centers,\u00a0<tt>U<\/tt>\u00a0contains the membership grades for each of the data points, and\u00a0<tt>objFcn<\/tt>\u00a0contains a history of the objective function across the iterations.<\/p>\n<p>This command returns the following result:<\/p>\n<pre>Iteration count = 1, obj. fcn = 8.794048\nIteration count = 2, obj. fcn = 6.986628\n.....\nIteration count = 12, obj. fcn = 3.797430<\/pre>\n<p>The\u00a0<tt>fcm<\/tt>\u00a0function is an iteration loop built on top of the following routines:<\/p>\n<ul type=\"disc\">\n<li><tt><a name=\"zmw57dd0e7216\"><\/a>initfcm<\/tt>\u00a0\u2014 initializes the problem<\/li>\n<li><tt><a name=\"zmw57dd0e7225\"><\/a>distfcm<\/tt>\u00a0\u2014 performs Euclidean distance calculation<\/li>\n<li><tt>stepfcm<\/tt>\u00a0\u2014 performs one iteration of clustering<\/li>\n<\/ul>\n<p>To view the progress of the clustering, plot the objective function by typing the following commands:<\/p>\n<pre>figure\nplot(objFcn)\ntitle('Objective Function Values')\nxlabel('Iteration Count')\nylabel('Objective Function Value')<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.mathworks.com\/help\/releases\/R2013b\/fuzzy\/fcm_objfcn.gif\" width=\"568\" height=\"495\" \/><\/p>\n<p>Finally, plot the two cluster centers found by the\u00a0<tt>fcm<\/tt>\u00a0function using the following code:<\/p>\n<pre>maxU = max(U);\nindex1 = find(U(1, :) == maxU);\nindex2 = find(U(2, :) == maxU);\nfigure\nline(fcmdata(index1, 1), fcmdata(index1, 2), 'linestyle',...\n'none','marker', 'o','color','g');\nline(fcmdata(index2,1),fcmdata(index2,2),'linestyle',...\n'none','marker', 'x','color','r');\nhold on\nplot(center(1,1),center(1,2),'ko','markersize',15,'LineWidth',2)\nplot(center(2,1),center(2,2),'kx','markersize',15,'LineWidth',2)<\/pre>\n<p><a name=\"zmw57dd0e7254\"><\/a><\/p>\n<table summary=\"Note\" border=\"1\" cellspacing=\"0\" cellpadding=\"5\">\n<tbody>\n<tr>\n<td><b>Note:<\/b>\u00a0\u00a0 Every time you run this example, the\u00a0<tt>fcm<\/tt>\u00a0function initializes with different initial conditions. This behavior swaps the order in which the cluster centers are computed and plotted.<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>In the following figure, the large characters indicate cluster centers.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.mathworks.com\/help\/releases\/R2013b\/fuzzy\/fcm_clusters.gif\" width=\"568\" height=\"495\" \/><\/p>\n<\/div>\n<div itemprop=\"content\"><a name=\"FP2434\"><\/a><\/p>\n<h3 id=\"FP2434\">Subtractive Clustering<\/h3>\n<p><a name=\"zmw57dd0e7272\"><\/a>If you do not have a clear idea how many clusters there should be for a given set of data,\u00a0<em>Subtractive clustering<\/em>,\u00a0<a href=\"http:\/\/www.mathworks.com\/help\/fuzzy\/fuzzy-clustering.html#bqo9aas\">[2]<\/a><em>,<\/em>\u00a0is a fast, one-pass algorithm for estimating the number of clusters and the cluster centers in a set of data. The cluster estimates, which are obtained from the<tt>subclust<\/tt>\u00a0function, can be used to initialize iterative optimization-based clustering methods (<tt>fcm<\/tt>) and model identification methods (like<tt>anfis<\/tt>). The\u00a0<tt>subclust<\/tt>\u00a0function finds the clusters by using the subtractive clustering method.<\/p>\n<p>The\u00a0<tt>genfis2<\/tt>\u00a0function builds upon the\u00a0<tt>subclust<\/tt>\u00a0function to provide a fast, one-pass method to take input-output training data and generate a\u00a0<a name=\"zmw57dd0e7304\"><\/a>Sugeno-type fuzzy inference system that models the data behavior.<\/p>\n<\/div>\n<div itemprop=\"content\"><a name=\"FP998\"><\/a><\/p>\n<h3 id=\"FP998\">Model Suburban Commuting Using Subtractive Clustering<\/h3>\n<p>In this example, you apply the\u00a0<tt>genfis2<\/tt>\u00a0function to model the relationship between the number of automobile trips generated from an area and the area&#8217;s demographics. Demographic and trip data are from 100 traffic analysis zones in New Castle County, Delaware. Five demographic factors are considered: population, number of dwelling units, vehicle ownership, median household income, and total employment. Hence, the model has five input variables and one output variable.<\/p>\n<p>Load and plot the data by typing the following commands:<\/p>\n<pre>clear\nclose all\nmytripdata\nsubplot(2,1,1), plot(datin)\nsubplot(2,1,2), plot(datout)<\/pre>\n<p>The next figure displays the input and the output data.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.mathworks.com\/help\/releases\/R2013b\/fuzzy\/clustdat.gif\" width=\"568\" height=\"495\" \/><\/p>\n<p>The function\u00a0<tt>tripdata<\/tt>\u00a0creates several variables in the workspace. Of the original 100 data points, use 75 data points as training data (<tt>datin<\/tt>\u00a0and\u00a0<tt>datout<\/tt>) and 25 data points as checking data, (as well as for test data to validate the model). The checking data input\/output pairs are denoted by\u00a0<tt>chkdatin<\/tt>\u00a0and\u00a0<tt>chkdatout<\/tt>.<\/p>\n<p>Use the\u00a0<tt>genfis2<\/tt>\u00a0function to generate a model from data using clustering.\u00a0<tt>genfis2<\/tt>\u00a0requires you to specify a cluster radius. The cluster radius indicates the range of influence of a cluster when you consider the data space as a unit hypercube. Specifying a small cluster radius usually yields many small clusters in the data, and results in many rules. Specifying a large cluster radius usually yields a few large clusters in the data, and results in fewer rules. The cluster radius is specified as the third argument of\u00a0<tt>genfis2<\/tt>. The following syntax calls the\u00a0<tt>genfis2<\/tt>\u00a0function using a cluster radius of 0.5.<\/p>\n<pre> fismat=genfis2(datin,datout,0.5);<\/pre>\n<p>The\u00a0<tt>genfis2<\/tt>\u00a0function is a fast, one-pass method that does not perform any iterative optimization. A FIS structure is returned; the model type for the FIS structure is a first order Sugeno model with three rules.<\/p>\n<p>Use the following commands to verify the model. Here,\u00a0<tt>trnRMSE<\/tt>\u00a0is the root mean square error of the system generated by the training data.<\/p>\n<pre>fuzout=evalfis(datin,fismat);\ntrnRMSE=norm(fuzout-datout)\/sqrt(length(fuzout))<\/pre>\n<p>These commands return the following result:<\/p>\n<pre>trnRMSE =\n\t  0.5276<\/pre>\n<p>Next, apply the test data to the FIS to validate the model. In this example, the checking data is used for both checking and testing the FIS parameters. Here,\u00a0<tt>chkRMSE<\/tt>\u00a0is the root mean square error of the system generated by the checking data.<\/p>\n<pre>chkfuzout=evalfis(chkdatin,fismat);\nchkRMSE=norm(chkfuzout-chkdatout)\/sqrt(length(chkfuzout))<\/pre>\n<p>These commands return the following result:<\/p>\n<pre>chkRMSE =\n\t  0.6179<\/pre>\n<p>Use the following commands to plot the output of the model\u00a0<tt>chkfuzout<\/tt>\u00a0against the checking data\u00a0<tt>chkdatout<\/tt>.<\/p>\n<pre>figure\nplot(chkdatout)\nhold on\nplot(chkfuzout,'o')\nhold off<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.mathworks.com\/help\/releases\/R2013b\/fuzzy\/clustchk.gif\" width=\"568\" height=\"495\" \/><\/p>\n<p>The model output and checking data are shown as\u00a0<em>circles<\/em>\u00a0and solid blue<em>\u00a0line<\/em>, respectively. The plot shows the model does not perform well on the checking data.<\/p>\n<p>At this point, you can use the optimization capability of\u00a0<tt>anfis<\/tt>\u00a0to improve the model. First, try using a relatively short\u00a0<tt>anfis<\/tt>\u00a0training (20 epochs) without implementing the checking data option, and then test the resulting FIS model against the testing data. To perform the optimization, type the following command:<\/p>\n<pre>fismat2=anfis([datin datout],fismat,[20 0 0.1]);<\/pre>\n<p>Here,\u00a0<tt>20<\/tt>\u00a0is the number of epochs,\u00a0<tt>0<\/tt>\u00a0is the training error goal, and\u00a0<tt>0.1<\/tt>\u00a0is the initial step size.<\/p>\n<p>This command returns the following result:<\/p>\n<pre>ANFIS info: \n\tNumber of nodes: 44\n\tNumber of linear parameters: 18\n\tNumber of nonlinear parameters: 30\n\tTotal number of parameters: 48\n\tNumber of training data pairs: 75\n\tNumber of checking data pairs: 0\n\tNumber of fuzzy rules: 3\n\nStart training ANFIS ...\n\n 1 \t 0.527607\n.\n.\n 20 \t 0.420275\n\nDesignated epoch number reached --&gt; ANFIS training completed at epoch 20.<\/pre>\n<p>After the training is done, validate the model by typing the following commands:<\/p>\n<pre>fuzout2=evalfis(datin,fismat2);\ntrnRMSE2=norm(fuzout2-datout)\/sqrt(length(fuzout2))\nchkfuzout2=evalfis(chkdatin,fismat2);\nchkRMSE2=norm(chkfuzout2-chkdatout)\/sqrt(length(chkfuzout2))<\/pre>\n<p>These commands return the following results:<\/p>\n<pre>trnRMSE2 =\n\t  0.4203\nchkRMSE2 =\n\t  0.5894<\/pre>\n<p>The model has improved a lot with respect to the training data, but only a little with respect to the checking data. Plot the improved model output obtained using\u00a0<tt>anfis<\/tt>\u00a0against the testing data by typing the following commands:<\/p>\n<pre>figure\nplot(chkdatout)\nhold on\nplot(chkfuzout2,'o')\nhold off<\/pre>\n<p>The next figure shows the model output.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.mathworks.com\/help\/releases\/R2013b\/fuzzy\/clustchkanfis.gif\" width=\"568\" height=\"495\" \/><\/p>\n<p>The model output and checking data are shown as\u00a0<em>circles<\/em>\u00a0and solid blue\u00a0<em>line<\/em>, respectively. This plot shows that\u00a0<tt>genfis2<\/tt>\u00a0can be used as a stand-alone, fast method for generating a fuzzy model from data, or as a preprocessor to\u00a0<tt>anfis<\/tt>\u00a0for determining the initial rules. An important advantage of using a clustering method to find rules is that the resultant rules are more tailored to the input data than they are in a FIS generated without clustering. This reduces the problem of an excessive propagation of rules when the input data has a high dimension.<\/p>\n<p><a name=\"btf8dh2-1\"><\/a><\/p>\n<h4 id=\"btf8dh2-1\">Overfitting<\/h4>\n<p>Overfitting can be detected when the checking error starts to increase while the training error continues to decrease.<\/p>\n<p>To check the model for overfitting, use\u00a0<tt>anfis<\/tt>\u00a0with the checking data option to train the model for 200 epochs. Here,\u00a0<tt>fismat3<\/tt>\u00a0is the FIS structure when the training error reaches a minimum.\u00a0<tt>fismat4<\/tt>\u00a0is the snapshot FIS structure taken when the checking data error reaches a minimum.<\/p>\n<pre>[fismat3,trnErr,stepSize,fismat4,chkErr]= ...\n   anfis([datin datout],fismat,[200 0 0.1],[], ...\n   [chkdatin chkdatout]);<\/pre>\n<p>This command returns a list of output arguments. The output arguments show a history of the step sizes, the RMSE using the training data, and the RMSE using the checking data for each training epoch.<\/p>\n<pre> 1 \t 0.527607 \t 0.617875\n 2 \t 0.513727 \t 0.615487\n .\n .\n 200 \t 0.326576 \t 0.601531\n\nDesignated epoch number reached --&gt; ANFIS training completed at\nepoch 200.<\/pre>\n<p>After the training completes, validate the model by typing the following commands:<\/p>\n<pre>fuzout4=evalfis(datin,fismat4);\ntrnRMSE4=norm(fuzout4-datout)\/sqrt(length(fuzout4))\nchkfuzout4=evalfis(chkdatin,fismat4);\nchkRMSE4=norm(chkfuzout4-chkdatout)\/sqrt(length(chkfuzout4))<\/pre>\n<p>These commands return the following results:<\/p>\n<pre>trnRMSE4 =\n   0.3393\nchkRMSE4 =\n    0.5833<\/pre>\n<p>The error with the training data is the lowest thus far, and the error with the checking data is also slightly lower than before. This result suggests perhaps there is an overfit of the system to the training data. Overfitting occurs when you fit the fuzzy system to the training data so well that it no longer does a very good job of fitting the checking data. The result is a loss of generality.<\/p>\n<p>To view the improved model output, plot the model output against the checking data by typing the following commands:<\/p>\n<pre>figure\nplot(chkdatout)\nhold on\nplot(chkfuzout4,'o')\nhold off<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.mathworks.com\/help\/releases\/R2013b\/fuzzy\/clustchk_min_chkerr.gif\" width=\"568\" height=\"495\" \/><\/p>\n<p>The model output and checking data are shown as\u00a0<em>circles<\/em>\u00a0and solid blue\u00a0<em>line<\/em>, respectively.<\/p>\n<p>Next, plot the training error\u00a0<tt>trnErr<\/tt>\u00a0by typing the following commands:<\/p>\n<pre>figure\nplot(trnErr)\ntitle('Training Error')\nxlabel('Number of Epochs')\nylabel('Training Error')<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.mathworks.com\/help\/releases\/R2013b\/fuzzy\/clustchk_trnerror.gif\" width=\"568\" height=\"495\" \/><\/p>\n<p>This plot shows that the training error settles at about the 60th epoch point.<\/p>\n<p>Plot the checking error\u00a0<tt>chkErr<\/tt>\u00a0by typing the following commands:<\/p>\n<pre>figure\nplot(chkErr)\ntitle('Checking Error')\nxlabel('Number of Epochs')\nylabel('Checking Error')<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.mathworks.com\/help\/releases\/R2013b\/fuzzy\/clustchk_chk_error.gif\" width=\"568\" height=\"495\" \/><\/p>\n<p>The plot shows that the smallest value of the checking data error occurs at the 52nd epoch, after which it increases slightly even as\u00a0<tt>anfis<\/tt>continues to minimize the error against the training data all the way to the 200th epoch. Depending on the specified error tolerance, the plot also indicates the model&#8217;s ability to generalize the test data.<\/p>\n<p>You can also compare the output of\u00a0<tt>fismat2<\/tt>\u00a0and\u00a0<tt>fistmat4<\/tt>\u00a0against the checking data\u00a0<tt>chkdatout<\/tt>\u00a0by typing the following commands:<\/p>\n<pre>figure\nplot(chkdatout)\nhold on\nplot(chkfuzout4,'ob')\nplot(chkfuzout2,'+r')<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.mathworks.com\/help\/releases\/R2013b\/fuzzy\/clustchk_compare_chkdat.gif\" width=\"568\" height=\"495\" \/><\/p>\n<\/div>\n<div itemprop=\"content\"><a name=\"bq_anos\"><\/a><\/p>\n<h3 id=\"bq_anos\">Data Clustering Using the Clustering Tool<\/h3>\n<p>The Clustering GUI Tool implements the fuzzy data clustering functions\u00a0<tt>fcm<\/tt>\u00a0and\u00a0<tt>subclust<\/tt>\u00a0and lets you perform clustering on the data. For more information on the clustering functions, see\u00a0<a href=\"http:\/\/www.mathworks.com\/help\/fuzzy\/fuzzy-clustering.html#FP43419\">Fuzzy C-Means Clustering<\/a>\u00a0and\u00a0<a href=\"http:\/\/www.mathworks.com\/help\/fuzzy\/fuzzy-clustering.html#FP2434\">Subtractive Clustering<\/a>.<\/p>\n<p>To start the GUI, type the following command at the MATLAB<sup>\u00ae<\/sup>\u00a0command prompt:<tt><a name=\"zmw57dd0e7588\"><\/a><\/tt><\/p>\n<pre>findcluster<\/pre>\n<p>The Clustering GUI Tool shown\u00a0<a name=\"zmw57dd0e7596\"><\/a>in the next figure.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.mathworks.com\/help\/releases\/R2013b\/fuzzy\/findcluster2.gif\" width=\"568\" height=\"468\" \/><\/p>\n<p>This GUI lets you perform the following tasks:<\/p>\n<ol type=\"1\">\n<li>Load and plot the data.<\/li>\n<li>Start the clustering.<\/li>\n<li>Save the cluster center.<\/li>\n<\/ol>\n<p>Access the online help topics by clicking\u00a0<b>Info<\/b>\u00a0or using the\u00a0<b>Help\u00a0<\/b>menu in the Clustering GUI.<\/p>\n<p><a name=\"bq_aohr\"><\/a><\/p>\n<h4 id=\"bq_aohr\">Loading and Plotting the Data<\/h4>\n<p>To load a data set in the GUI, perform either of the following actions:<\/p>\n<ul type=\"disc\">\n<li>Click\u00a0<b>Load Data<\/b>, and select the file containing the data.<\/li>\n<li>Open the GUI with a data set directly by invoking\u00a0<tt>findcluster<\/tt>\u00a0with the data set as the argument, in the MATLAB Command Window.\n<p>The data set must have the extension<tt>.dat<\/tt>. For example, to load the data set,\u00a0<tt>clusterdemo.dat<\/tt>, type<tt>findcluster('clusterdemo.dat')<\/tt>.<\/li>\n<\/ul>\n<p>The Clustering GUI Tool works on multidimensional data sets, but displays only two of those dimensions on the plot. To select other dimensions in the data set for plotting, you can use the drop-down lists under\u00a0<b>X-axis<\/b>\u00a0and\u00a0<b>Y-axis<\/b>.<\/p>\n<p><a name=\"bq_apw4\"><\/a><\/p>\n<h4 id=\"bq_apw4\">Starting the Clustering<\/h4>\n<p>To start clustering the data:<\/p>\n<ol type=\"1\">\n<li>Choose the clustering function\u00a0<tt>fcm<\/tt>\u00a0(fuzzy C-Means clustering) or\u00a0<tt>subtractiv<\/tt>\u00a0(subtractive clustering) from the drop-down menu under\u00a0<b>Methods<\/b>.<\/li>\n<li>Set options for the selected method using the\u00a0<b>Influence Range<\/b>,\u00a0<b>Squash<\/b>,\u00a0<b>Aspect Ratio<\/b>, and\u00a0<b>Reject Ratio<\/b>\u00a0fields.\n<p>For more information on these methods and their options, refer to\u00a0<a href=\"http:\/\/www.mathworks.com\/help\/fuzzy\/fcm.html\"><tt>fcm<\/tt><\/a>, and\u00a0<a href=\"http:\/\/www.mathworks.com\/help\/fuzzy\/subclust.html\"><tt>subclust<\/tt><\/a>\u00a0respectively.<\/li>\n<li>Begin clustering by clicking\u00a0<b>Start<\/b>.\n<p>After clustering gets completed, the cluster centers appear in black as shown in the next figure.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.mathworks.com\/help\/releases\/R2013b\/fuzzy\/clustercenter.gif\" width=\"568\" height=\"468\" \/><\/li>\n<\/ol>\n<p><a name=\"bq__f79\"><\/a><\/p>\n<h4 id=\"bq__f79\">Saving the Cluster Center<\/h4>\n<p>To save the cluster centers, click\u00a0<b>Save Center<\/b>.<\/p>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>What Is Data Clustering? Clustering of numerical data forms the basis of many classification and system modeling algorithms. The purpose of\u00a0clustering is to identify natural&hellip; <\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[9],"tags":[],"class_list":["post-357","post","type-post","status-publish","format-standard","hentry","category-image-processing"],"_links":{"self":[{"href":"https:\/\/zhuoyao.net\/index.php\/wp-json\/wp\/v2\/posts\/357","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/zhuoyao.net\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/zhuoyao.net\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/zhuoyao.net\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/zhuoyao.net\/index.php\/wp-json\/wp\/v2\/comments?post=357"}],"version-history":[{"count":0,"href":"https:\/\/zhuoyao.net\/index.php\/wp-json\/wp\/v2\/posts\/357\/revisions"}],"wp:attachment":[{"href":"https:\/\/zhuoyao.net\/index.php\/wp-json\/wp\/v2\/media?parent=357"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/zhuoyao.net\/index.php\/wp-json\/wp\/v2\/categories?post=357"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/zhuoyao.net\/index.php\/wp-json\/wp\/v2\/tags?post=357"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}