Giter Club home page Giter Club logo

verbose.py's Introduction

verbose.py

A Python module that returns a list of the most frequently used words of a webpage (requires lxml and requests)

Example:

from verbose import verbose_counter

array = verbose_counter("http://clholm.com/", 2)
print(array)

array = ['connor', 'holm']

To use, simply import the module and call the verbose_counter function. Function parameters:

  1. Website URL
  2. Number of frequent words to return
  3. Whether or not duplicates are allowed in the returned list (default True). Edit this in the function call with "duplicates_allowed=(True/False)"
  4. Whether or not stopwords are allowed in the returned list. Uses English Stopwords from the NLTK (default False). Edit this in the function call with "stopwords_allowed=(True/False")

If there is a tie for the last word to return, allowing duplicates will return every word that is tied, and not allowing duplicates will break the tie in alphabetic order. If stopwords are not allowed, they will be omitted from the entire frequency count, and as a result will not be in the returned list

This code is provided under the MIT License. Do whatever you want with it!

If you have any questions, suggestions, or other comments feel free to email me at [email protected] (or visit my website at clholm.com)

verbose.py's People

Contributors

clholm avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.