dist/multilabel/MetaLabeler.js
function(dataset) {
		// The ranker is just trained by the given set of labels relevant to each sample:
		this.ranker.trainBatch(dataset);

		// The counter is trained by the *number* of labels relevant to each sample:
		var labelCountDataset = dataset.map(function(datum) {
			var labelCount = (Array.isArray(datum.output)? datum.output.length: 1);
			return {
				input: datum.input,
				output: labelCount
			};
		});
		this.counter.trainBatch(labelCountDataset);
	}
function(dataset) {
		// The ranker is just trained by the given set of labels relevant to each sample:
		this.ranker.trainBatch(dataset);

		// The counter is trained by the *number* of labels relevant to each sample:
		var labelCountDataset = dataset.map(function(datum) {
			var labelCount = (Array.isArray(datum.output)? datum.output.length: 1);
			return {
				input: datum.input,
				output: labelCount
			};
		});
		this.counter.trainBatch(labelCountDataset);
	}
Train the classifier with all the given documents.

@param dataset
an array with objects of the format:
{input: sample1, output: [class11, class12...]}