# analyser-frequency-average

> gets an average Hz between two frequency ranges

Latest version **1.0.0** (published 2015-11-25) · MIT license · 0 weekly downloads

## Install

```sh
npm install analyser-frequency-average
pnpm add analyser-frequency-average
yarn add analyser-frequency-average
bun add analyser-frequency-average
```

## Health

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

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.0 |
| Published | 2015-11-25 |
| First published | 2015-11-25 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 1 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 23 |
| Author | Matt DesLauriers |
| Maintainers | mattdesl |
| Keywords | freq, range, frequency, audio, detection, beat, visualizer, freqs, frequencies |

## Links

- npm: https://www.npmjs.com/package/analyser-frequency-average
- Repository: https://github.com/Jam3/analyser-frequency-average
- Issues: https://github.com/Jam3/analyser-frequency-average/issues
- npm.io page: https://npm.io/package/analyser-frequency-average

## Dependencies (1)

- [audio-frequency-to-index](https://npm.io/package/audio-frequency-to-index.md) ^2.0.0

## Recent versions

- 1.0.0 (latest) — 2015-11-25

## README

# analyser-average-frequency

[![stable](http://badges.github.io/stability-badges/dist/stable.svg)](http://github.com/badges/stability-badges)

For the given WebAudio [AnalyserNode](https://developer.mozilla.org/en/docs/Web/API/AnalyserNode), determine the average signal (0 .. 1) between two frequency ranges in Hz. This can be useful for audio visualization on a certain spectrum of the frequency graph.

The frequency is assumed to be in byte data, though you can use the `floatData` entry point to get around this.

## Usage

[![NPM](https://nodei.co/npm/analyser-average-frequency.png)](https://www.npmjs.com/package/analyser-average-frequency)

#### `avg = average(analyser, frequencies, minHz, maxHz)`

Returns the average signal in `0 .. 1` range for the given `analyser` (AnalyserNode) and `frequencies` (array of byte frequency data from that node). The `minHz` and `maxHz` is the frequency range to sum, in Herz.

#### `avg = average.floatData(analyser, floatFrequencies, minHz, maxHz)`

The same as above, but intended to be used with the result of `analyserNode.getFloatFrequencyData()`. 

## License

MIT, see [LICENSE.md](http://github.com/Jam3/analyser-average-frequency/blob/master/LICENSE.md) for details.

---
_Source: https://npm.io/package/analyser-frequency-average · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
