I want to plot a dataset in a 3D pgfplots graph. It looks like a good start but somehow the label placement is far out. Boiling it down to a MWE did not give me any hints how to get the labels back in place. Is there any option I overlooked? My pgf and pgfplots version's are fairly recent, so it should not be this issue: 3d axis label ovelapping.

Here is my almost minimal example:



as_concentration    T   
0.00        0.0
0.00        0.152   
0.13        0.00    

as_concentration    T   
0.00        0.152   
0.13        0.00    

    ymin=-0.1, ymax=0.25, xmax=0.19, xmin=0,    zmax=0.3,
    axis lines=center,
    \addplot3 [forget plot,no marks,fill=blue, opacity=0.5] 
                     table[x=as_concentration,y expr=0,z=T] {\ascycledata}; 

    \addplot3+ [] table[x=as_concentration,y expr=0,z=T]    {\asdata};              


And the output with the axis labels far away:

wrong result

  • 1
    Looks like it's due to axis lines=center option. – percusse Feb 27 '13 at 23:25
  • Ah, that is already a nice hint. Some searching with this keyword revealed: "That is a known bug ..." by Christian Feuersänger (tex.stackexchange.com/questions/84442/…). So that answers my question already. – Alexander Feb 27 '13 at 23:34

With percusse's hint it turns out that this problem is a known bug in pgfplots 1.7 (see: pgfplots: labels and width issues in non-boxed 3d plot with oblique projection).

Christian Feuersänger already fixed this in the most recent unstable version of pgfplots (1.7-181-gc021eee). The fixed behavior needs to be enabled via the explicit use of the new version: \pgfplotsset{compat=1.8}.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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