How to shift X Axis position

Home Forums Matlab How to shift X Axis position

This topic contains 1 reply, has 2 voices, and was last updated by  cK 10 years, 1 month ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #477

    pankaj kumar
    Participant

    For 2D plot where Y axis vary from -10 to 10 and I like to shift X axis passing from zero of Y axis ie its mid point rather than bottom corner point. May I know simple way or matlab command to do this shift of X-axis line.

    #478

    cK
    Keymaster

    I dont think there is a simple way to put axis in middle of plot, but you can have it at top, rather than at bottom (default).
    set(gca,’xAxisLocation’,'top’)

    • This reply was modified 10 years, 1 month ago by  cK.
    • This reply was modified 10 years, 1 month ago by  cK.
    • This reply was modified 10 years, 1 month ago by  cK.
Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.