The below TimelinePlot produces the proper figure within a Mathematica session, but when that figure is exported as an .eps figure (to be used in a $\LaTeX$ document) all portions appear except the vertical GridLines. (They do appear if the figure is exported as a BMP format as shown below, but that format cannot be integrated into a $\LaTeX$ document under the $\LaTeX$ version I'm running. I prefer .eps format for a number of other reasons as well.)

I'm using Mathematica version 10.1 under OS X on a Mac Pro.

timeLine = TimelinePlot[{
   {Labeled[Interval[{{2016, 1, 1}, {2016, 6, 15}}], "aaa"], 
    Labeled[Interval[{{2016, 2, 1}, {2016, 5, 15}}], "bbb"],
    Labeled[Interval[{{2017, 5, 5}, {2017, 8, 1}}], "ccc"]},
   {Labeled[Interval[{{2017, 4, 15}, {2018, 1, 1}}], "ddd"],
    Labeled[Interval[{{2018, 4, 15}, {2019, 1, 1}}], "eee"]}},
  PlotRange -> {{{2016, 1, 1}, {2018, 12, 15}}},
  GridLines -> {Automatic, None},
  GridLinesStyle -> {{Dashed, Green}, None},
  PlotStyle -> {Blue, Red},
  Spacings -> {1, 5},
  PlotLegends -> Placed[{"AAA", "BBB"}, Bottom],
  ImageSize -> 700]

How can I get the GridLines to export in the .eps format?

my TimelinePlot


1 Answer 1


Figured it out. For some unknown reason, GridLines created with DateRange and Quantity magically export in .eps.

 GridLines -> {DateRange["2016", "2019", Quantity[3, "Months"]], None}

I have no idea why this form works while Automatic does not.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.