Important new features of the package include a simplified command language for LISREL, imputation of missing values in PRELIS (using the "hotdeck" method), bootstrap resampling, and Monte Carlo simulation.
lisrel8You should get a small graphics screen which will ask you for the names of your command file and output file. It looks something like this:
(Sample Screen Shot for Text-based browsers)
Input File [input]:
After you type the name of your input file (command file) , LISREL prompts you for the name of the output file. It also prompts you to correct errors.
The PRELIS command is prelis2, and the PRELIS screen looks essentially the same and operates in the same manner as LISREL.
If you don't want the prompt and the graphics screen, type --
lisrel8 command_file output_file -noquery
LISREL example:
Suppose you have the following commands in a file called model1.lis: (This example is available on the central UNIX systems and is stored in the file /opt/lib/lisrel/examples/ls8ex/ex1.ls8 .)
Hypothetical model estimated by ml da ni=11 no=100 cm sy fi=ex1.cov mo ny=4 nx=7 ne=2 nk=3 be=fu ps=sy,fr fr ly 2 1 ly 4 2 lx 2 1 lx 3 1 lx 3 2 lx 5 2 lx 7 3 be 2 1 be 1 2 fi ga 1 3 ga 2 2 va 1 ly 1 1 ly 3 2 lx 1 1 lx 4 2 lx 6 3 ou mi rs ef mr ss sc
This command file instructs LISREL to read the covariance matrix from the file ex1.cov. It is one of several LISREL example files in that directory. To run LISREL with these commands and have your output stored in model1.lst, type
lisrel8 model1.lis model1.lst -noqueryAny errors from a run using the -noquery flag are stored in a file called lisrel8.log. If there are no errors you should get a message indicating normal execution.
NOTE: The prelis2.log indicates abnormal termination even when the run ended without errors.
Run PRELIS the same way, except substitute the prelis2 command for lisrel8.
Many applications use output generated by PRELIS as input to LISREL. The following example uses PRELIS commands modified from /opt/lib/lisrel/examples/simex/simex13.pr2 and LISREL commands modified from /opt/lib/lisrel/examples/simex/simex14.ls8. Suppose the PRELIS command file is called smodel1.pre.
PRELIS commands: Generating multivariate normal variables with a specified covariance matrix da no=200 rp=40 ne v1=nrand ne v2=nrand ne v3=nrand ne v4=nrand ne v5=nrand ne v6=nrand ne x1=v1 ne x2=.378*v1+.925806*v2 ne x3=.72*v1+.068956*v2+.690540*v3 ne x4=.324*v1+.321372*v2+.047151*v3+.88855*v4 ne x5=.27*v1+.26781*v2+.039292*v3+.140229*v4+.913329*v5 ne x6=.27*v1+.025858*v2+.063453*v3+.010374*v4+.006818*v5+.960339*v6 co all sd v1-v6 ou cm=smodel1.cm xm ix=123456
Further suppose that the LISREL command file is called smodel1.lis.
LISREL commands: Fitting a confirmatory factor analysis model in each of 40 samples da ni=6 no=200 rp=40 cm=SMODEL1.CM mo nx=6 nk=2 fr lx(1,1) lx(2,2) lx(3,1) lx(4,2) lx(5,2) lx(6,1) ou ad=off pv=simex1.pv sv=simex1.sv gf=simex1.gf xm
To get results from this application, run PRELIS first, so it can produce the file SMODEL1.CM, and then run LISREL. For example:
prelis2 smodel1.pre smodel1a.lst -noquery lisrel8 smodel1.lis smodel1b.lst -noqueryNOTE: Even though the filename of the output file in the PRELIS command file is in lower-case letters, PRELIS outputs a file whose name is all in upper-case letters; hence, you MUST use the upper-case version in the LISREL command file. (If you run examples from the /opt/lib/lisrel/examples/simex directory, you may have to change filenames in the LISREL command files).
The following somewhat cryptic looking alias can be placed in your .localalias file (in your home directory) to run both PRELIS and LISREL, and display the LISREL log file on your screen --
alias pre_lis 'prelis2 \!*.pre \!*a.lst -noquery;' \ 'lisrel8 \!*.lis \!*b.lst -noquery;' \ 'cat lisrel8.log'To use this command with the above two example files, type:
pre_lis smodel1Output from the PRELIS run will be put in smodel1a.lst and output from the LISREL run put in smodel1b.lst. The LISREL log file lisrel8.log. will be displayed on your screen.
cp /opt/lib/lisrel/examples/ls8ex/* .This copies all the example files in /opt/lib/lisrel/examples/ls8ex to your current directory. Do likewise for any of the other example directories.
NOTE: The name of a file in any one of the example directories may match the name of a file in any one of the other example directories. So, if you copy examples from more than one example directory, you may want to construct a unique directory name on your own account to hold examples from each of the LISREL/PRELIS example directories.
cd unset noglob; ~consult/proto/setupThe second command replaces your current .login and .cshrc files after first making backup copies. (The backup copiess have the current date appended to the filename.) You can copy commands you've added to your earlier "dot" files to the end of your new ones -- aliases to .localalias and environment settings (e.g., defining your PATH) to .localenv.
After issuing these commands, log out and log in again to have them take effect.
LISREL manuals:
February 7, 1996