help openall
-------------------------------------------------------------------------------

Title

openall -- Open many data sets by appending them

Syntax

openall [files], [directory(string)] [storefilename(string)] [insheet]

Description

openall clears the currently active dataset, then appends together all the files specified.

Options

files specifies the files to append together. The extension (e.g. ".dta") shou > ld not be specified. Wildcards (e.g. *) are acceptable. If not present, def > aults to all Stata data files (.dta) in the current directory, or all .csv fi > les if insheet is specified.

directory specifies the directory the files are located in. If not present, de > faults to the current directory (see pwd).

storefilename specifies a variable to hold the filename from whence each observ > ation came.

insheet specifies that the files to be read in are in CSV format.

Examples

openall pop_US* pop_CA*, directory(c:/data/) storefilename(file)

openall sheet*, directory(c:/data/) insheet