@stdlib/math-base-special-ceilsd 0.3.0 → 0.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (4) hide show
  1. package/NOTICE +1 -1
  2. package/README.md +14 -16
  3. package/package.json +11 -11
  4. package/src/addon.c +0 -1
package/NOTICE CHANGED
@@ -1 +1 @@
1
- Copyright (c) 2016-2024 The Stdlib Authors.
1
+ Copyright (c) 2016-2026 The Stdlib Authors.
package/README.md CHANGED
@@ -88,18 +88,16 @@ v = ceilsd( 0.0313, 2, 2 );
88
88
  <!-- eslint no-undef: "error" -->
89
89
 
90
90
  ```javascript
91
- var randu = require( '@stdlib/random-base-randu' );
91
+ var uniform = require( '@stdlib/random-array-uniform' );
92
+ var logEachMap = require( '@stdlib/console-log-each-map' );
92
93
  var ceilsd = require( '@stdlib/math-base-special-ceilsd' );
93
94
 
94
- var x;
95
- var y;
96
- var i;
95
+ var opts = {
96
+ 'dtype': 'float64'
97
+ };
98
+ var x = uniform( 100, -5000.0, 5000.0, opts );
97
99
 
98
- for ( i = 0; i < 100; i++ ) {
99
- x = (randu()*10000.0) - 5000.0;
100
- y = ceilsd( x, 5, 10 );
101
- console.log( 'x: %d. Rounded: %d.', x, y );
102
- }
100
+ logEachMap( 'x: %0.4f. y: %d. z: %d. Rounded: %0.4f.', x, 5, 10, ceilsd );
103
101
  ```
104
102
 
105
103
  </section>
@@ -134,7 +132,7 @@ for ( i = 0; i < 100; i++ ) {
134
132
 
135
133
  #### stdlib_base_ceilsd( x, n, b )
136
134
 
137
- Rounds a `numeric` value to the nearest `number` toward negative infinity with `n` significant figures.
135
+ Rounds a `numeric` value to the nearest `number` toward positive infinity with `n` significant figures.
138
136
 
139
137
  ```c
140
138
  double out = stdlib_base_ceilsd( 0.0313, 2, 2 );
@@ -206,7 +204,7 @@ int main( void ) {
206
204
 
207
205
  - <span class="package-name">[`@stdlib/math-base/special/ceil`][@stdlib/math/base/special/ceil]</span><span class="delimiter">: </span><span class="description">round a double-precision floating-point number toward positive infinity.</span>
208
206
  - <span class="package-name">[`@stdlib/math-base/special/floorsd`][@stdlib/math/base/special/floorsd]</span><span class="delimiter">: </span><span class="description">round a numeric value to the nearest number toward negative infinity with N significant figures.</span>
209
- - <span class="package-name">[`@stdlib/math-base/special/roundsd`][@stdlib/math/base/special/roundsd]</span><span class="delimiter">: </span><span class="description">round a numeric value to the nearest number with N significant figures.</span>
207
+ - <span class="package-name">[`@stdlib/math-base/special/roundsd`][@stdlib/math/base/special/roundsd]</span><span class="delimiter">: </span><span class="description">round a double-precision floating-point number to the nearest value with N significant figures.</span>
210
208
  - <span class="package-name">[`@stdlib/math-base/special/truncsd`][@stdlib/math/base/special/truncsd]</span><span class="delimiter">: </span><span class="description">round a numeric value to the nearest number toward zero with N significant figures.</span>
211
209
 
212
210
  </section>
@@ -239,7 +237,7 @@ See [LICENSE][stdlib-license].
239
237
 
240
238
  ## Copyright
241
239
 
242
- Copyright &copy; 2016-2024. The Stdlib [Authors][stdlib-authors].
240
+ Copyright &copy; 2016-2026. The Stdlib [Authors][stdlib-authors].
243
241
 
244
242
  </section>
245
243
 
@@ -252,8 +250,8 @@ Copyright &copy; 2016-2024. The Stdlib [Authors][stdlib-authors].
252
250
  [npm-image]: http://img.shields.io/npm/v/@stdlib/math-base-special-ceilsd.svg
253
251
  [npm-url]: https://npmjs.org/package/@stdlib/math-base-special-ceilsd
254
252
 
255
- [test-image]: https://github.com/stdlib-js/math-base-special-ceilsd/actions/workflows/test.yml/badge.svg?branch=v0.3.0
256
- [test-url]: https://github.com/stdlib-js/math-base-special-ceilsd/actions/workflows/test.yml?query=branch:v0.3.0
253
+ [test-image]: https://github.com/stdlib-js/math-base-special-ceilsd/actions/workflows/test.yml/badge.svg?branch=v0.3.1
254
+ [test-url]: https://github.com/stdlib-js/math-base-special-ceilsd/actions/workflows/test.yml?query=branch:v0.3.1
257
255
 
258
256
  [coverage-image]: https://img.shields.io/codecov/c/github/stdlib-js/math-base-special-ceilsd/main.svg
259
257
  [coverage-url]: https://codecov.io/github/stdlib-js/math-base-special-ceilsd?branch=main
@@ -265,8 +263,8 @@ Copyright &copy; 2016-2024. The Stdlib [Authors][stdlib-authors].
265
263
 
266
264
  -->
267
265
 
268
- [chat-image]: https://img.shields.io/gitter/room/stdlib-js/stdlib.svg
269
- [chat-url]: https://app.gitter.im/#/room/#stdlib-js_stdlib:gitter.im
266
+ [chat-image]: https://img.shields.io/badge/zulip-join_chat-brightgreen.svg
267
+ [chat-url]: https://stdlib.zulipchat.com
270
268
 
271
269
  [stdlib]: https://github.com/stdlib-js/stdlib
272
270
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stdlib/math-base-special-ceilsd",
3
- "version": "0.3.0",
3
+ "version": "0.3.1",
4
4
  "description": "Round a numeric value to the nearest number toward positive infinity with N significant figures.",
5
5
  "license": "Apache-2.0",
6
6
  "author": {
@@ -33,17 +33,17 @@
33
33
  "url": "https://github.com/stdlib-js/stdlib/issues"
34
34
  },
35
35
  "dependencies": {
36
- "@stdlib/math-base-assert-is-infinite": "^0.2.2",
37
- "@stdlib/math-base-assert-is-nan": "^0.2.2",
38
- "@stdlib/math-base-napi-ternary": "^0.3.0",
39
- "@stdlib/math-base-special-abs": "^0.2.2",
40
- "@stdlib/math-base-special-ceil": "^0.2.2",
41
- "@stdlib/math-base-special-floor": "^0.2.3",
42
- "@stdlib/math-base-special-ln": "^0.2.4",
43
- "@stdlib/math-base-special-log10": "^0.3.0",
36
+ "@stdlib/math-base-assert-is-infinite": "^0.2.3",
37
+ "@stdlib/math-base-assert-is-nan": "^0.2.3",
38
+ "@stdlib/math-base-napi-ternary": "^0.3.2",
39
+ "@stdlib/math-base-special-abs": "^0.2.3",
40
+ "@stdlib/math-base-special-ceil": "^0.2.3",
41
+ "@stdlib/math-base-special-floor": "^0.2.4",
42
+ "@stdlib/math-base-special-ln": "^0.2.5",
43
+ "@stdlib/math-base-special-log10": "^0.3.1",
44
44
  "@stdlib/math-base-special-pow": "^0.3.0",
45
- "@stdlib/number-float64-base-exponent": "^0.2.2",
46
- "@stdlib/utils-library-manifest": "^0.2.2"
45
+ "@stdlib/number-float64-base-exponent": "^0.2.3",
46
+ "@stdlib/utils-library-manifest": "^0.2.4"
47
47
  },
48
48
  "devDependencies": {},
49
49
  "engines": {
package/src/addon.c CHANGED
@@ -19,5 +19,4 @@
19
19
  #include "stdlib/math/base/special/ceilsd.h"
20
20
  #include "stdlib/math/base/napi/ternary.h"
21
21
 
22
- // cppcheck-suppress shadowFunction
23
22
  STDLIB_MATH_BASE_NAPI_MODULE_DII_D( stdlib_base_ceilsd )