Find Duplicate Passages

Get help using and writing Nisus Writer Pro macros.
Post Reply
wolane
Posts: 4
Joined: 2011-06-22 16:41:33
Location: Toronto, Canada

Find Duplicate Passages

Post by wolane » 2011-07-24 11:58:50

Hi all--

Does anyone have, or know, a Macro which can find duplicate passages? I'm working with a 200-page document in which I've been doing a lot of cutting and pasting, and I'm afraid some paragraphs or sentences might have been pasted more than once, or copy/pasted rather than cut/pasted. I've been finding that Compare Documents macro very useful for merging different versions of chapters, so I wonder if there might also be a way to automate the search for duplications. Any thoughts?

Thanks.

BILL.

User avatar
martin
Official Nisus Person
Posts: 4251
Joined: 2002-07-11 17:14:10
Location: San Diego, CA
Contact:

Re: Find Duplicate Passages

Post by martin » 2011-07-24 17:59:16

Hi Bill- certainly a macro could do such a thing. The question is, what constitutes a duplicate? A sentence that's exactly the same? What about if a few words are arranged differently, or you use a slightly different word choice (eg: "in" instead of "within")? Getting all those details right would take some work.

wolane
Posts: 4
Joined: 2011-06-22 16:41:33
Location: Toronto, Canada

Re: Find Duplicate Passages

Post by wolane » 2011-07-24 18:34:35

Well, Martin, I was imagining it would work the same as the document comparison macro... in other words, at the paragraph level or at the sentence level, the structure would have to be identical.

BILL.

User avatar
martin
Official Nisus Person
Posts: 4251
Joined: 2002-07-11 17:14:10
Location: San Diego, CA
Contact:

Re: Find Duplicate Passages

Post by martin » 2011-07-25 15:30:03

This macro might serve your needs. It creates a copy of the frontmost/active document, and marks all duplicates in that copy with special bookmarks. These bookmarks will be listed at the end of the duplicated document.
Attachments

[The extension nwm has been deactivated and can no longer be displayed.]


wolane
Posts: 4
Joined: 2011-06-22 16:41:33
Location: Toronto, Canada

Re: Find Duplicate Passages

Post by wolane » 2011-07-25 18:13:42

Wow that’s amazing, Martin, and it totally works. I’m slightly embarrassed to admit, it found two duplicated passages in my 227 page document.
Nisus is a truly great program, especially with those macros!

BILL.

Post Reply