Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I have two plots drawn with the \pgfplots package. In one of them, I specified that ymin=0 when I created the axis since the plotted curve never goes below y=0 (otherwise something like ymin=-0.2 would be used). However, when I put both of the plots into two \subcaptionboxes that I put in the same figure environment, it becomes apparent that this plot has become raised up, since the frame is much higher up for that plot than the frame for the other plot:

enter image description here

How can I prevent \pgfplots from raising up the plot when I specify (hence increasing?) the value of ymin? I want the frames of both plots to be aligned vertically.

share|improve this question
1  
Add the code, to help us trying. Anyway, may be you should look at groupplots in the documentation (in case you are not using it). –  Manuel Dec 22 '12 at 15:33
    
@Manuel: I figured out the reason for this behavior myself, and it wasn't the ymin=0 specification that I said it was. See my answer below. –  StrawberryFieldsForever Dec 22 '12 at 15:43
    
@Manuel: I updated the answer; I realized my initial explanation was incorrect. –  StrawberryFieldsForever Jan 26 '13 at 14:46
add comment

closed as too localized by Jake, Werner, Thorsten, Kurt, Torbjørn T. Dec 22 '12 at 20:59

This question is unlikely to help any future visitors; it is only relevant to a small geographic area, a specific moment in time, or an extraordinarily narrow situation that is not generally applicable to the worldwide audience of the internet. For help making this question more broadly applicable, visit the help center.If this question can be reworded to fit the rules in the help center, please edit the question.

1 Answer

up vote 1 down vote accepted

I realized that it wasn't the ymin=0 specification that messed up the vertical alignment. This behavior was instead triggered depending on of which sizes the \subcaptionboxex were. It turned out that if they are too large, this misalignment is likely to happen, although I don't really know why.

share|improve this answer
add comment

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