q_calc_util 1.1.0 copy "q_calc_util: ^1.1.0" to clipboard
q_calc_util: ^1.1.0 copied to clipboard

Dixon's Q Test calculator package for Dart. It makes it easy to identify an outlier in a range between 3 and 30 double numbers

example/q_calc_util_example.dart

import 'package:q_calc_util/q_calc_util.dart';

void printResults(DixonResults result, int confidence) {
  print('''
      Confidence: $confidence%
       Lower end: ${result.lowerEnd!.toStringAsFixed(3)}
       Upper end: ${result.upperEnd!.toStringAsFixed(3)}
               Q: ${result.q}
               N: ${result.n}
          Values: ${result.values.toString()}
  Removed values: ${result.removedValues.toString()}
  ''');
}

void main() {
  var values = [0.764, 0.864, 0.936, 0.047, 1.028, 1.043];

  try {
    var result95 = calculateQTest(values, Confidence.percent95);
    printResults(result95, 95);
  } on DixonException catch (error) {
    print(error.toString());
  }

  try {
    var result99 = calculateQTest(values, Confidence.percent99);
    printResults(result99, 99);
  } on DixonException catch (error) {
    print(error.toString());
  }
}
0
likes
140
pub points
0%
popularity

Publisher

verified publisherchemis.tech

Dixon's Q Test calculator package for Dart. It makes it easy to identify an outlier in a range between 3 and 30 double numbers

Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (LICENSE)

More

Packages that depend on q_calc_util