how to use functions from private directories
Mostra commenti meno recenti
While I was trying to improve the performance of Excel file reading and writing, I've noticed that xlsread is using some other functions, located in a directory called ...\toolbox\matlab\iofun\private. I wrote a new function, which is composed of the code of xlsread, but it was impossible to access some functions that reside in the location above.
I tried using addpath:
addpath(fullfile(matlabroot, 'toolbox\matlab\iofun\private\'))
but I got a warning saying:
Warning: Private directories not allowed in MATLAB path
1. what's the reason for that?
2. are there any workarounds except of copying all the necessary related functions to my working directory?
Risposta accettata
Più risposte (1)
Walter Roberson
il 7 Giu 2015
Modificato: Walter Roberson
il 7 Giu 2015
2 voti
Private functions cannot be called directly from outside routines, except by making copies of them.
Categorie
Scopri di più su Search Path in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!