7

I'm currently preparing a paper for publication and so trying to construct the figures. I'm finding it more difficult than making figures for a report mainly because journals expect one figure file for each figure, regardless of whether it contains subfigures or not. This leads to some problems/hurdles:

  • I can't use LaTeX's \subfig package, so I have to manually place an (a), (b) and (c) on the figure and keep track of the caption if the ordering of these changes.
  • Journals' rules about figure submission vary quite a lot, some can take pdfs, some want vector graphics, others raster.
  • I have to somehow merge the output from various programs into a single file; for example diagrams made with Tikz make up the same figure as a graph plotted with python's matplotlib.
  • With having to merge subfigures in such a way, my workflow becomes quite convoluted if I have to modify one of the subfigures, and then regenerate the single figure file.
David Ketcheson
  • 36,304
  • 9
  • 109
  • 162
thosphor
  • 2,143
  • 1
  • 13
  • 20
  • The warning comes exclusively from the fact that the word "best" is present in the title, FWIW. There are a few keywords that will produce that warning, such as "you", "favorite", or "worst". –  Sep 07 '16 at 13:38
  • 3
    Why not ask at TeX.see since it seems like you want a technical answer. Seems like a perfect job for the standalone package/class. – StrongBad Sep 07 '16 at 14:30
  • @StrongBad Thanks for the suggestion, but I did want to make my question as broad as possible, I merely used my own experiences as examples to illustrate my point. I hope it doesn't come across as if I was asking for technical help in this particular case. – thosphor Sep 07 '16 at 14:53
  • 1
    Possible duplicate http://academia.stackexchange.com/questions/1095/software-to-draw-illustrative-figures-in-papers – StrongBad Sep 07 '16 at 14:59
  • @user3087409 I removed your comments to the mods in order to keep the question clear. Please feel free to post your comments as comments. – David Ketcheson Sep 08 '16 at 06:40
  • so I have to manually place an (a), (b) and (c) on the figure and keep track of the caption if the ordering of these changes – I know, this is mostly my opinion: But in the vast majority of cases, I find it more user-friendly not to use these indicators at all but to refer to “Fig. 5, left” or similar. This way people know directly where to look or even remember the respective part of the figure and their flow of thoughts is less broken. – Wrzlprmft Sep 08 '16 at 06:46
  • Journals' rules about figure submission vary quite a lot, some can take pdfs, some want vector graphics, others raster – The PDF format is capable of containing pixel as well as vector graphics. I have not encountered any journal that seriously requires pixel graphics; see also Why do some publication venues prefer TIFF over some vector formats? In general, I do not expect you can go much wrong with PDFs. – Wrzlprmft Sep 08 '16 at 06:50
  • 1
    @Wrzlprmft: 'I find it more user-friendly not to use these indicators at all but to refer to “Fig. 5, left' or similar" - while this may be a matter of preference, the point that the OP has to "keep track of the caption if the ordering of these changes" still stands. – O. R. Mapper Sep 08 '16 at 07:05
  • @O.R.Mapper: Sure, but the problem of manually placing such indicators is gone. – Wrzlprmft Sep 08 '16 at 07:08
  • 1
    @Wrzlprmft: Ah, I didn't realize that's a problem. If I am supposed to provide one PDF for the entire figure, I would have LaTeX render that PDF file while still using the subfig package or something equivalent. – O. R. Mapper Sep 08 '16 at 07:12
  • @scaaahu - See chat. – eykanal Sep 08 '16 at 12:43

5 Answers5

3

I don't know how well this will apply to you because I don't use tikz much. But if you can save them as say a pdf, this might work for you.

I use illustrator (but inkscape is similar and free), and I link in the files so that if there is an update to any component it will update. And I merge them all together.

Then I can just save it as a pdf or svg (or whatever format the journal wants). I found this a little cumbersome to start off with, but now that I'm used to it, I have a hard time reverting.

Aaron Shifman
  • 101
  • 1
  • 6
  • This is a nice use for linking that I hadn't thought of. How well does illustrator/inkscape keep edits, i.e. if an image has to be rescaled/cropped in order to fit into the figure, and the linked component is updated? – AJK Sep 09 '16 at 19:06
  • Illustrator can handle rescaled images (keeping dimensions true to the original figure) as of cs5 I believe. But I don't think inkscape can. – Aaron Shifman Sep 09 '16 at 19:18
1

I have used Matlab and Sci-Lab for creating graphics so far. In Matlab, I have also made the process of data analysis automatic, with minor interventions in the input parameters. Next, I have converted the data in separate files(*.txt) to be read after by a new program which creates the final figures. From my experience, Matlab provides the best quality in EPS, and is also good for data analysis but is not free. Sci-lab is good for graphics and free, but for analyzing data is very slow and time consuming. From what I have seen, R also is a good candidate for plots and have the biggest number of line styles(when printed on grayscale), but I have not worked with it.

Nikey Mike
  • 2,933
  • 2
  • 17
  • 33
1
  1. Use \subfig and typeset your document as you wish.

  2. Save it as a pdf.

  3. Within the pdf select the figure and crop everything else (on a mac you can use the select tool and then command-K in preview).

  4. Save the cropped figure as a .pdf or .tiff (or whatever is required).

  5. Replace the \subfig command with the cropped figure. It will look exactly the same (you may have to adjust the size) and will conform to journal requirements.

SoB
  • 1,026
  • 1
  • 8
  • 11
  • I'm not sure this will conform to journal requirements - often journals will want higher resolution files for their raster formats. Also, I think this will degrade vector graphics to a raster format, which should probably be avoided. – AJK Sep 09 '16 at 19:03
1

I keep separate files for every subfigure, which may be created using different means.

I use LaTeX to create a pdf for the entire figure, which combines the subfigures. In this way there is one pdf file corresponding to each figure. The tex file is to arrange the subfigures according to the desired layout, as well as to place the (a), (b), (c). I use overpic to do the latter. The package textpos is useful for the former.

In the tex file for the document, the figures are inserted using the usual includegraphics command, and for each figure there is one includegraphics command.

Not sure if this helps. Probably you are already doing this and are looking for something more efficient.

adipro
  • 8,488
  • 6
  • 44
  • 88
0

There's the usual automation tradeoff: https://xkcd.com/1319/

In practice, I end up using Inkscape (Illustrator if your school has a license, I guess) to manually put figures together from different parts for the final submission. This allows export to PDF or TIFF, and hasn't given me too many hassles.

If you are going to be regenerating these figures all the time, i.e. there's a big collaboration and everyone will be submitting new versions of these figures, or if you have a paper with 100s of figures, it might be worth it to develop a script using ImageMagick to connect all of those different pieces together, using montage and labeling: http://www.imagemagick.org/Usage/annotating/ However, the circumstances where this is a good use of time are going to be pretty rare! (Also note this is going to be better for raster output.)

AJK
  • 4,757
  • 19
  • 23