protected void calculateMedian()
	{
		double[] b = new double[data.length];
		System.arraycopy (data, 0, b, 0, b.length);
		Arrays.sort (b);
		
		if (data.length % 2 == 0) {
			median = (b[(b.length / 2) - 1] + b[b.length / 2]) / 2.0;
		} else {
			median = b[b.length / 2];
		}
	}