2

enter image description hereMy problem ist, that the filled Area overlays a part of the x-axis. Is there a possibility to fill the area without hiding a part of the x-axis?

\begin{figure}[H]
\centering
\begin{tikzpicture}
\begin{axis}[
         scale only axis,
         axis x line=middle,
         axis y line=middle,
         inner axis line style={=>},
                 width=15cm,height=6cm,
                     ymin=0,ymax=0.45,
                     xmin=-3.5,xmax=3.5,
                     axis line style = thick,
                     xtick={-3,-2,-1,1,2,3},
                     ytick={0.1,0.2,0.3,0.4},
                 every axis x label/.style={at={(current axis.right of 
         origin)},anchor=west},
         every axis y label/.style={at={(current axis.north)},above=0.5mm},
                 xlabel={$x$},
                 ylabel={$f(x)$}
        ]
      \addplot[fill=blue!25,draw=none,domain=1.63:3.5] {gauss(0,1)} 
      \closedcycle;]
      \addplot [domain=-3.5:3.5,samples=500,red,thick] {gauss(0,1)};
        \node[below] at (1.63,0)  {\Large \textcolor{black}{$\mu_{3}$}};
       \end{axis}
       \end{tikzpicture}
        \caption{Graph der Dichtefunktion $f_X(x)$ mit $X\sim\mathcal{N}
       (0,1)$}%
\end{figure}
Stefan Pinnow
  • 29,535
David
  • 21
  • 1
  • 2
    try add axis on top, to axis options. for more, please extend your code to complete small document caled "minimal working example" (https://tex.meta.stackexchange.com/questions/228/ive-just-been-asked-to-write-a-minimal-example-what-is-that). welcome to tex.se! an – Zarko Dec 15 '17 at 19:49
  • axis on top in the axis option works fine. thanks!! – David Dec 15 '17 at 20:01
  • @daqvid, anyway, please provide complete small document (mwe), that i will have less work to write an answer, or you prefer to close question as "solved by comment"? – Zarko Dec 15 '17 at 20:05
  • 3
    I'm voting to close this question as off-topic because solved by comment. – Zarko Dec 15 '17 at 20:18
  • I wouldn't vote to close this because it was solved in the comments. It's probably a duplicate, which would perhaps be a more reasonable reason to vote to close... – cmhughes Dec 15 '17 at 21:15

0 Answers0