How do i clear all except one variable?
조회 수: 605 (최근 30일)
이전 댓글 표시
I want to clear all variables except one
entering all variable to be cleared is a lengthy process, has many variables and function
댓글 수: 0
채택된 답변
Walter Roberson
2018년 12월 18일
clearvars -except NAME
댓글 수: 2
Pedapudi Bharath Raja Bhoopal
2020년 12월 14일
Thankyou it worked
clearvars -except X %deletes all variables except X in workspace
Matthew Creek
2023년 8월 24일
Here are some links to related documentation:
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Workspace Variables and MAT Files에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!