I'm writing my masters thesis and my supervisor has picked up my sentence structure, in that they are too long. She commented that Microsoft Word has a feature to investigate 'large' sentences. How can I do this with TeX? I'm using a mac and TexShop.
- Render your document to a PDF. Let's assume it's called
- Grab the plain text from the PDF using
pdftotext. At the terminal, run this:
pdftotext paper.pdf paper.txt
- Now run
style -l N paper.txt, where you should replace
Nwith a number. This will print out all lines of your document that are longer than
Alternatively, you can do it all as a one-liner:
$ pdflatex paper.tex && pdftotext paper.pdf - | style -l 20
style is extremely powerful and has many other features. For a good overview, see here.