Copyfile with variable as destination

조회 수: 7 (최근 30일)
Bradley Robert
Bradley Robert 2019년 5월 29일
댓글: Stephen23 2019년 5월 29일
I am trying to copy a folder (A) in a directory, to the same directory with a variable as a name, but Matlab doesn't recognize the variable
Example:
saveName = 1234_fMRI
copyfile = *fMR* saveName
This creates a new folder in the directory called "saveName" where it needs to be a folder called 1234_fMRI
Help. Please.
Brad R.

채택된 답변

Walter Roberson
Walter Roberson 2019년 5월 29일
saveName = '1234_fMRI'
copyfile('*fMR*', saveName)

추가 답변 (0개)

카테고리

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

태그

제품


릴리스

R2019a

Community Treasure Hunt

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

Start Hunting!

Translated by