Thickness of Tick mark

47 views (last 30 days)
Khalid Alsinan
Khalid Alsinan on 17 Jul 2022
Answered: dpb on 17 Jul 2022
How do I change the thickness of only some of the tick marks on my plot?

Answers (1)

dpb
dpb on 17 Jul 2022
There is no such property for the axes ticks to change individual tick marks -- some possible workarounds (not tried any of these, just the things that come to mind as first-shot attempts to create the effect)
  1. Set additional tick values at select ticks +/- some small epsilon so the new ticks are just offset from original. Will then have to use ticklabels to label only the ones wanted; can't turn ticklabels on/off on individual level, either.
  2. Add second axes with above idea -- then can just set the second axis ticklabels to empty
  3. Draw a heavier line at the desired tick locations with plot() with the desired line width.
The last of the above is probably the simplest...

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!