⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 clusteringinfoskmean.java

📁 一个用于排队系统仿真的开源软件,有非常形象的图象仿真过程!
💻 JAVA
字号:
package jmt.engine.jwat.workloadAnalysis.clustering.kMean;

import java.text.DecimalFormat;
import java.text.NumberFormat;
import java.util.Vector;

import jmt.engine.jwat.MatrixOsservazioni;
import jmt.engine.jwat.Observation;
import jmt.engine.jwat.workloadAnalysis.clustering.ClusteringInfos;
import jmt.engine.jwat.workloadAnalysis.clustering.kMean.KMeanClusteringEngine.TempClusterStatistics;


public class ClusteringInfosKMean implements ClusteringInfos{
	
	public ClusterInfoKMean[] infoCluster;
	private static final String SPACES5  = "     ";
    private static final String SPACES7  = "       ";
    private static final String SPACES16 = "                ";
	private NumberFormat Floatformatter = new DecimalFormat("###.##E0");

	public int		isGoodCluster;					// -1 non presente; 0 non ottimo; 1 ottimo
	public double	omsr;					// overall
	public double	ratio;					// ratio

	public int[]		numElem;		// numero di elementi di ogni singolo cluster
	public double[]	percent;		// percentuale sul totale

	

	public String centri;					// contiene i centri dei cluster

	public String log;					// informazioni generali
	private int numCluster;
	
	public double passw;

	public ClusteringInfosKMean(int numCluster,int nvars){
		centri="";
		log="";
		ratio=-1;
		isGoodCluster=0;
		numElem=new int[numCluster+1];
		infoCluster = new ClusterInfoKMean[numCluster+1];
		for(int i = 0; i < numCluster+1;i++){
			infoCluster[i] = new ClusterInfoKMean(nvars);
		}
		percent = new double[numCluster+1];
		this.numCluster=numCluster;
    }
		
	public void Output(int[] varSel,TempClusterStatistics[][] sum,short[] clusAssign,MatrixOsservazioni m
			,double oldPassw) //Deve valere assw precedentemente calcolato 
	{
		
		passw = oldPassw;
		
		String tempStr;
		String crlf = "\n";	
		
		double ssb;		// varianza fra le classi sulla variabile j
		double ssw;		// varianza interna sulla variabile j
		double dfw = 0;		// grado di libert

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -