squiggle/packages/website/docs/Api/Number.mdx

145 lines
1.5 KiB
Plaintext
Raw Normal View History

2022-06-05 20:59:45 +00:00
---
2022-06-11 00:35:48 +00:00
sidebar_position: 9
2022-06-05 20:59:45 +00:00
title: Number
---
import TOCInline from "@theme/TOCInline";
<TOCInline toc={toc} />
2022-06-05 20:59:45 +00:00
### ceil
```javascript
2022-06-11 15:57:02 +00:00
ceil: (number) => number;
2022-06-05 20:59:45 +00:00
```
### floor
```javascript
2022-06-11 15:57:02 +00:00
floor: (number) => number;
2022-06-05 20:59:45 +00:00
```
### abs
```javascript
2022-06-11 15:57:02 +00:00
abs: (number) => number;
2022-06-05 20:59:45 +00:00
```
### round
```javascript
2022-06-11 15:57:02 +00:00
round: (number) => number;
2022-06-05 20:59:45 +00:00
```
## Statistics
2022-06-05 20:59:45 +00:00
### max
```javascript
2022-06-11 00:35:48 +00:00
max: (list<number>) => number
2022-06-05 20:59:45 +00:00
```
### min
```javascript
2022-06-11 00:35:48 +00:00
min: (list<number>) => number
2022-06-05 20:59:45 +00:00
```
### mean
```javascript
2022-06-11 00:35:48 +00:00
mean: (list<number>) => number
2022-06-05 20:59:45 +00:00
```
2022-06-11 00:35:48 +00:00
### stdev
2022-06-05 20:59:45 +00:00
```javascript
2022-06-11 00:35:48 +00:00
stdev: (list<number>) => number
2022-06-05 20:59:45 +00:00
```
### variance
```javascript
2022-06-11 00:35:48 +00:00
variance: (list<number>) => number
2022-06-05 20:59:45 +00:00
```
## Algebra
2022-06-05 20:59:45 +00:00
### unaryMinus
```javascript
2022-06-11 15:57:02 +00:00
unaryMinus: (number) => number;
2022-06-05 20:59:45 +00:00
```
### equal
```javascript
2022-06-11 15:57:02 +00:00
equal: (number, number) => boolean;
2022-06-05 20:59:45 +00:00
```
### add
```javascript
2022-06-11 15:57:02 +00:00
add: (number, number) => number;
2022-06-05 20:59:45 +00:00
```
### sum
```javascript
2022-06-11 00:35:48 +00:00
sum: (list<number>) => number
```
### cumulative sum
```
cumsum: (list<number>) => list<number>
2022-06-05 20:59:45 +00:00
```
### multiply
```javascript
2022-06-11 15:57:02 +00:00
multiply: (number, number) => number;
2022-06-05 20:59:45 +00:00
```
### product
```javascript
2022-06-11 00:35:48 +00:00
product: (list<number>) => number
```
### cumulative product
```
cumprod: (list<number>) => list<number>
2022-06-05 20:59:45 +00:00
```
### subtract
```javascript
2022-06-11 15:57:02 +00:00
subtract: (number, number) => number;
2022-06-05 20:59:45 +00:00
```
### divide
```javascript
2022-06-11 15:57:02 +00:00
divide: (number, number) => number;
2022-06-05 20:59:45 +00:00
```
### pow
```javascript
2022-06-11 15:57:02 +00:00
pow: (number, number) => number;
2022-06-05 20:59:45 +00:00
```
### exp
```javascript
2022-06-11 15:57:02 +00:00
exp: (number) => number;
2022-06-05 20:59:45 +00:00
```
### log
```javascript
2022-06-11 15:57:02 +00:00
log: (number) => number;
```