repl.txt (1523B)
1 2 {{alias}}( x[, ...y[, options]] ) 3 Computes Levene's test for equal variances. 4 5 Parameters 6 ---------- 7 x: Array<number> 8 Measured values. 9 10 y: ...Array<number> (optional) 11 Measured values. 12 13 options: Object (optional) 14 Options. 15 16 options.alpha: number (optional) 17 Number in the interval `[0,1]` giving the significance level of the 18 hypothesis test. Default: `0.05`. 19 20 options.groups: Array (optional) 21 Array of group indicators. 22 23 Returns 24 ------- 25 out: Object 26 Test result object. 27 28 out.alpha: number 29 Significance level. 30 31 out.rejected: boolean 32 Test decision. 33 34 out.pValue: number 35 p-value of the test. 36 37 out.statistic: number 38 Value of test statistic. 39 40 out.method: string 41 Name of test. 42 43 out.df: Array 44 Degrees of freedom. 45 46 out.print: Function 47 Function to print formatted output. 48 49 Examples 50 -------- 51 // Data from Hollander & Wolfe (1973), p. 116: 52 > var x = [ 2.9, 3.0, 2.5, 2.6, 3.2 ]; 53 > var y = [ 3.8, 2.7, 4.0, 2.4 ]; 54 > var z = [ 2.8, 3.4, 3.7, 2.2, 2.0 ]; 55 56 > var out = {{alias}}( x, y, z ) 57 58 > var arr = [ 2.9, 3.0, 2.5, 2.6, 3.2, 59 ... 3.8, 2.7, 4.0, 2.4, 60 ... 2.8, 3.4, 3.7, 2.2, 2.0 61 ... ]; 62 > var groups = [ 63 ... 'a', 'a', 'a', 'a', 'a', 64 ... 'b', 'b', 'b', 'b', 65 ... 'c', 'c', 'c', 'c', 'c' 66 ... ]; 67 > out = {{alias}}( arr, { 'groups': groups } ) 68 69 See Also 70 -------- 71