Socket
Socket
Sign inDemoInstall

keyword-analyzer

Package Overview
Dependencies
0
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    keyword-analyzer

A keyword analyzer tool that returns keyword frequency for a given set of text.


Version published
Weekly downloads
19
increased by5.56%
Maintainers
1
Install size
14.9 kB
Created
Weekly downloads
 

Readme

Source

Keyword Analyzer

A nodejs module for discovering keywords for a given text input.

Introduction

The keyword analyzer tool allows you to find what keywords are most prevalent for a given input of text and allows you to specify options for configuring it to your needs. A basic example below shows you how it functions.

var keyword-analyzer = require('keyword-analyzer')

keyword-analyzer.wrest('bar bar bar foo foo foo foo'); // ["foo", "bar"]

Installation

npm install --save keyword-analyzer

Usage

.wrest(string[, options])

You can supply several options to configure how you want to find keywords.

Option: limit - .wrest(string,{ limit : int })

This specifies the max keyword results you want to be returned in the array. Defaults to all.

Option: frequency - .wrest(string,{ frequency : bool })

This determines whether or not the keywords will be returned with the number of times used in the text. Defaults to false.

Returned array will look like this: [{foo:3, bar:2}]

Option: min - .wrest(string,{ min : int })

The minimum times a word should be found in text to be returned. Defaults to 2.

Option: stopWords - .wrest(string,{ stopWords : arr })

A way to add additional stopwords to check against.

Option: nWords - .wrest(string,{ nWords : int })

Number of words to count as one keyword. A way to check phrases.

License

MIT

Keywords

FAQs

Last updated on 18 May 2016

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc