How do i put a title for my entire subplot?

i have a 3x3 subplot with the first component looking like this:
subplot(3,3,1),plot(AnkleAng_X(:,1:5))
title('Transverse Plane')
ylabel('Ankle Angle(°)')
I want to put a title at the top of the subplot. My code will create 4, 3x3 subplots so i need titles to differentiate each of them.

 채택된 답변

Image Analyst
Image Analyst 2014년 12월 8일

1 개 추천

댓글 수: 3

Leelai
Leelai 2014년 12월 13일
works great thanks!
Souarv De
Souarv De 2021년 2월 18일
Awesome. It works.
But that was the 7 year old answer. Now the preferred way is to use sgtitle() like Cris mentioned below, instead of suptitle().

댓글을 달려면 로그인하십시오.

추가 답변 (1개)

Cris LaPierre
Cris LaPierre 2018년 10월 25일

12 개 추천

There is now (in r2018b) a function in base MATLAB for placing a title over a grid of subplots. It is called sgtitle.

카테고리

도움말 센터File Exchange에서 2-D and 3-D Plots에 대해 자세히 알아보기

질문:

2014년 12월 8일

댓글:

2021년 2월 19일

Community Treasure Hunt

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

Start Hunting!

Translated by