Sponsored links: Algebra eBooks
 

Help Index

A

B

C

D

E

F

G

H

I

J

K

L

M

N

O

P

Q

R

S

T

U

V

W

X

Y

Z

The Maxima on-line user's manual

Algebra Calculator

Search:

File_search

Function: file_search (<filename>)

file_search("*");

Function: file_search (<filename>, <pathlist>) file_search searches for the file <filename> and returns the path to the file (as a string) if it can be found; otherwise file_search returns false. file_search (<filename>) searches in the default search directories, which are specified by the file_search_maxima, file_search_lisp, and file_search_demo variables.

file_search first checks if the actual name passed exists, before attempting to match it to "wildcard" file search patterns. See file_search_maxima concerning file search patterns.

The argument <filename> can be a path and file name, or just a file name, or, if a file search directory includes a file search pattern, just the base of the file name (without an extension). For example,

file_search ("/home/wfs/special/zeta.mac"); file_search ("zeta.mac"); file_search ("zeta");

all find the same file, assuming the file exists and /home/wfs/special/###.mac is in file_search_maxima.

file_search (<filename>, <pathlist>) searches only in the directories specified by <pathlist>, which is a list of strings. The argument <pathlist> supersedes the default search directories, so if the path list is given, file_search searches only the ones specified, and not any of the default search directories. Even if there is only one directory in <pathlist>, it must still be given as a one-element list.

The user may modify the default search directories. See file_search_maxima.

file_search is invoked by load with file_search_maxima and file_search_lisp as the search directories.

There are also some inexact matches for file_search. Try ?? file_search to see them.

(%o1)                                true
(%i2) 

Related Examples

file_search-load-read_list

load (descriptive);

s1 : read_list (file...

histogram ( ...

Calculate

file_search-length-load-matrix-read_matrix

load(descriptive);

load(numericalio);

s:read_matrix (file_s...

Calculate

file_search-length-load-matrix-read_matrix-var

load(descriptive);

load(numericalio);

s:read_matrix (file_s...

Calculate

file_search-load-matrix-read_matrix

load (descriptive);

s2 : read_matrix(fil...

boxplot(s2, ...

Calculate

file_search-load-read_list

load (descriptive);

s1 : read_list (file_...

piechart( s1, ...

Calculate

file_search-load-plot2d-read_list-sin
plot2d(sin(x),[x,-5,5]);

plot2d(sin(x),[x,-5,5]);

load (descriptive);

s1 : read_list (file...

Calculate

file_search-load-matrix-read_matrix

load (descriptive);

s2 : read_matrix(fil...

boxplot(s2, ...

Calculate

file_search

file_search("/*");

Calculate

file_search-load-read_list

load (descriptive);

s1 : read_list (file_...

histogram ( ...

Calculate

file_search-length-load-matrix-read_matrix

load(descriptive);

load(numericalio);

s:read_matrix (file_s...

Calculate