legend

조회 수: 3 (최근 30일)
Bahareh
Bahareh 2011년 10월 22일
I have a matrix m which varies with vectors a and b. I've plotted m versus a for different values of b, but I don't know how to set the legend command corresponding different values for b. I will be so grateful if somebody can help me.

채택된 답변

Mitch Martelli
Mitch Martelli 2011년 10월 22일
Try
  • if b is a numerical vector with:
legend(num2str(b(:)))
  • If b is a string vector :
legend(b)
  댓글 수: 2
Jan
Jan 2011년 10월 22일
What is a "string vector"?
Mitch Martelli
Mitch Martelli 2011년 10월 23일
I cant write english very well... I'm sorry...I dont find an other way to explain what I think...

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

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Legend에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by