pspp-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Create new variables from others (If Condistional or recode)


From: John Darrington
Subject: Re: Create new variables from others (If Condistional or recode)
Date: Mon, 23 Oct 2017 19:00:17 +0200
User-agent: Mutt/1.5.23 (2014-03-12)

In PSPP, the simplest way to create a new variable, and assign values
to it derived from existing variables is using the COMPUTE command.
For example if you have existing variables v1, v2 and v3, you could
create a new variable as follows:

compute newVar = v1 or v2 or v3.

(don't forget the . at the end)

J'

On Mon, Oct 23, 2017 at 01:12:03PM -0300, Betsab?? Cohen wrote:
     Hi everyone:
     I'm a recent user of PSPP and i'm trying to create a new variable from
     three other variables using a conditional. In Excel i would use IF and OR
     functions but i don't know what should i used in pspp sintaxys:
     
     The idea is to create a new variable as follows:
     
     
     NEW Variable "Condicion_Actividad"
     Existing variables
     Cod.1= Var5=1 or Var6=1 or Var7=1
     Cod.2= Var8=1
     Cod.3= Var8=2
     
     Thanks in advance.
     
     Betsy
     
     
-- 
Avoid eavesdropping.  Send strong encrypted email.
PGP Public key ID: 1024D/2DE827B3 
fingerprint = 8797 A26D 0854 2EAB 0285  A290 8A67 719C 2DE8 27B3
See http://sks-keyservers.net or any PGP keyserver for public key.

Attachment: signature.asc
Description: Digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]