@@ -17,6 +17,7 @@ test('test matrixBoxPlot even', () => {
1717 [ 10 , 100 ] ,
1818 [ 11 , 110 ] ,
1919 ] ;
20+
2021 expect ( matrixBoxPlot ( matrix ) ) . toStrictEqual ( {
2122 q1 : Float64Array . from ( [ 2.5 , 25 ] ) ,
2223 median : Float64Array . from ( [ 5.5 , 55 ] ) ,
@@ -28,6 +29,7 @@ test('test matrixBoxPlot even', () => {
2829
2930test ( 'test matrixBoxPlot even small' , ( ) => {
3031 const matrix = [ [ 0 ] , [ 1 ] , [ 2 ] , [ 3 ] , [ 4 ] , [ 5 ] ] ;
32+
3133 expect ( matrixBoxPlot ( matrix ) ) . toStrictEqual ( {
3234 q1 : Float64Array . from ( [ 1 ] ) ,
3335 median : Float64Array . from ( [ 2.5 ] ) ,
@@ -39,6 +41,7 @@ test('test matrixBoxPlot even small', () => {
3941
4042test ( 'test matrixBoxPlot odd' , ( ) => {
4143 const matrix = [ [ 0 ] , [ 1 ] , [ 2 ] , [ 3 ] , [ 4 ] , [ 5 ] , [ 6 ] , [ 7 ] , [ 8 ] , [ 9 ] , [ 10 ] ] ;
44+
4245 expect ( matrixBoxPlot ( matrix ) ) . toStrictEqual ( {
4346 q1 : Float64Array . from ( [ 2 ] ) ,
4447 median : Float64Array . from ( [ 5 ] ) ,
@@ -50,6 +53,7 @@ test('test matrixBoxPlot odd', () => {
5053
5154test ( 'test matrixBoxPlot odd small' , ( ) => {
5255 const matrix = [ [ 0 ] , [ 1 ] , [ 2 ] , [ 3 ] , [ 4 ] ] ;
56+
5357 expect ( matrixBoxPlot ( matrix ) ) . toStrictEqual ( {
5458 q1 : Float64Array . from ( [ 0.5 ] ) ,
5559 median : Float64Array . from ( [ 2 ] ) ,
@@ -61,6 +65,7 @@ test('test matrixBoxPlot odd small', () => {
6165
6266test ( 'test matrixBoxPlot too small' , ( ) => {
6367 const matrix = [ [ 0 ] , [ 1 ] , [ 2 ] , [ 4 ] ] ;
68+
6469 expect ( ( ) => matrixBoxPlot ( matrix ) ) . toThrow (
6570 'can not calculate info if matrix contains less than 5 rows' ,
6671 ) ;
0 commit comments