|
I'm having difficulty with a file getting the following error message:
>Error # 34. Command name: get file >SPSS cannot access a file with the given file specification. The file >specification is either syntactically invalid, specifies an invalid drive, >specifies a protected directory, specifies a protected file, or specifies a >non-sharable file. >This command not executed. I am using this file fine with other programs so not sure what the problem is. I'll give the first few lines of code below. Note, this is from the Health Care Utilization Project State Inpatient Database [HCUP-SID] data sets which contain charge and diagnosis data from hospital discharges. I have converted the raw data into SPSS .sav files and have manipulated these files in other programs. I am currently trying to get the AHQR supplied syntax to work with the converted file to get quality indicators for each record. Thanks, John Here is the first few screens of the AHRQ supplied program: define pssps1 (). *----------------------------------------------------------------. * * Title: PSSPS1.SPS (Program 1) * Purpose: Assign AHRQ Patient Safety Indicators (PSI) and * comorbidity flags to inpatient records. * Version: 3.0a, April 2006 * PSI definitions only reflect ICD-9-CM and DRG codes valid from * October 1, 1997 through September 30, 2006. * Please review the SPSS software documentation thoroughly * before running the PSI programs. * * Note: In order to run this program, the following parameters * must be set to reflect your data and your computer: * !infile= should specify the name of the input SPSS data * file (including the directory path) where user's * data are located. We recommend all processing be * done on a local drive, not across a network. * !outfile= should specify the name of the output SPSS data * file (including the directory path) where flagged * inpatient data are to be saved. We recommend using the * file name provided, e.g., psi1.sav, as the outfile name * is referred to in the subsequent program (psspsp2.sps). * !lastdx= the number of dx variables present in the input data file. * !lastpr= the number of pr variables present in the input data file. * !prday = yes/no flag indicating whether user's inpatient data file * (input data) contains the optional variables for procedure days. * !malevl= 0, 1, 2 or 3 to indicate if and how county land * areas should be aggregated into modified FIPS codes * or metropolitan statistical areas (MSA). * 0-leave data at county level with U.S. Census FIPS. * 1-County level with Modified FIPS. * 2-Metropolitan Area level with OMB 1999 definition. * 3-Metropolitan Area level with OMB 2003 definition. * !yearqtr= yes/no flag indicating whether the input data set includes * the variables year (of discharge) and dqtr (discharge * quarter). * * Example: The user's input data file is named psidata.sav and is located on * their C: drive in a folder titled "PSItest." The input data file contains * 15 diagnosis codes and 15 procedure codes. It also contains YEAR and DQTR, * and a variable for procedure days. The user wants the analysis to define * urban areas by MSA. The user should change the parameter * settings to: * !let !infile = 'C:\MA_SIDC_2002_CORE.SAV'. * !let !outfile = 'C:\MA_SIDC_2002_CORE.SAV'. * !let !lastdx = 16. * !let !lastpr = 15. * !let !prday = 'Yes' . * !let !malevl = 'Yes' . * !let !yearqtr = 'Yes' . * * IMPORTANT: Do not forget the *.sav extension on the !infile and !outfile * parameters. * * Edit the parameters below to match those of your data and computer. *----------------------------------------------------------------. !let !infile = 'c:\pathname\SIDyy.sav'. !let !outfile = 'c:\pathname\psi1.sav'. !let !lastdx = 30. !let !lastpr = 30. !let !prday = 'Yes' . !let !malevl = '0' . !let !yearqtr = 'Yes' . *----------------------------------------------------------------. * Do not edit below this line. *----------------------------------------------------------------. !let !dxl = !concat('dx',!lastdx). !let !prl = !concat('pr',!lastpr). !let !pdl = !concat('prday',!lastpr). !let !infile = !quote(!infile). !let !outfile = !quote(!outfile). !let !prday = !upcase(!prday). !let !yearqtr = !upcase(!yearqtr). !if (!yearqtr !eq YES) !then !let !addvars = 'year dqtr'. !ifend. get file = !infile /keep =key drg mdc sex age ageday pstco !addvars pay1 hospid disp race los asource atype ndx dx1 to !dxl npr pr1 to !prl !if (!prday = YES) !then prday1 to !pdl !ifend. |
|
My first guess is that there is a typo in the filespec.
to check this start spss click <file> <open> <data> browse to the file that you are interested in. click <paste> highlight and run the pasted syntax. Does that cure your problem? My second guess is that you or someone else has not released the file. I.e., some program has it opened. try rebooting. If you still have the problem, please post the syntax that generates the error. Art Kendall [hidden email] see if this helps John wrote: > I'm having difficulty with a file getting the following error message: > > > > >> Error # 34. Command name: get file >> > > >> SPSS cannot access a file with the given file specification. The file >> > > >> specification is either syntactically invalid, specifies an invalid drive, >> > > >> specifies a protected directory, specifies a protected file, or specifies a >> > > >> non-sharable file. >> > > >> This command not executed. >> > > > > > > I am using this file fine with other programs so not sure what the problem > is. I'll give the first few lines of code below. Note, this is from the > Health Care Utilization Project State Inpatient Database [HCUP-SID] data > sets which contain charge and diagnosis data from hospital discharges. I > have converted the raw data into SPSS .sav files and have manipulated these > files in other programs. I am currently trying to get the AHQR supplied > syntax to work with the converted file to get quality indicators for each > record. > > > > Thanks, John > > > > > > Here is the first few screens of the AHRQ supplied program: > > > > > > > > define pssps1 (). > > > > *----------------------------------------------------------------. > > * > > * Title: PSSPS1.SPS (Program 1) > > * Purpose: Assign AHRQ Patient Safety Indicators (PSI) and > > * comorbidity flags to inpatient records. > > * Version: 3.0a, April 2006 > > * PSI definitions only reflect ICD-9-CM and DRG codes valid from > > * October 1, 1997 through September 30, 2006. > > * Please review the SPSS software documentation thoroughly > > * before running the PSI programs. > > * > > * Note: In order to run this program, the following parameters > > * must be set to reflect your data and your computer: > > * !infile= should specify the name of the input SPSS data > > * file (including the directory path) where user's > > * data are located. We recommend all processing be > > * done on a local drive, not across a network. > > * !outfile= should specify the name of the output SPSS data > > * file (including the directory path) where flagged > > * inpatient data are to be saved. We recommend using > the > > * file name provided, e.g., psi1.sav, as the outfile > name > > * is referred to in the subsequent program > (psspsp2.sps). > > * !lastdx= the number of dx variables present in the input data > file. > > * !lastpr= the number of pr variables present in the input data > file. > > * !prday = yes/no flag indicating whether user's inpatient data > file > > * (input data) contains the optional variables for > procedure days. > > * !malevl= 0, 1, 2 or 3 to indicate if and how county land > > * areas should be aggregated into modified FIPS codes > > * or metropolitan statistical areas (MSA). > > * 0-leave data at county level with U.S. Census FIPS. > > * 1-County level with Modified FIPS. > > * 2-Metropolitan Area level with OMB 1999 definition. > > * 3-Metropolitan Area level with OMB 2003 definition. > > * !yearqtr= yes/no flag indicating whether the input data set > includes > > * the variables year (of discharge) and dqtr (discharge > > * quarter). > > * > > * Example: The user's input data file is named psidata.sav and is located > on > > * their C: drive in a folder titled "PSItest." The input data file > contains > > * 15 diagnosis codes and 15 procedure codes. It also contains YEAR > and DQTR, > > * and a variable for procedure days. The user wants the analysis to > define > > * urban areas by MSA. The user should change the parameter > > * settings to: > > * !let !infile = 'C:\MA_SIDC_2002_CORE.SAV'. > > * !let !outfile = 'C:\MA_SIDC_2002_CORE.SAV'. > > * !let !lastdx = 16. > > * !let !lastpr = 15. > > * !let !prday = 'Yes' . > > * !let !malevl = 'Yes' . > > * !let !yearqtr = 'Yes' . > > * > > * IMPORTANT: Do not forget the *.sav extension on the !infile and !outfile > > * parameters. > > * > > * Edit the parameters below to match those of your data and computer. > > *----------------------------------------------------------------. > > > > !let !infile = 'c:\pathname\SIDyy.sav'. > > !let !outfile = 'c:\pathname\psi1.sav'. > > !let !lastdx = 30. > > !let !lastpr = 30. > > !let !prday = 'Yes' . > > !let !malevl = '0' . > > !let !yearqtr = 'Yes' . > > > > *----------------------------------------------------------------. > > * Do not edit below this line. > > *----------------------------------------------------------------. > > > > !let !dxl = !concat('dx',!lastdx). > > !let !prl = !concat('pr',!lastpr). > > !let !pdl = !concat('prday',!lastpr). > > !let !infile = !quote(!infile). > > !let !outfile = !quote(!outfile). > > !let !prday = !upcase(!prday). > > !let !yearqtr = !upcase(!yearqtr). > > !if (!yearqtr !eq YES) !then > > !let !addvars = 'year dqtr'. > > !ifend. > > > > get file = !infile /keep =key drg mdc sex age ageday pstco !addvars > > pay1 hospid disp race los asource atype ndx dx1 to !dxl npr pr1 to !prl > > !if (!prday = YES) !then prday1 to !pdl > > !ifend. > > > |
|
Related to Art's comments, it could also be that your
credentials (your computer account) do not allow you to access the given file. Your network administrator may not have given you rights to do so. For instance, Jane Doe can access 'secret.sav' but John Doe can't, even though they're both on the same network. Albert-Jan --- Art Kendall <[hidden email]> wrote: > My first guess is that there is a typo in the > filespec. > to check this start spss > click <file> <open> <data> > browse to the file that you are interested in. > click <paste> > highlight and run the pasted syntax. > Does that cure your problem? > > My second guess is that you or someone else has not > released the file. > I.e., some program has it opened. > try rebooting. > > If you still have the problem, please post the > syntax that generates the > error. > > Art Kendall > [hidden email] > > > see if this helps > > John wrote: > > I'm having difficulty with a file getting the > following error message: > > > > > > > > > >> Error # 34. Command name: get file > >> > > > > > >> SPSS cannot access a file with the given file > specification. The file > >> > > > > > >> specification is either syntactically invalid, > specifies an invalid drive, > >> > > > > > >> specifies a protected directory, specifies a > protected file, or specifies a > >> > > > > > >> non-sharable file. > >> > > > > > >> This command not executed. > >> > > > > > > > > > > > > I am using this file fine with other programs so > not sure what the problem > > is. I'll give the first few lines of code below. > Note, this is from the > > Health Care Utilization Project State Inpatient > Database [HCUP-SID] data > > sets which contain charge and diagnosis data from > hospital discharges. I > > have converted the raw data into SPSS .sav files > and have manipulated these > > files in other programs. I am currently trying to > get the AHQR supplied > > syntax to work with the converted file to get > quality indicators for each > > record. > > > > > > > > Thanks, John > > > > > > > > > > > > Here is the first few screens of the AHRQ supplied > program: > > > > > > > > > > > > > > > > define pssps1 (). > > > > > > > > > > > > > * > > > > * Title: PSSPS1.SPS (Program 1) > > > > * Purpose: Assign AHRQ Patient Safety Indicators > (PSI) and > > > > * comorbidity flags to inpatient > records. > > > > * Version: 3.0a, April 2006 > > > > * PSI definitions only reflect ICD-9-CM and DRG > codes valid from > > > > * October 1, 1997 through September 30, > 2006. > > > > * Please review the SPSS software documentation > thoroughly > > > > * before running the PSI programs. > > > > * > > > > * Note: In order to run this program, the > following parameters > > > > * must be set to reflect your data and > your computer: > > > > * !infile= should specify the name of > the input SPSS data > > > > * file (including the > directory path) where user's > > > > * data are located. We > recommend all processing be > > > > * done on a local drive, not > across a network. > > > > * !outfile= should specify the name of > the output SPSS data > > > > * file (including the > directory path) where flagged > > > > * inpatient data are to be > saved. We recommend using > > the > > > > * file name provided, e.g., > psi1.sav, as the outfile > > name > > > > * is referred to in the > subsequent program > > (psspsp2.sps). > > > > * !lastdx= the number of dx variables > present in the input data > > file. > > > > * !lastpr= the number of pr variables > present in the input data > > file. > > > > * !prday = yes/no flag indicating > whether user's inpatient data > > file > > > > * (input data) contains the > optional variables for > > procedure days. > > > > * !malevl= 0, 1, 2 or 3 to indicate if > and how county land > > > > * areas should be aggregated > into modified FIPS codes > > > > * or metropolitan statistical > areas (MSA). > > > > * 0-leave data at county > level with U.S. Census FIPS. > > > > * 1-County level with > Modified FIPS. > > > > * 2-Metropolitan Area level > with OMB 1999 definition. > > > > * 3-Metropolitan Area level > with OMB 2003 definition. > > > > * !yearqtr= yes/no flag indicating > whether the input data set > Cheers! Albert-Jan ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Did you know that 87.166253% of all statistics claim a precision of results that is not justified by the method employed? [HELMUT RICHTER] ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ____________________________________________________________________________________ Choose the right car based on your needs. Check out Yahoo! Autos new Car Finder tool. http://autos.yahoo.com/carfinder/ |
| Free forum by Nabble | Edit this page |
