Well, this should apply to all Latex documents, no matter it is edited in Windows or Linux environment. I jot this down because I am currently writing my final thesis, and just finished the first chapter. Then I want to check the word I’ve written, but I realised that the word count may include all the latex command which is not the real word count. Then I search the web find the ways to tackle this:
- First “sudo apt-get install untex“. then “untex target.tex > count“, then “wc -w count“. Well, don’t know is there any untex in Windows.
- This is quite convinient. There is a Perl script that can do this job nicely in here. The online script is even more convinient, just upload all the code, and the result will come out in a second (click on the icon in that webpage, or click here directly).
[...] February 7, 2007 Posted by ubuntonista in commands, packages, Readers’ Tips. trackback By way of Wei comes this little nugget of useful information of the kind I [...]
[...] way of Wei comes this little nugget of useful information of the kind I [...]
hi there, here is another small utility that is able to count Words in Latex. It is called LaTeX Word Counter. As it is based on Java it should also run under Windows.
http://lwc.sourceforge.net/
Thanks Olli, I’ll check this out, looks good
Hello
G’night
Note that these methods do not seem to expand \newcommands or automatically count words in \inputted or \included documents.
I am still searching for a comprehensive way to do a latex word count, unfortunately the definitive way seems to involve converting the final pdf (I use pdflatex BTW) to text and then doing a wc on that.
Note also you can abbreviate
untex target.tex > count ; wc -w count
to simply
untex target.tex | wc -w
May be a bit late for you, but I came across this Perl script (and this blog post, too) while searching for a way to do a word count on a LaTex document.
I seems to work quite well!
http://folk.uio.no/einarro/Comp/texwordcount.html
pick up women
how to pick up women the right way
That perl script is very nice. Thanks for the tip. Anyone up to the task of making it give section specific word count information? The output could add:
Section (Introduction): 300 words
Section (Methods): 500 words
Section (Results): 500 words
etc.
Good day!,
Hello!,