TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

To remove the ticks of a figure (and not the tick labels), I could only find the opacity trick, that I find odd. Is there any better way?

\pgfplotsset{minor grid style={color=black!20,line width=0.25pt},major grid style={color=black!30,line width=0.35pt},tick style={opacity=0}}
\begin{semilogyaxis}[grid=both,scale only axis,width=7cm,height=5cm,xmin=0,xmax=2.4,ymin=1e-008,ymax=0.01,,axis background/.style={fill=black!3},xlabel=$\omega$,ylabel=$|X_5(\omega)|$,xtick={0,0.4,0.8,1.2,1.6,2,2.4},xticklabels={$0$,$$,$50$,$$,$100$,$$,$150$},ytickten={-8,-7,-6,-5,-4,-3,-2},yticklabels={$10^{-8}$,$$,$10^{-6}$,$$,$10^{-4}$,$$,$10^{-2}$}]
share|improve this question
up vote 5 down vote accepted

You could also use tick style={draw=none}. This has the added flexibility in that you could change the color of the ticks with something like tick style={draw=red}

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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