You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: lib/node_modules/@stdlib/repl/help/lib/db.js
+2-1
Original file line number
Diff line number
Diff line change
@@ -1031,6 +1031,7 @@ module.exports = {
1031
1031
"keyBy": "\nkeyBy( collection, fcn[, thisArg] )\n Converts a collection to an object whose keys are determined by a provided\n function and whose values are the collection values.\n\n When invoked, the input function is provided two arguments:\n\n - `value`: collection value\n - `index`: collection index\n\n If more than one element in a collection resolves to the same key, the key\n value is the collection element which last resolved to the key.\n\n Object values are shallow copies.\n\n Parameters\n ----------\n collection: Array|TypedArray|Object\n Input collection over which to iterate. If provided an object, the\n object must be array-like (excluding strings and functions).\n\n fcn: Function\n The function to invoke for each element in a collection.\n\n thisArg: any (optional)\n Execution context.\n\n Returns\n -------\n out: Object\n Output object.\n\n Examples\n --------\n > function toKey( v ) { return v.a; };\n > var arr = [ { 'a': 1 }, { 'a': 2 } ];\n > keyBy( arr, toKey )\n { '1': { 'a': 1 }, '2': { 'a': 2 } }\n\n See Also\n --------\n forEach\n",
1032
1032
"keyByRight": "\nkeyByRight( collection, fcn[, thisArg] )\n Converts a collection to an object whose keys are determined by a provided\n function and whose values are the collection values, iterating from right to\n left.\n\n When invoked, the input function is provided two arguments:\n\n - `value`: collection value\n - `index`: collection index\n\n If more than one element in a collection resolves to the same key, the key\n value is the collection element which last resolved to the key.\n\n Object values are shallow copies.\n\n Parameters\n ----------\n collection: Array|TypedArray|Object\n Input collection over which to iterate. If provided an object, the\n object must be array-like (excluding strings and functions).\n\n fcn: Function\n The function to invoke for each element in a collection.\n\n thisArg: any (optional)\n Execution context.\n\n Returns\n -------\n out: Object\n Output object.\n\n Examples\n --------\n > function toKey( v ) { return v.a; };\n > var arr = [ { 'a': 1 }, { 'a': 2 } ];\n > keyByRight( arr, toKey )\n { '2': { 'a': 2 }, '1': { 'a': 1 } }\n\n See Also\n --------\n forEachRight, keyBy\n",
1033
1033
"kstest": "\nkstest( x, y[, ...params][, opts] )\n Computes a Kolmogorov-Smirnov goodness-of-fit test.\n\n For a numeric array or typed array `x`, a Kolmogorov-Smirnov goodness-of-fit\n is computed for the null hypothesis that the values of `x` come from the\n distribution specified by `y`. `y` can be either a string with the name of\n the distribution to test against, or a function.\n\n In the latter case, `y` is expected to be the cumulative distribution\n function (CDF) of the distribution to test against, with its first parameter\n being the value at which to evaluate the CDF and the remaining parameters\n constituting the parameters of the distribution. The parameters of the\n distribution are passed as additional arguments after `y` from `kstest` to\n the chosen CDF. The function returns an object holding the calculated test\n statistic `statistic` and the `pValue` of the test.\n\n The returned object comes with a `.print()` method which when invoked will\n print a formatted output of the hypothesis test results.\n\n Parameters\n ----------\n x: Array<number>\n Input array holding numeric values.\n\n y: Function|string\n Either a CDF function or a string denoting the name of a distribution.\n\n params: ...number (optional)\n Distribution parameters passed to reference CDF.\n\n options: Object (optional)\n Function options.\n\n options.alpha: number (optional)\n Number in the interval `[0,1]` giving the significance level of the\n hypothesis test. Default: `0.05`.\n\n options.sorted: boolean (optional)\n Boolean indicating if the input array is already in sorted order.\n Default: `false`.\n\n options.alternative: string (optional)\n Either `two-sided`, `less` or `greater`. Indicates whether the\n alternative hypothesis is that the true distribution of `x` is not equal\n to the reference distribution specified by `y` (`two-sided`), whether it\n is `less` than the reference distribution or `greater` than the\n reference distribution. Default: `'two-sided'`.\n\n Returns\n -------\n out: Object\n Test result object.\n\n out.alpha: number\n Used significance level.\n\n out.rejected: boolean\n Test decision.\n\n out.pValue: number\n P-value of the test.\n\n out.statistic: number\n Value of test statistic.\n\n out.alternative: string\n Used test alternative. Either `two-sided`, `less` or `greater`.\n\n out.method: string\n Name of test.\n\n out.print: function\n Function to print formatted output.\n\n Examples\n --------\n // Verify that data is drawn from a normal distribution:\n > var rnorm = base.random.normal.factory({ 'seed': 4839 });\n > var x = new Array( 100 );\n > for ( var i = 0; i < 100; i++ ) { x[ i ] = rnorm( 3.0, 1.0 ); }\n // Test against N(0,1)\n > var out = kstest( x, 'normal', 0.0, 1.0 );\n { pValue: 0.0, statistic: 0.847, ... }\n // Test against N(3,1)\n > out = kstest( x, 'normal', 3.0, 1.0 )\n { pValue: 0.6282, statistic: 0.0733, ... }\n\n // Verify that data is drawn from a uniform distribution:\n > runif = base.random.uniform.factory( 0.0, 1.0, { 'seed': 8798 })\n > x = new Array( 100 );\n > for ( i = 0; i < x.length; i++ ) { x[ i ] = runif(); }\n > out = kstest( x, 'uniform', 0.0, 1.0 )\n { pValue: ~0.703, statistic: ~0.069, ... }\n\n // Print output:\n > out.print()\n Kolmogorov-Smirnov goodness-of-fit test.\n\n Null hypothesis: the CDF of `x` is equal equal to the reference CDF.\n\n pValue: 0.7039\n statistic: 0.0689\n\n Test Decision: Fail to reject null in favor of alternative at 5%\n significance level\n\n // Set custom significance level:\n > out = kstest( x, 'uniform', 0.0, 1.0, { 'alpha': 0.1 })\n { pValue: ~0.7039, statistic: ~0.069, ... }\n\n // Carry out one-sided hypothesis tests:\n > runif = base.random.uniform.factory( 0.0, 1.0, { 'seed': 8798 });\n > x = new Array( 100 );\n > for ( i = 0; i < x.length; i++ ) { x[ i ] = runif(); }\n > out = kstest( x, 'uniform', 0.0, 1.0, { 'alternative': 'less' });\n { pValue: ~0.358, statistic: ~0.07, ... }\n > out = kstest( x, 'uniform', 0.0, 1.0, { 'alternative': 'greater' });\n { pValue: ~0.907, statistic: ~0.02, ... }\n\n // Set `sorted` option to true when data is in increasing order:\n x = [ 0.1, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9 ]\n out = kstest( x, 'uniform', 0.0, 1.0, { 'sorted': true })\n { pValue: ~1, statistic: 0.1, ... }\n\n",
1034
+
"linspace": "\nlinspace( start, stop[, length] )\n Generates a linearly spaced numeric array.\n\n If a `length` is not provided, the default output array length is `100`.\n\n The output array is guaranteed to include the `start` and `stop` values.\n\n Parameters\n ----------\n start: number\n First array value.\n\n stop: number\n Last array value.\n\n length: integer (optional)\n Length of output array. Default: `100`.\n\n Returns\n -------\n arr: Array\n Linearly spaced numeric array.\n\n Examples\n --------\n > var arr = linspace( 0, 100, 6 )\n [ 0, 20, 40, 60, 80, 100 ]\n\n See Also\n --------\n incrspace, logspace\n",
1034
1035
"LIU_NEGATIVE_OPINION_WORDS_EN": "\nLIU_NEGATIVE_OPINION_WORDS_EN()\n Returns a list of negative opinion words.\n\n A word's appearance in a sentence does *not* necessarily imply a positive or\n negative opinion.\n\n The list includes misspelled words. Their presence is intentional, as such\n misspellings frequently occur in social media content.\n\n Returns\n -------\n out: Array<string>\n List of negative opinion words.\n\n Examples\n --------\n > var list = LIU_NEGATIVE_OPINION_WORDS_EN()\n [ '2-faced', '2-faces', 'abnormal', 'abolish', ... ]\n\n References\n ----------\n - Hu, Minqing, and Bing Liu. 2004. \"Mining and Summarizing Customer\n Reviews.\" In *Proceedings of the Tenth Acm Sigkdd International Conference\n on Knowledge Discovery and Data Mining*, 168–77. KDD '04. New York, NY, USA:\n ACM. doi:10.1145/1014052.1014073.\n - Liu, Bing, Minqing Hu, and Junsheng Cheng. 2005. \"Opinion Observer:\n Analyzing and Comparing Opinions on the Web.\" In *Proceedings of the 14th\n International Conference on World Wide Web*, 342–51. WWW '05. New York, NY,\n USA: ACM. doi:10.1145/1060745.1060797.\n\n * If you use the list for publication or third party consumption, please\n cite one of the listed references.\n\n See Also\n --------\n LIU_POSITIVE_OPINION_WORDS_EN\n",
1035
1036
"LIU_POSITIVE_OPINION_WORDS_EN": "\nLIU_POSITIVE_OPINION_WORDS_EN()\n Returns a list of positive opinion words.\n\n A word's appearance in a sentence does *not* necessarily imply a positive or\n negative opinion.\n\n The list includes misspelled words. Their presence is intentional, as such\n misspellings frequently occur in social media content.\n\n Returns\n -------\n out: Array<string>\n List of positive opinion words.\n\n Examples\n --------\n > var list = LIU_POSITIVE_OPINION_WORDS_EN()\n [ 'a+', 'abound', 'abounds', 'abundance', ... ]\n\n References\n ----------\n - Hu, Minqing, and Bing Liu. 2004. 'Mining and Summarizing Customer\n Reviews.' In *Proceedings of the Tenth Acm Sigkdd International Conference\n on Knowledge Discovery and Data Mining*, 168–77. KDD '04. New York, NY, USA:\n ACM. doi:10.1145/1014052.1014073.\n - Liu, Bing, Minqing Hu, and Junsheng Cheng. 2005. 'Opinion Observer:\n Analyzing and Comparing Opinions on the Web.' In *Proceedings of the 14th\n International Conference on World Wide Web*, 342–51. WWW '05. New York, NY,\n USA: ACM. doi:10.1145/1060745.1060797.\n\n * If you use the list for publication or third party consumption, please\n cite one of the listed references.\n\n See Also\n --------\n LIU_NEGATIVE_OPINION_WORDS_EN\n",
"LN_TWO_PI": "\nLN_TWO_PI\n Natural logarithm of `2π`.\n\n Examples\n --------\n > LN_TWO_PI\n 1.8378770664093456\n\n See Also\n --------\n TWO_PI\n",
1040
1041
"LN10": "\nLN10\n Natural logarithm of `10`.\n\n Examples\n --------\n > LN10\n 2.302585092994046\n\n See Also\n --------\n LN2\n",
1041
1042
"LN2": "\nLN2\n Natural logarithm of `2`.\n\n Examples\n --------\n > LN2\n 0.6931471805599453\n\n See Also\n --------\n LN10\n",
1042
-
"linspace": "\nlinspace( start, stop[, length] )\n Generates a linearly spaced numeric array.\n\n If a `length` is not provided, the default output array length is `100`.\n\n The output array is guaranteed to include the `start` and `stop` values.\n\n Parameters\n ----------\n start: number\n First array value.\n\n stop: number\n Last array value.\n\n length: integer (optional)\n Length of output array. Default: `100`.\n\n Returns\n -------\n arr: Array\n Linearly spaced numeric array.\n\n Examples\n --------\n > var arr = linspace( 0, 100, 6 )\n [ 0, 20, 40, 60, 80, 100 ]\n\n See Also\n --------\n incrspace, logspace\n",
1043
1043
"logspace": "\nlogspace( a, b[, length] )\n Generates a logarithmically spaced numeric array between `10^a` and `10^b`.\n\n If a `length` is not provided, the default output array length is `10`.\n\n The output array includes the values `10^a` and `10^b`.\n\n Parameters\n ----------\n a: number\n Exponent of start value.\n\n b: number\n Exponent of end value.\n\n length: integer (optional)\n Length of output array. Default: `10`.\n\n Returns\n -------\n arr: Array\n Logarithmically spaced numeric array.\n\n Examples\n --------\n > var arr = logspace( 0, 2, 6 )\n [ 1, ~2.5, ~6.31, ~15.85, ~39.81, 100 ]\n\n See Also\n --------\n incrspace, linspace\n",
1044
+
"LOG2E": "\nLOG2E\n Base 2 logarithm of Euler's number.\n\n Examples\n --------\n > LOG2E\n 1.4426950408889634\n\n See Also\n --------\n E\n",
1044
1045
"lowercase": "\nlowercase( str )\n Converts a `string` to lowercase.\n\n Parameters\n ----------\n str: string\n Input string.\n\n Returns\n -------\n out: string\n Lowercase string.\n\n Examples\n --------\n > var out = lowercase( 'bEEp' )\n 'beep'\n\n See Also\n --------\n uncapitalize, uppercase\n",
1045
1046
"lowercaseKeys": "\nlowercaseKeys( obj )\n Converts each object key to lowercase.\n\n The function only transforms own properties. Hence, the function does not\n transform inherited properties.\n\n The function shallow copies key values.\n\n Parameters\n ----------\n obj: Object\n Source object.\n\n Returns\n -------\n out: Object\n New object.\n\n Examples\n --------\n > var obj = { 'A': 1, 'B': 2 };\n > var out = lowercaseKeys( obj )\n { 'a': 1, 'b': 2 }\n\n See Also\n --------\n uncapitalizeKeys, uppercaseKeys\n",
1046
1047
"lpad": "\nlpad( str, len[, pad] )\n Left pads a `string` such that the padded `string` has a length of at least\n `len`.\n\n An output string is not guaranteed to have a length of exactly `len`, but to\n have a length of at least `len`. To generate a padded string having a length\n equal to `len`, post-process a padded string by trimming off excess\n characters.\n\n Parameters\n ----------\n str: string\n Input string.\n\n len: integer\n Minimum string length.\n\n pad: string (optional)\n String used to pad. Default: ' '.\n\n Returns\n -------\n out: string\n Padded string.\n\n Examples\n --------\n > var out = lpad( 'a', 5 )\n ' a'\n > out = lpad( 'beep', 10, 'b' )\n 'bbbbbbbeep'\n > out = lpad( 'boop', 12, 'beep' )\n 'beepbeepboop'\n\n See Also\n --------\n pad, rpad\n",
0 commit comments