@Test
public void testStdDev2() throws Exception {

  Path input = getTestTempFilePath("stdDev/counts.file");
  Path output = getTestTempFilePath("stdDev/output.file");
  FileSystem fs = FileSystem.get(input.toUri(), conf);
  SequenceFile.Writer writer = new SequenceFile.Writer(fs, conf, input, IntWritable.class,
          DoubleWritable.class);
  Random random = RandomUtils.getRandom();
  Normal normal = new Normal(5, 3, random);
  for (int i = 0; i < 1000000; i++) {
    writer.append(new IntWritable(i), new DoubleWritable((long) normal.nextInt()));
  }
  writer.close();
  double v = BasicStats.stdDev(input, output, conf);
  assertEquals(3, v, 0.02);
}