# @reactiff/random-walk

> Generates random number sequences that are more characteristic of Price Movements i.e. trending.

Latest version **1.0.0** (published 2021-06-06) · MIT license · 0 weekly downloads

## Install

```sh
npm install @reactiff/random-walk
pnpm add @reactiff/random-walk
yarn add @reactiff/random-walk
bun add @reactiff/random-walk
```

## Health

**Score 30/100 (F)** — status: abandoned.

Positive: has types; esm support; no vulnerabilities; high quality score.

Warnings: low downloads.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.0 |
| Published | 2021-06-06 |
| First published | 2021-06-06 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Node | >=10 |
| Dependencies | 0 |
| Unpacked size | 11 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Rick Ellis |
| Maintainers | nycdude777 |

## Links

- npm: https://www.npmjs.com/package/@reactiff/random-walk
- Repository: https://github.com/reactiff/random-walk
- Homepage: https://reactiff.github.io/random-walk
- Issues: https://github.com/reactiff/random-walk/issues
- npm.io page: https://npm.io/package/@reactiff/random-walk

## Recent versions

- 1.0.0 (latest) — 2021-06-06

## README

# @reactiff/random-walk

Generates random number sequences that are more characteristic of Price Movements i.e. trending.

[![NPM](https://img.shields.io/npm/v/@reactiff/random-walk.svg)](https://www.npmjs.com/package/@reactiff/random-walk) [![JavaScript Style Guide](https://img.shields.io/badge/code_style-standard-brightgreen.svg)](https://standardjs.com)



## Install

```bash
yarn add @reactiff/random-walk
```

## Usage

```tsx
import RandomWalk from '@reactiff/random-walk'

const rndWalk = new RandomWalk(
    1,      // min:         number
    1000,   // max:         number
    500,    // start:       number
    10,     // maxTrend:    number - max number of steps
    10      // maxStep:     number - max step size 
);

const generatePrice = () => {
    
    console.log( rndWalk.next() );
    
    // run again after delay
    setTimeout(generatePrice, 500);
}

generatePrice();
```

---

## Publishing the package to npm

```bash
# if scoped and free account
npm publish --access public

# otherwise
npm publish

```

to update
```bash
npm version major|minor|patch
```

and then simply
```bash
npm publish
```

---


## License
MIT © [Rick Ellis](https://github.com/reactiff)

---
_Source: https://npm.io/package/@reactiff/random-walk · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
