Is this EVEN possible?

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

Is this EVEN possible?

Juan Pablo Sandoval
HI:
 
I´ve been reviewing the SPSS syntax and I can´t find if this is possible...
 
What I want to do is:
 
compute test = any(var1,var2,var3,var4, var5,1).
 
So what I want to do is check if any of the variables var1 to var5 contains the value 1.
 
Whay is this not possible.
 
Regards,
Reply | Threaded
Open this post in threaded view
|

Re: Is this EVEN possible?

Hector Maletta

ANY is a conditional command, something like “IF any OF THESE VARIABLES EQUALS 1, THEN DO THE FOLLOWING”.

 

De: SPSSX(r) Discussion [mailto:[hidden email]] En nombre de Juan Pablo Sandoval
Enviado el: Tuesday, June 22, 2010 10:27 PM
Para: [hidden email]
Asunto: Is this EVEN possible?

 

HI:

 

I´ve been reviewing the SPSS syntax and I can´t find if this is possible...

 

What I want to do is:

 

compute test = any(var1,var2,var3,var4, var5,1).

 

So what I want to do is check if any of the variables var1 to var5 contains the value 1.

 

Whay is this not possible.

 

Regards,

Se certificó que el correo entrante no contiene virus.
Comprobada por AVG - www.avg.es
Versión: 8.5.439 / Base de datos de virus: 271.1.1/2951 - Fecha de la versión: 06/22/10 18:36:00

Reply | Threaded
Open this post in threaded view
|

Re: Is this EVEN possible?

Kylie
In reply to this post by Juan Pablo Sandoval

Hi Juan Pablo,

 

Put the test criterion as the first argument and it should do what you want:

 

COMPUTE test = ANY(1, var1, var2, var3, var4, var5)

 

Cheers,

Kylie.

 

 

From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of Juan Pablo Sandoval
Sent: Wednesday, 23 June 2010 10:57 AM
To: [hidden email]
Subject: Is this EVEN possible?

 

HI:

 

I´ve been reviewing the SPSS syntax and I can´t find if this is possible...

 

What I want to do is:

 

compute test = any(var1,var2,var3,var4, var5,1).

 

So what I want to do is check if any of the variables var1 to var5 contains the value 1.

 

Whay is this not possible.

 

Regards,