FacetsCollector fc = new FacetsCollector();
IndexSearcher s = newSearcher(r);
s.search(new MatchAllDocsQuery(), fc);
Facets facets = new DoubleRangeFacetCounts("field", new FloatFieldSource("field"), fc,
new DoubleRange("less than 10", 0.0f, true, 10.0f, false),
new DoubleRange("less than or equal to 10", 0.0f, true, 10.0f, true),
new DoubleRange("over 90", 90.0f, false, 100.0f, false),
new DoubleRange("90 or above", 90.0f, true, 100.0f, false),
new DoubleRange("over 1000", 1000.0f, false, Double.POSITIVE_INFINITY, false));