I need to count words in a paper. The journal I am writing for suggests to use wordcount.tex
(and the related wordcount.sh
). I am using TeX Live on a Mac and I could not find these files; I found them on the CTAN.
Now my question is: how should I install these files? Or where should I place them within the TeX Directory Structure?
Best Answer
Download the package at http://ctan.org/pkg/wordcount (i.e., http://mirrors.ctan.org/macros/latex/contrib/wordcount.zip), unpack it, extract its content (
wordcount.tex
andwourdcount.sh
) and copy it in the same folder as your document. Let's assume this document is nametest.tex
, and that it is in the folder/home/work/
.Launch a console, go to
/home/work/
using the commandcd
, i.e., doThen give to your script
wourdcount.sh
the right to be executed:You have to do all of the above only once. Once all of this is set up, a simple
should gives you what you want. Make sure that you can compile your document
test.tex
without errors, otherwisewourdcount.sh
might not work.If you are confused by Mac's terminal or uneasy with it, you could ask at https://apple.stackexchange.com/ or try apple support.
You might also want to compare
wordcount
's output with other software's count. For this, have a look at Is there any way to do a correct word count of a LaTeX document?