🌳📖💻#3:🌳 — Word Frequenctrees

Get yourself some literature and watch this great introduction, because inspired by the following beautiful bash line:

$ tr -s ‘A-Z’ ‘a-z’ < shakes.txt | tr -sc ‘a-z’ ‘\n’ | sort | uniq -c | sort -n -r | less

I spent most of my day building a mini-website:

(here’s the code)

It was also a practice in JavaScript, and an approach to make RegEx do small tasks for me. The site is another one-day-hack.

I wrote all of the functions myself — except for the final `sortWords()`. It was once again interesting to see how using code I didn’t fully understand broke my flow and had me backtrack a few times until figuring my way around. I doubt that using something has even half as much learning effect as making something.

While taking a break, I also realized that I will now probably suspend creating small webapps and instead focus on learning to use python’s NLTK.

I might have already watched enough basic NLP concepts in the beginning videos of my courses, so that it starts to make sense to learn to use a powerful toolset, such as NLTK.

  • Taking text input and keeping some formatting by transforming the newline characters into <p>
  • Creating and hiding DOM Elements
  • Using JavaScript for simple text processing
the and i a to some my text for az using of that as it in

; )

feedback, code, projects, life, and education

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store