private Table displayFVCvalue(FieldValueCounterResource fvcResource, NumberFormat pattern, final int size) {
		final Map<String, Double> fieldValueCounts = fvcResource.getFieldValueCounts();
		FieldValueComparator fvc = new FieldValueComparator(fieldValueCounts);
		TreeMap<String, Double> sortedFvc = new TreeMap<String, Double>(fvc);
		sortedFvc.putAll(fieldValueCounts);
		Table t = new Table();
		t.addHeader(1, new TableHeader("FieldValueCounter=" + fvcResource.getName())).addHeader(2, new TableHeader(""))
				.addHeader(3, new TableHeader(""));
		t.newRow().addValue(1, "VALUE").addValue(2, "-").addValue(3, "COUNT");
		int rowSize = 1;
		for (Map.Entry<String, Double> entry : sortedFvc.entrySet()) {
			t.newRow().addValue(1, entry.getKey()).addValue(2, "|").addValue(3, pattern.format(entry.getValue()));
			if (rowSize >= size) {
				break;
			}
			rowSize++;
		}
		return t;
	}
Commands for interacting with field value counter analytics.

@author Ilayaperumal Gopinathan
spring-xd-shell/src/main/java/org/springframework/xd/shell/command/FieldValueCounterCommands.java