samePDF {gdiff} | R Documentation |
Compare Two PDF Files
Description
Check whether two PDF files have the same content, ignoring some details like creation time and modification time.
Usage
samePDF(file1, file2)
Arguments
file1 , file2 |
Names of PDF files to compare. |
Details
This function will compare any two files, byte by byte, but if a file is a PDF file that was generated by R, it will discard the file header, which may contain differences that do not matter, such as the creation date.
Value
A logical value.
Author(s)
Paul Murrell
Examples
f1 <- tempfile(fileext=".pdf")
f2 <- tempfile(fileext=".pdf")
pdf(f1)
plot(1)
dev.off()
pdf(f2)
plot(2)
dev.off()
samePDF(f1, f1)
samePDF(f1, f2)
[Package gdiff version 0.2-5 Index]