필터 지우기
필터 지우기

Undefined function or variable

조회 수: 9 (최근 30일)
Thao Ha
Thao Ha 2017년 12월 4일
댓글: Thao Ha 2017년 12월 5일
When I tried to run the file "project.m" in the folder "C:\Users\MyName\Documents\MATLAB", it always showed the error "Undefined function or variable 'project'" even though I already set PATH for MATLAB to point to that MATLAB folder. I have a student license lasting till Oct 31, 2018
  댓글 수: 19
KL
KL 2017년 12월 5일
What happens if you close matlab and double-click open your m-file from your file explorer. That should open the file with its corresponding folder as working directory.
Thao Ha
Thao Ha 2017년 12월 5일
It still shows:
project 'project' is not found in the current folder or on the MATLAB path, but exists in: C:\DATA\WSU-Thao\Fall 2017\MATLAB
Change the MATLAB current folder or add its folder to the MATLAB path.

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

답변 (2개)

KL
KL 2017년 12월 4일
You still haven't answered how you set the path. Use addpath,
addpath('C:\Users\MyName\Documents\MATLAB')
  댓글 수: 1
Thao Ha
Thao Ha 2017년 12월 4일
편집: Thao Ha 2017년 12월 4일
I set matlab PATH by clicking on the "Set Path" icon on toolbar. I have followed your instruction to use addpath command but it did not help. The error still remains.

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


Walter Roberson
Walter Roberson 2017년 12월 5일
You need to contact Mathworks for installation support.

카테고리

Help CenterFile Exchange에서 Startup and Shutdown에 대해 자세히 알아보기

제품

Community Treasure Hunt

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

Start Hunting!

Translated by