I am writing a paper with using this structure (simplified for explanation):
paper_root/master_document.lyx
paper_root/part1/part1.lyx
paper_root/part2/part2.lyx
paper_root/part3/part3.lyx
I have it set up so that, for example, I can work on part2.lyx and
compile it to view only the part2.pdf file.
Now say, I'm working on part2.lyx. If I put an image file in the same
directory, e.g.:
paper_root/part2/picture1.png
The compilation works fine. But if I create a top-level directory to
store my images, both to keep things organized to find files and to be
able to share/update pictures and have them in a different directory:
paper_root/images/picture1.png
When I try to insert the image in part2.lyx, Lyx just won't do it.
Nothing crashes, but the image never shows up in the document. In fact,
using the Insert > Graphics ... dialog, as soon as I browse to
../images/picture1.png and select the image, the Insert Graphics window
closes with nothing inserted in the document.
What am I doing wrong?
Secondary question:
I believe it was in his book on the ggplot2 package for R that Hadley
Wickham recommended putting this command in the LaTeX preamble:
\graphicspath{{../images/}{../graphs}}
But this totally screws things up for me when I put it in the preamble
in LyX. Any thoughts about this?
Thanks for your help.