Hello,
I am using a macro to compare two versions of an rtf output for differences. My question is there a way to compress/remove control words such as /trowd or /setd using regular expressions so that when using proc compare to detect differences they will match up better. For example.
\trowd\trkeep\...etc..\cf1{Alfreq\cell}\pard\...cf1{1.6\cell}\pard…..\cf1{60\cell}{\row}
\trowd\trkeep\...etc..\cf1{Alice\cell}\pard\...cf1{1.5\cell}\pard…..\cf1{50\cell}{\row}
being turned into this
Alfreq ^^^ 1.6 ^^^ 60 ^^^
Alice ^^^ 1.5 ^^^ 50 ^^^
If you search lexjansen.com you'll find papers on this, e.g.
https://www.lexjansen.com/pharmasug-cn/2017/CC/PharmaSUG-China-2017-CC07.pdf
https://www.pharmasug.org/cd/papers/TT/TT13.pdf
But after skimming, I don't think I would do this in SAS. I'd be more likely to read the RTF's into MS Word, and use Word's compare feature. Which could probably be automated with VBA or whatever if needed.
If you search lexjansen.com you'll find papers on this, e.g.
https://www.lexjansen.com/pharmasug-cn/2017/CC/PharmaSUG-China-2017-CC07.pdf
https://www.pharmasug.org/cd/papers/TT/TT13.pdf
But after skimming, I don't think I would do this in SAS. I'd be more likely to read the RTF's into MS Word, and use Word's compare feature. Which could probably be automated with VBA or whatever if needed.
Good news: We've extended SAS Hackathon registration until Sept. 12, so you still have time to be part of our biggest event yet – our five-year anniversary!
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.
Ready to level-up your skills? Choose your own adventure.