int median(int qual[], int i) {
		// Create a list
		LinkedList<Integer> list = new LinkedList<Integer>();
		for( int k = 0, j = i - runningMedianLength + 1; k < runningMedianLength; k++, j++ )
			if( (j >= 0) && (j < qual.length) ) list.add(qual[j]);
		Collections.sort(list);

		int size = list.size(), med = 0;
		if( list.size() % 2 == 1 ) med = list.get(size / 2);
		else med = (list.get(size / 2 - 1) + list.get(size / 2)) / 2;

		return med;
	}