How to display a single element from a matrix?
조회 수: 154 (최근 30일)
이전 댓글 표시
Hi, I was wondering how I would be able to display a singular element from a given matrix. If I were to have a random integer matrix
x = randi (20,20)
how would I go about selecting or highlighting the given value from a random row/column combination (say I want to know what vlaue is at [5, 7])? Thanks in advance for the advice.
댓글 수: 1
답변 (1개)
Jan
2022년 9월 15일
Indexing is a fundamental Matlab method. To learn the basics asking in the forum is less efficient than using the tutorials:
- Getting Started chapters of the documentation
- https://www.mathworks.com/learn/tutorials/matlab-onramp.html
댓글 수: 0
참고 항목
카테고리
Help Center 및 File Exchange에서 Logical에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!