我有以下取自示例的代码:
\documentclass{article}
\usepackage{pgfplots,pgfplotstable}
\begin{document}
\begin{tikzpicture}
\pgfplotstableread{
plot1 plot2 plot3 plot4
0 0 0 0
3.466 2.058 0 0
4.262 2.976 0.001 0
3.822 3.168 0.006 0.008
2.953 2.936 0.019 0.063
2.065 2.492 0.046 0.265
1.332 1.977 0.092 0.734
0.797 1.478 0.164 1.508
0.443 1.045 0.268 2.44
0.228 0.698 0.412 3.219
0.107 0.438 0.598 3.524
0.046 0.256 0.831 3.219
0.017 0.138 1.109 2.44
0.006 0.067 1.429 1.508
0.002 0.029 1.78 0.734
0 0.01 2.141 0.265
0 0.003 2.479 0.063
0 0.001 2.736 0.008
0 0 2.808 0
0 0 2.465 0
0 0 0 0
}\dummydata
\begin{axis}[
samples=30,
domain=-4:4,
samples y=0, ytick={1,...,4},
zmin=0,
area plot/.style={
fill opacity=0.75,
draw=orange!80!black,thick,
fill=orange,
mark=none,
}
]
\pgfplotsinvokeforeach{4,3,...,1}{
\addplot3 [area plot] table [x expr=\coordindex, y expr=#1, z=plot#1] {\dummydata};
}
\end{axis}
\end{tikzpicture}
\end{document}
因此我开始使用它并提供我的数据:
\documentclass{article}
\usepackage{pgfplots,pgfplotstable}
\begin{document}
\begin{tikzpicture}
\pgfplotstableread{
plot1 plot2 plot3 plot4
33747 33106 32755 32930
33509 32593 34302 33049
33872 32091 34332 33215
33019 32247 34372 33256
33120 32625 32874 33547
33177 34026 34586 33158
32875 35361 34835 33125
33118 33176 31211 33604
34313 34541 33225 32763
32968 32928 33855 33702
33086 33252 31636 34113
34200 33695 32812 33003
32568 33940 32663 40287
32656 32893 34264 20548
33318 35521 34196 41851
32601 29895 33255 33100
34217 34852 33790 34922
33149 33691 31934 31673
34077 32532 33860 32766
32832 34082 33221 33544
32835 33256 33164 33222
32746 33081 32762 31282
33962 32996 33580 33369
32896 33818 33053 36396
33168 32747 33373 31252
33680 33286 38413 35094
32870 33949 21930 28687
33661 35410 38583 35524
34272 31062 33643 34092
33488 33348 33521 32926
}\dummydata
\begin{axis}[
samples=30,
domain=-4:4,
samples y=0, ytick={1,...,4},
zmin=0,
area plot/.style={
fill opacity=0.75,
draw=orange!80!black,thick,
fill=orange,
mark=none,
}
]
\pgfplotsinvokeforeach{4,3,...,1}{
\addplot3 [area plot] table [x expr=\coordindex, y expr=#1, z=plot#1] {\dummydata};
}
\end{axis}
\end{tikzpicture}
\end{document}
哪里有问题?