Batch file processing = Yes |
This is for 32-bit Facets 3.87. Here is Help for 64-bit Facets 4
To avoid Facets requesting user intervention when it is run in batch mode from the DOS prompt or otherwise, include Batch=Yes on the command line in your.bat or .cmd file.
1. Construct a Facets specification and data file that works correctly when launched in the usual way. Let's say this is "c:\myfolder\myspec.txt".
2. Let say that facets.exe is in "c:\facets\facets.exe"
3. Construct a text file which contains:
START /WAIT "c:\facets\facets.exe" BATCH=NO "c:\myfolder\myspec.txt" "c:\myfolder\myoutput.txt"
4. Save the text file and rename it "c:\myfolder\mybatch.bat"
5. Double-click on "c:\myfolder\mybatch.bat"
6. Facets will run in batch mode and you will see its operation on your screen. The output is in c:\myfolder\myoutput.txt
7. Exit from Facets.
8. Edit "c:\myfolder\mybatch.bat" to be
START /WAIT "c:\facets\facets.exe" BATCH=YES "c:\myfolder\myspec.txt" "c:\myfolder\myoutput.txt"
9. Double-click on "c:\myfolder\mybatch.bat"
10. Facets will run in hidden batch mode. Its output is in c:\myfolder\myoutput.txt
The general format is: Facets BATCH=YES specification-file output-file extra-specifications
It is often useful to run multiple Facets tasks, one after the other, without keyboard intervention. This can be accomplished by running Facets in CMD batch mode.
Here is a typical .CMD file. It is Facetsxp.cmd in the Examples folder. Double-click on it to launch it.
echo This is the version for Windows-NT, 2000
echo This is a batch file to run Facets in batch mode
echo Edit the next lines and add more.
echo Format of lines is:
echo START /WAIT ..\Facets BATCH=YES Control-file Output-file Extra=specifications
START /WAIT ..\Facets BATCH=YES dives.txt dives.out.txt
START /WAIT ..\Facets BATCH=YES lfs.txt lfs.out.txt
START /WAIT ..\Facets BATCH=YES kct.txt kct.out.txt
Example 1: Simulate and analyze 1000 Facets data sets from lfs.txt
Create text file "Simul.bat" in the Examples folder, copy this text into it, save and double-click on Simul.bat
Rem Simulate and analyze 1000 data sets
rem perform analysis of the original data and write out the anchor values
START /WAIT c:\facets\ BATCH=YES lfs.txt specfile.out.txt anchorfile=lfsanc.txt
SET /A COUNT=1
:LOOP
echo Loop number %COUNT%
rem do this 1000 times
IF %COUNT% == 1001 GOTO END
rem generate simulate data file from lfsanc.txt to avoid re-estimation each time
START /WAIT c:\facets\Facets BATCH=YES lfsanc.txt specfile.out.txt simul=s%COUNT%.txt
rem analyze original file replacing data in lfs.txt with the simulated data
START /WAIT c:\facets\ BATCH=YES lfs.txt s%COUNT%.out.txt data=s%COUNT%.txt scorefile=sc%COUNT%.txt
rem accumulate scorefiles by facet
type sc%COUNT%1.txt >> cand.results.txt
type sc%COUNT%2.txt >> rater.results.txt
type sc%COUNT%3.txt >> paper.results.txt
type sc%COUNT%4.txt >> task.results.txt
SET /A COUNT=COUNT+1
GOTO LOOP
:END
PAUSE
Example 2: Simulate and analyze multiple Facets data sets from lfs.txt using %include files:
At the top of the lfs.txt file, add this line:
%include.txt
Create text file "Simul.bat" in the Examples folder, copy this text into it, save and double-click on Simul.bat
Rem Simulate and analyze 1000 data sets
rem perform analysis of the original data and write out the anchor values
START /WAIT c:\facets\ BATCH=YES lfs.txt specfile.out.txt anchorfile=lfsanc.txt
SET /A COUNT=1
:LOOP
echo Loop number %COUNT%
rem do this 1000 times
IF %COUNT% == 1001 GOTO END
rem generate simulate data file from lfsanc.txt to avoid re-estimation each time
START /WAIT c:\facets\Facets BATCH=YES lfsanc.txt specfile.out.txt simul=s%COUNT%.txt
rem analyze original file replacing data in lfs.txt with the simulated data
echo "s%COUNT%.out.txt data=s%COUNT%.txt scorefile=sc%COUNT%.txt" >include.txt
START /WAIT c:\facets\ BATCH=YES lfs.txt
rem accumulate scorefiles by facet
type sc%COUNT%1.txt >> cand.results.txt
type sc%COUNT%2.txt >> rater.results.txt
type sc%COUNT%3.txt >> paper.results.txt
type sc%COUNT%4.txt >> task.results.txt
SET /A COUNT=COUNT+1
GOTO LOOP
:END
PAUSE
Help for Facets Rasch Measurement and Rasch Analysis Software: www.winsteps.com Author: John Michael Linacre.
Facets Rasch measurement software.
Buy for $149. & site licenses.
Freeware student/evaluation Minifac download Winsteps Rasch measurement software. Buy for $149. & site licenses. Freeware student/evaluation Ministep download |
---|
Forum: | Rasch Measurement Forum to discuss any Rasch-related topic |
---|
Questions, Suggestions? Want to update Winsteps or Facets? Please email Mike Linacre, author of Winsteps mike@winsteps.com |
---|
State-of-the-art : single-user and site licenses : free student/evaluation versions : download immediately : instructional PDFs : user forum : assistance by email : bugs fixed fast : free update eligibility : backwards compatible : money back if not satisfied Rasch, Winsteps, Facets online Tutorials |
---|
Our current URL is www.winsteps.com
Winsteps® is a registered trademark