HOWTO: count “real” word in Latex document

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).
About these ads

14 Responses to HOWTO: count “real” word in Latex document

  1. […] 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 […]

  2. […] way of Wei comes this little nugget of useful information of the kind I […]

  3. Olli says:

    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/

  4. Wei says:

    Thanks Olli, I’ll check this out, looks good

  5. Test says:

    Hello

    G’night

  6. samar says:

    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

  7. Robert says:

    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

  8. pick up women

    how to pick up women the right way

  9. Shane says:

    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.

  10. Sallie says:

    I know this if off topic but I’m looking into starting my own weblog and was wondering what all is needed to get setup? I’m
    assuming having a blog like yours would cost a pretty penny?
    I’m not very web smart so I’m not 100% positive. Any tips or
    advice would be greatly appreciated. Appreciate
    it

  11. Norberto says:

    Helpful information. Lucky me I discovered your website by accident, and I’m surprised why this coincidence didn’t came about earlier!

    I bookmarked it.

  12. These sites must be developed in such a way that it should allow users to share ideas, events, activities,
    events and also their interest. service, so there is plenty of room to under cut them in terms of price.
    Wordpress is a lot the same, but gives you some more options.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Follow

Get every new post delivered to your Inbox.

%d bloggers like this: