Reading Syntax

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Reading Syntax

DAJudge
Dear Users,

I am having trouble loading a saved syntax file into active data. I usually work with STATA, but am collaborating with a humanities colleague who does not have a statistical background. We are currently using SPSS 22, and created a script file (.wwd) to monitor changes to a data file that includes string and numeric variables. However, every time I try to execute the script commands onto the original data I receive the following message:

Error: Expecting an existing scalar var.
At Line No: 6.

Any suggestion on how to proceed would be greatly appreciated.

Thank you,

David
Reply | Threaded
Open this post in threaded view
|

Re: Reading Syntax

Bruce Weaver
Administrator
What exactly does the script do?  And more specifically, what does it do on line 6?  (It may be that there is a less complicated way to do what you want to do using ordinary syntax rather than a script.)  

If it is not too terribly long, you could just post the script here.  (IIRC, .wwd files are just text, so you should be able to open it with Notepad or any text editor, copy and paste into the body of your post.)  

HTH.


DAJudge wrote
Dear Users,

I am having trouble loading a saved syntax file into active data. I usually work with STATA, but am collaborating with a humanities colleague who does not have a statistical background. We are currently using SPSS 22, and created a script file (.wwd) to monitor changes to a data file that includes string and numeric variables. However, every time I try to execute the script commands onto the original data I receive the following message:

Error: Expecting an existing scalar var.
At Line No: 6.

Any suggestion on how to proceed would be greatly appreciated.

Thank you,

David
--
Bruce Weaver
bweaver@lakeheadu.ca
http://sites.google.com/a/lakeheadu.ca/bweaver/

"When all else fails, RTFM."

PLEASE NOTE THE FOLLOWING: 
1. My Hotmail account is not monitored regularly. To send me an e-mail, please use the address shown above.
2. The SPSSX Discussion forum on Nabble is no longer linked to the SPSSX-L listserv administered by UGA (https://listserv.uga.edu/).
Reply | Threaded
Open this post in threaded view
|

Re: Reading Syntax

Jon K Peck
In reply to this post by DAJudge
In case you haven't solved this...

This is an error in the VB script.  It could perhaps come from an undeclared variable with Option Explicit set, which means that all variables must be declared before use, but more likely it is just an invalid variable reference.

Although Basic scripting is still supported, these days people are  more likely to use the Python scripting option.  I would have to see the details to make any suggestions toward a solution with either Basic or Python.


Jon Peck (no "h") aka Kim
Senior Software Engineer, IBM
[hidden email]
phone: 720-342-5621




From:        DAJudge <[hidden email]>
To:        [hidden email]
Date:        11/09/2015 10:13 AM
Subject:        [SPSSX-L] Reading Syntax
Sent by:        "SPSSX(r) Discussion" <[hidden email]>




Dear Users,

I am having trouble loading a saved syntax file into active data. I usually
work with STATA, but am collaborating with a humanities colleague who does
not have a statistical background. We are currently using SPSS 22, and
created a script file (.wwd) to monitor changes to a data file that includes
string and numeric variables. However, every time I try to execute the
script commands onto the original data I receive the following message:

Error: Expecting an existing scalar var.
At Line No: 6.

Any suggestion on how to proceed would be greatly appreciated.

Thank you,

David



--
View this message in context:
http://spssx-discussion.1045642.n5.nabble.com/Reading-Syntax-tp5730911.html
Sent from the SPSSX Discussion mailing list archive at Nabble.com.

=====================
To manage your subscription to SPSSX-L, send a message to
[hidden email] (not to SPSSX-L), with no body text except the
command. To leave the list, send the command
SIGNOFF SPSSX-L
For a list of commands to manage subscriptions, send the command
INFO REFCARD



===================== To manage your subscription to SPSSX-L, send a message to [hidden email] (not to SPSSX-L), with no body text except the command. To leave the list, send the command SIGNOFF SPSSX-L For a list of commands to manage subscriptions, send the command INFO REFCARD
Reply | Threaded
Open this post in threaded view
|

Re: Reading Syntax

DAJudge
In reply to this post by DAJudge

Thank you for your insight. I believe I have solved it, and the error was on my end. I was trying to save the command sequence as basic script, but when I tried again saving the sequence using syntax it worked without a problem.


 

David Abeling-Judge

Instructor

School of Criminology and Criminal Justice

Northeastern University


Managing Editor

Crime, Law, and Social Change




From: Jon K Peck <[hidden email]>
Sent: Tuesday, November 10, 2015 10:22 AM
To: Abeling-Judge, David
Cc: [hidden email]
Subject: Re: [SPSSX-L] Reading Syntax
 
In case you haven't solved this...

This is an error in the VB script.  It could perhaps come from an undeclared variable with Option Explicit set, which means that all variables must be declared before use, but more likely it is just an invalid variable reference.

Although Basic scripting is still supported, these days people are  more likely to use the Python scripting option.  I would have to see the details to make any suggestions toward a solution with either Basic or Python.


Jon Peck (no "h") aka Kim
Senior Software Engineer, IBM
[hidden email]
phone: 720-342-5621<img title="Call: 720-342-5621" style="margin: 0px; border: currentColor; left: 0px; top: 0px; width: 16px; height: 16px; right: 0px; bottom: 0px; overflow: hidden; vertical-align: middle; float: none; display: inline; white-space: nowrap; position: static !important;" src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAACXBIWXMAAA7EAAAOxAGVKw4bAAAAIGNIUk0AAHolAACAgwAA&#43;f8AAIDpAAB1MAAA6mAAADqYAAAXb5JfxUYAAAKLSURBVHjadJPfS5NhFMe/21xvuhXRyJAZroiSrJnbRdT7vrAf5HBaK5RABmEEwQIvkpZ/QRcWXdSFw5soKaF0F7qZeLO13mGBDpQsf5CoxVKHOt0Pctp2uvEdrzG/V&#43;c553w/54HnPDIiQiGpPMETABoB2AAYd9MRAMMAvGmX&#43;RcAyAoBVJ7gZQDtABworH4AHWmX&#43;bOMZdkjCoXiUzabvcAwzPSsob5p/VTNY9GcdpnxdmYZ9wJThSCtCr1e/4XjuNPd3d1KjUZzaGbI27ysqzGQoggAsLa1A7ehArrDxfDNr0oBlQB&#43;wmKxbJFEL968SxoamsjkHaPU9l9piUo6A0RE1DG2QCWdASrpDAzJM5kMI8XecdjVxfEl&#43;K9dxFgsgUvvR6HyBKHyBAEATyKLeGSsENuNcqk5kUjEGm7fzcYqr0ClVODl99&#43;YXEvl6&#43;c1amjVe&#43;ahiGGYaUEQKnmeh91uL43rqheixjpdmzCL11er0PcjhrTLvMfUJsyKYUSeyWQ6enp6tgCgrKxsfbP8bB8AdE1G89cOReMAgOv&#43;Cag8QXRNRkXAsDwcDr&#43;am5tLCYKA3t7eo2dG&#43;1vVK/MfpRPtA&#43;MIReMYaKj&#43;/xm9MiICx3EmpVL5wefzFavValis1u1vvHMkdfykCQC0kSGUTo&#43;Ajmnx1dSC7IGD&#43;UUCEYGIwLKsyWazrSeTSSIiMpnNf7Ttz5&#43;ec96fr7/VnE0mk&#43;QfHMzV3WjcKH/4rEr05QGFIA6HY4llWRLPRER&#43;v3/HYrFMFQSIkNra2tVQKJSlfcSyLO0LECFWq3XF6XRGA4HAptTsdrsXeZ6fEHtl&#43;31nAOA4rkUulz/I5XL63dQGgHEAN8Ph8AYA/BsAt4ube4GblQIAAAAASUVORK5CYII=">




From:        DAJudge <[hidden email]>
To:        [hidden email]
Date:        11/09/2015 10:13 AM
Subject:        [SPSSX-L] Reading Syntax
Sent by:        "SPSSX(r) Discussion" <[hidden email]>




Dear Users,

I am having trouble loading a saved syntax file into active data. I usually
work with STATA, but am collaborating with a humanities colleague who does
not have a statistical background. We are currently using SPSS 22, and
created a script file (.wwd) to monitor changes to a data file that includes
string and numeric variables. However, every time I try to execute the
script commands onto the original data I receive the following message:

Error: Expecting an existing scalar var.
At Line No: 6.

Any suggestion on how to proceed would be greatly appreciated.

Thank you,

David



--
View this message in context:
http://spssx-discussion.1045642.n5.nabble.com/Reading-Syntax-tp5730911.html
Sent from the SPSSX Discussion mailing list archive at Nabble.com.

=====================
To manage your subscription to SPSSX-L, send a message to
[hidden email] (not to SPSSX-L), with no body text except the
command. To leave the list, send the command
SIGNOFF SPSSX-L
For a list of commands to manage subscriptions, send the command
INFO REFCARD

SPSSX Discussion - Reading Syntax
Reading Syntax. Dear Users, I am having trouble loading a saved syntax file into active data. I usually work with STATA, but am collaborating with a humanities colleague who does not have a...




===================== To manage your subscription to SPSSX-L, send a message to [hidden email] (not to SPSSX-L), with no body text except the command. To leave the list, send the command SIGNOFF SPSSX-L For a list of commands to manage subscriptions, send the command INFO REFCARD