Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/atlassubbed/atlas-sum


https://github.com/atlassubbed/atlas-sum

Last synced: 21 days ago
JSON representation

Awesome Lists containing this project

README

        

# atlas-sum

Calculate the sum of a set of data points.

[![Travis](https://img.shields.io/travis/atlassubbed/atlas-sum.svg)](https://travis-ci.org/atlassubbed/atlas-sum)

---

## install

```
npm install --save atlas-sum
```

## why

Breaking up [atlas-dataset](https://github.com/atlassubbed/atlas-dataset#readme) into standalone functions. This module sums over an array of numbers:


sum(V) = sum[i=1 -> |V|](v_i)

## examples

```javascript
const sum = require("atlas-sum")
console.log(sum([1,2,3,4]))
// 10
```