I have been reading the cookbook for Linux to get a hang of it. I am fairly new to it.
I cam across a topic called Concordance of text. Now I understand what it is, but I am not able to get a sequence of commands using tr, sort and uniq ( That's what the cookbook says ) that would generate the concordance.
Can someone tell me how to create a basic concordance? i.e. just sort and display word frequency for each unique word.
The idea presented in the cookbook to use tr to translate all spaces to newline characters so that each word goes into a new line, which is then passed to the sorter, and then passed to the uniq with the -c flag to make a count of the unique terms.
I am not able to figure out the correct parameters though. Can someone explain please while explaining what each parameter does?
I have googled out for this but I am not able to get a clearly defined answer to my problem.
Any help is much appreciated!