problème avec les working directory
bonsoir,
j'aimerai exécuter un script qui n'est pas dans mon working directory matlab.
Mon script s'appelle script, il est dans C:\tata\toto. mon working directory est C:\matlab\work.
je rajoute le chemin vers mon script dans matlab path:
Code:
1 2
|
>>addpath C:\tata\toto |
j'exécute ensuite:
Code:
1 2 3 4 5 6
|
path='C:\tata\toto';
kk=sprintf(path,'%s',script);
eval('run %s',kk); |
et matlab m'affiche comme erreur,
Code:
1 2 3 4 5 6
|
??? Attempt to execute SCRIPT script as a function.
Error in ==> start at 7
kk=sprintf(path,'%s',script); |
Je crois que j'ai fait une erreur de syntaxe. pouvez vous la corriger ?
merci beaucoup,