do repeat...

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

do repeat...

Hans-Christian Stahl-3
Hi,

I have cases identified by unique visit ids. For each patient I can calculate the day of visit since registration (visit_day). During their visits patients were asked about their Quality of Life (QOL). I want to do a longitudinal analysis from visit day 0 to day 75 for each patient, starting from my original table where cases are identified by visit ids. Patients where asked about their QOL at different visit days. Therefore I want to compute variables:

if (visit_day = 0) quality_of_life_score_at_day_0 (QOL_0) = quality_of_life_score_of_the_visit (QOL).
if (visit_day = 1) quality_of_life_score_at_day_1 (QOL_1) = quality_of_life_score_of_the_visit (QOL).
etc. until
if (visit_day = 75) quality_of_life_score_at_day_1 (QOL_75) = quality_of_life_score_of_the_visit (QOL).

Subsequently I want to use the aggregate function /break by pid to have the time series by patient ID (pid).

How can I compute the 75 "if procedures" in a "do repeat - end repeat" slope or something equal? Any more elegant way to do this?

Thank you for any help in advance!

Christian

=====================
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: do repeat...

John F Hall
Christian
 
If I understand what you are trying to do, something like (untested, but PASW 18 doesn't display any errors in the syntax)
 
do repeat .
x = visit_day0 to visit_day75 .
y = 0 to 75 .
z = qol0 to qol75 .
if (x = y) z = <where does it get the score from?> .
end repeat .
 
It's not clear which variable has the QoL score for the day of visit.
 
I did something recently on total incidents by day of season (football analogy) and used syntax:
 
TSPLOT VARIABLES= <var>
  /ID=Month
  /NOLOG.
 
. . . so you need something like:
 
TSPLOT VARIABLES= <QoL score for visit day>
  /ID= <visit day>  /NOLOG.
 
Jon Peck, Bruce Weaver, Art Kendal, or one of the other regulars will give you something more appropriate.
 
John Hall
 
----- Original Message -----
Sent: Friday, August 06, 2010 1:03 PM
Subject: do repeat...

Hi,

I have cases identified by unique visit ids. For each patient I can calculate the day of visit since registration (visit_day). During their visits patients were asked about their Quality of Life (QOL). I want to do a longitudinal analysis from visit day 0 to day 75 for each patient, starting from my original table where cases are identified by visit ids. Patients where asked about their QOL at different visit days. Therefore I want to compute variables:

if (visit_day = 0) quality_of_life_score_at_day_0 (QOL_0) = quality_of_life_score_of_the_visit (QOL).
if (visit_day = 1) quality_of_life_score_at_day_1 (QOL_1) = quality_of_life_score_of_the_visit (QOL).
etc. until
if (visit_day = 75) quality_of_life_score_at_day_1 (QOL_75) = quality_of_life_score_of_the_visit (QOL).

Subsequently I want to use the aggregate function /break by pid to have the time series by patient ID (pid).

How can I compute the 75 "if procedures" in a "do repeat - end repeat" slope or something equal? Any more elegant way to do this?

Thank you for any help in advance!

Christian

=====================
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: do repeat...

Maguin, Eugene
In reply to this post by Hans-Christian Stahl-3
Christian,

How are your data organized? Does each person-visit get its own record (long
format) or are all visits by one person on the same record (wide format)?

I saw John Hall's posting and if your data are in a wide format, his code
seems fine. If your data are in a long format, you need different syntax.

If your data are long format, it would be helpful to post a sample, made-up
or real.

Gene Maguin


-----Original Message-----
From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of
Hans-Christian Stahl
Sent: Friday, August 06, 2010 7:04 AM
To: [hidden email]
Subject: do repeat...

Hi,

I have cases identified by unique visit ids. For each patient I can
calculate the day of visit since registration (visit_day). During their
visits patients were asked about their Quality of Life (QOL). I want to do a
longitudinal analysis from visit day 0 to day 75 for each patient, starting
from my original table where cases are identified by visit ids. Patients
where asked about their QOL at different visit days. Therefore I want to
compute variables:

if (visit_day = 0) quality_of_life_score_at_day_0 (QOL_0) =
quality_of_life_score_of_the_visit (QOL).
if (visit_day = 1) quality_of_life_score_at_day_1 (QOL_1) =
quality_of_life_score_of_the_visit (QOL).
etc. until
if (visit_day = 75) quality_of_life_score_at_day_1 (QOL_75) =
quality_of_life_score_of_the_visit (QOL).

Subsequently I want to use the aggregate function /break by pid to have the
time series by patient ID (pid).

How can I compute the 75 "if procedures" in a "do repeat - end repeat" slope
or something equal? Any more elegant way to do this?

Thank you for any help in advance!

Christian

=====================
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: do repeat...

Bruce Weaver
Administrator
In reply to this post by Hans-Christian Stahl-3
Hans-Christian Stahl-3 wrote
Hi,

I have cases identified by unique visit ids. For each patient I can calculate the day of visit since registration (visit_day). During their visits patients were asked about their Quality of Life (QOL). I want to do a longitudinal analysis from visit day 0 to day 75 for each patient, starting from my original table where cases are identified by visit ids. Patients where asked about their QOL at different visit days. Therefore I want to compute variables:

if (visit_day = 0) quality_of_life_score_at_day_0 (QOL_0) = quality_of_life_score_of_the_visit (QOL).
if (visit_day = 1) quality_of_life_score_at_day_1 (QOL_1) = quality_of_life_score_of_the_visit (QOL).
etc. until
if (visit_day = 75) quality_of_life_score_at_day_1 (QOL_75) = quality_of_life_score_of_the_visit (QOL).

Subsequently I want to use the aggregate function /break by pid to have the time series by patient ID (pid).

How can I compute the 75 "if procedures" in a "do repeat - end repeat" slope or something equal? Any more elegant way to do this?

Thank you for any help in advance!

Christian
This is a wild stab in the dark, but do you mean that you want to convert this:

ID  DAY  QOL
1   0      QOL on day 0
1   1      QOL on day 1
etc.
1  75     QOL on day 75
2   0      QOL on day 0
2   1      QOL on day 1
etc.
2  75     QOL on day 75
etc

to this:

ID QOL0  QOL1  QOL2 ...  QOL75
1
2
3
etc

If so, take a look at CASESTOVARS in the Help files.  You can find examples there, and also on the UCLA Computing website--search on "UCLA SPSS data management", or something along those lines.

--
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: do repeat...

Hans-Christian Stahl-3
In reply to this post by John F Hall

Thank you John!

 

I have something like:

 

Visitid   PID  Visit_day QoL_Score

89        7    0         80

122       7    7         90

145       7    14        92

76        10   0         76

89        10   6         78

101       10   9         82

 

I need:

 

PID       QoL0  QoL1 etc… QoL6 QoL7 etc… QoL9 etc… QoL14

7         80   mis.      mis. 90        mis.      92

10        76   mis.      78   mis.      82        mis.

 

Am I right to correct your syntax according to:

 

Do repeat

Y = 0 to 75.

Z = qol0 to qol75.

If (visit_day=Y) Z=qol_score.

End repeat.

 

I will give it a try. Else I will look up what Bruce posted. Thank you very much!

 

Christian

 

From: John F Hall [mailto:[hidden email]]
Sent: Freitag, 6. August 2010 14:56
To: Hans-Christian Stahl; [hidden email]
Subject: Re: do repeat...

 

Christian

 

If I understand what you are trying to do, something like (untested, but PASW 18 doesn't display any errors in the syntax)

 

do repeat .

x = visit_day0 to visit_day75 .

y = 0 to 75 .

z = qol0 to qol75 .

if (x = y) z = <where does it get the score from?> .

end repeat .

 

It's not clear which variable has the QoL score for the day of visit.

 

I did something recently on total incidents by day of season (football analogy) and used syntax:

 

TSPLOT VARIABLES= <var>

  /ID=Month
  /NOLOG.

 

. . . so you need something like:

 

TSPLOT VARIABLES= <QoL score for visit day>

  /ID= <visit day>  /NOLOG.

 

Jon Peck, Bruce Weaver, Art Kendal, or one of the other regulars will give you something more appropriate.

 

John Hall

 

----- Original Message -----

Sent: Friday, August 06, 2010 1:03 PM

Subject: do repeat...

 

Hi,

I have cases identified by unique visit ids. For each patient I can calculate the day of visit since registration (visit_day). During their visits patients were asked about their Quality of Life (QOL). I want to do a longitudinal analysis from visit day 0 to day 75 for each patient, starting from my original table where cases are identified by visit ids. Patients where asked about their QOL at different visit days. Therefore I want to compute variables:

if (visit_day = 0) quality_of_life_score_at_day_0 (QOL_0) = quality_of_life_score_of_the_visit (QOL).
if (visit_day = 1) quality_of_life_score_at_day_1 (QOL_1) = quality_of_life_score_of_the_visit (QOL).
etc. until
if (visit_day = 75) quality_of_life_score_at_day_1 (QOL_75) = quality_of_life_score_of_the_visit (QOL).

Subsequently I want to use the aggregate function /break by pid to have the time series by patient ID (pid).

How can I compute the 75 "if procedures" in a "do repeat - end repeat" slope or something equal? Any more elegant way to do this?

Thank you for any help in advance!

Christian

=====================
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: do repeat...

David Marso
Administrator
In reply to this post by Hans-Christian Stahl-3
Hi Christian,
First of all John's syntax is incorrectly specified.
You would need to remove the periods and put / between the clauses.
(OTOH, you DON'T need a DO REPEAT in the first place).
I would solve this as follows .
-----
NUMERIC QoL0 TO QoL75.
VECTOR QoL= QoL0 TO QoL75.
COMPUTE QoL(Visit_day+1)=QoL_Score.
AGGREGATE OUTFILE */ BREAK PID / QoL0 TO QoL75=MAX(QoL0 TO QoL75).
HTH, David

On Fri, 6 Aug 2010 15:19:36 +0200, Hans-Christian Stahl
<[hidden email]> wrote:

>Thank you John!
>
>
>
>I have something like:
>
>
>
>Visitid   PID  Visit_day QoL_Score
>
>89        7    0         80
>
>122       7    7         90
>
>145       7    14        92
>
>76        10   0         76
>
>89        10   6         78
>
>101       10   9         82
>
>
>
>I need:
>
>
>
>PID       QoL0  QoL1 etc. QoL6 QoL7 etc. QoL9 etc. QoL14
>
>7         80   mis.      mis. 90        mis.      92
>
>10        76   mis.      78   mis.      82        mis.
>
>
>
>Am I right to correct your syntax according to:
>
>
>
>Do repeat
>
>Y = 0 to 75.
>
>Z = qol0 to qol75.
>
>If (visit_day=Y) Z=qol_score.
>
>End repeat.
>
>
>
>I will give it a try. Else I will look up what Bruce posted. Thank you very
>much!
>
>
>
>Christian
>
>
>
>From: John F Hall [mailto:[hidden email]]
>Sent: Freitag, 6. August 2010 14:56
>To: Hans-Christian Stahl; [hidden email]
>Subject: Re: do repeat...
>
>
>
>Christian
>
>
>
>If I understand what you are trying to do, something like (untested, but
>PASW 18 doesn't display any errors in the syntax)
>
>
>
>do repeat .
>
>x = visit_day0 to visit_day75 .
>
>y = 0 to 75 .
>
>z = qol0 to qol75 .
>
>if (x = y) z = <where does it get the score from?> .
>
>end repeat .
>
>
>
>It's not clear which variable has the QoL score for the day of visit.
>
>
>
>I did something recently on total incidents by day of season (football
>analogy) and used syntax:
>
>
>
>TSPLOT VARIABLES= <var>
>
>  /ID=Month
>  /NOLOG.
>
>
>
>. . . so you need something like:
>
>
>
>TSPLOT VARIABLES= <QoL score for visit day>
>
>  /ID= <visit day>  /NOLOG.
>
>
>
>Jon Peck, Bruce Weaver, Art Kendal, or one of the other regulars will give
>you something more appropriate.
>
>
>
>John Hall
>
>
>
>----- Original Message -----
>
>From:  <mailto:[hidden email]> Hans-Christian Stahl
>
>To:  <mailto:[hidden email]> [hidden email]
>
>Sent: Friday, August 06, 2010 1:03 PM
>
>Subject: do repeat...
>
>
>
>Hi,
>
>I have cases identified by unique visit ids. For each patient I can
>calculate the day of visit since registration (visit_day). During their
>visits patients were asked about their Quality of Life (QOL). I want to do a
>longitudinal analysis from visit day 0 to day 75 for each patient, starting
>from my original table where cases are identified by visit ids. Patients
>where asked about their QOL at different visit days. Therefore I want to
>compute variables:
>
>if (visit_day = 0) quality_of_life_score_at_day_0 (QOL_0) =
>quality_of_life_score_of_the_visit (QOL).
>if (visit_day = 1) quality_of_life_score_at_day_1 (QOL_1) =
>quality_of_life_score_of_the_visit (QOL).
>etc. until
>if (visit_day = 75) quality_of_life_score_at_day_1 (QOL_75) =
>quality_of_life_score_of_the_visit (QOL).
>
>Subsequently I want to use the aggregate function /break by pid to have the
>time series by patient ID (pid).
>
>How can I compute the 75 "if procedures" in a "do repeat - end repeat" slope
>or something equal? Any more elegant way to do this?
>
>Thank you for any help in advance!
>
>Christian
>
>=====================
>To manage your subscription to SPSSX-L, send a message to
> <mailto:[hidden email]> [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
Please reply to the list and not to my personal email.
Those desiring my consulting or training services please feel free to email me.
---
"Nolite dare sanctum canibus neque mittatis margaritas vestras ante porcos ne forte conculcent eas pedibus suis."
Cum es damnatorum possederunt porcos iens ut salire off sanguinum cliff in abyssum?"
Reply | Threaded
Open this post in threaded view
|

Re: do repeat...

Ruben Geert van den Berg
Hi David,

I think you could even write 

VECTOR QoL(75).

instead of 

NUMERIC QoL0 TO QoL75.
VECTOR QoL= QoL0 TO QoL75.

Best,

Ruben van den Berg
Consultant Models & Methods
TNS NIPO
Email: [hidden email]
Mobiel: +31 6 24641435
Telefoon: +31 20 522 5738
Internet: www.tns-nipo.com




> Date: Sat, 7 Aug 2010 13:46:50 -0400
> From: [hidden email]
> Subject: Re: do repeat...
> To: [hidden email]
>
> Hi Christian,
> First of all John's syntax is incorrectly specified.
> You would need to remove the periods and put / between the clauses.
> (OTOH, you DON'T need a DO REPEAT in the first place).
> I would solve this as follows .
> -----
> NUMERIC QoL0 TO QoL75.
> VECTOR QoL= QoL0 TO QoL75.
> COMPUTE QoL(Visit_day+1)=QoL_Score.
> AGGREGATE OUTFILE */ BREAK PID / QoL0 TO QoL75=MAX(QoL0 TO QoL75).
> HTH, David
>
> On Fri, 6 Aug 2010 15:19:36 +0200, Hans-Christian Stahl
> <[hidden email]> wrote:
>
> >Thank you John!
> >
> >
> >
> >I have something like:
> >
> >
> >
> >Visitid PID Visit_day QoL_Score
> >
> >89 7 0 80
> >
> >122 7 7 90
> >
> >145 7 14 92
> >
> >76 10 0 76
> >
> >89 10 6 78
> >
> >101 10 9 82
> >
> >
> >
> >I need:
> >
> >
> >
> >PID QoL0 QoL1 etc. QoL6 QoL7 etc. QoL9 etc. QoL14
> >
> >7 80 mis. mis. 90 mis. 92
> >
> >10 76 mis. 78 mis. 82 mis.
> >
> >
> >
> >Am I right to correct your syntax according to:
> >
> >
> >
> >Do repeat
> >
> >Y = 0 to 75.
> >
> >Z = qol0 to qol75.
> >
> >If (visit_day=Y) Z=qol_score.
> >
> >End repeat.
> >
> >
> >
> >I will give it a try. Else I will look up what Bruce posted. Thank you very
> >much!
> >
> >
> >
> >Christian
> >
> >
> >
> >From: John F Hall [mailto:[hidden email]]
> >Sent: Freitag, 6. August 2010 14:56
> >To: Hans-Christian Stahl; [hidden email]
> >Subject: Re: do repeat...
> >
> >
> >
> >Christian
> >
> >
> >
> >If I understand what you are trying to do, something like (untested, but
> >PASW 18 doesn't display any errors in the syntax)
> >
> >
> >
> >do repeat .
> >
> >x = visit_day0 to visit_day75 .
> >
> >y = 0 to 75 .
> >
> >z = qol0 to qol75 .
> >
> >if (x = y) z = <where does it get the score from?> .
> >
> >end repeat .
> >
> >
> >
> >It's not clear which variable has the QoL score for the day of visit.
> >
> >
> >
> >I did something recently on total incidents by day of season (football
> >analogy) and used syntax:
> >
> >
> >
> >TSPLOT VARIABLES= <var>
> >
> > /ID=Month
> > /NOLOG.
> >
> >
> >
> >. . . so you need something like:
> >
> >
> >
> >TSPLOT VARIABLES= <QoL score for visit day>
> >
> > /ID= <visit day> /NOLOG.
> >
> >
> >
> >Jon Peck, Bruce Weaver, Art Kendal, or one of the other regulars will give
> >you something more appropriate.
> >
> >
> >
> >John Hall
> >
> >
> >
> >----- Original Message -----
> >
> >From: <mailto:[hidden email]> Hans-Christian Stahl
> >
> >To: <mailto:[hidden email]> [hidden email]
> >
> >Sent: Friday, August 06, 2010 1:03 PM
> >
> >Subject: do repeat...
> >
> >
> >
> >Hi,
> >
> >I have cases identified by unique visit ids. For each patient I can
> >calculate the day of visit since registration (visit_day). During their
> >visits patients were asked about their Quality of Life (QOL). I want to do a
> >longitudinal analysis from visit day 0 to day 75 for each patient, starting
> >from my original table where cases are identified by visit ids. Patients
> >where asked about their QOL at different visit days. Therefore I want to
> >compute variables:
> >
> >if (visit_day = 0) quality_of_life_score_at_day_0 (QOL_0) =
> >quality_of_life_score_of_the_visit (QOL).
> >if (visit_day = 1) quality_of_life_score_at_day_1 (QOL_1) =
> >quality_of_life_score_of_the_visit (QOL).
> >etc. until
> >if (visit_day = 75) quality_of_life_score_at_day_1 (QOL_75) =
> >quality_of_life_score_of_the_visit (QOL).
> >
> >Subsequently I want to use the aggregate function /break by pid to have the
> >time series by patient ID (pid).
> >
> >How can I compute the 75 "if procedures" in a "do repeat - end repeat" slope
> >or something equal? Any more elegant way to do this?
> >
> >Thank you for any help in advance!
> >
> >Christian
> >
> >=====================
> >To manage your subscription to SPSSX-L, send a message to
> > <mailto:[hidden email]> [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: do repeat...

David Marso
Administrator
In reply to this post by Hans-Christian Stahl-3
Hi Ruben,
In general True,  my declaration using NUMERIC is just to get the first
variable name to end with 0.  The plain VECTOR will begin with QoL1.
One could probably rig the whole thing with CASESTOVARS.
David

On Sun, 8 Aug 2010 05:02:35 +0000, Ruben van den Berg
<[hidden email]> wrote:

>
>Hi David,
>I think you could even write
>VECTOR QoL(75).
>instead of
>NUMERIC QoL0 TO QoL75.VECTOR QoL= QoL0 TO QoL75.
>Best,
>
>Ruben van den Berg
>Consultant Models & Methods
>TNS NIPO
>Email: [hidden email]
>Mobiel: +31 6 24641435
>Telefoon: +31 20 522 5738
>Internet: www.tns-nipo.com
>
>
>
>
>> Date: Sat, 7 Aug 2010 13:46:50 -0400
>> From: [hidden email]
>> Subject: Re: do repeat...
>> To: [hidden email]
>>
>> Hi Christian,
>> First of all John's syntax is incorrectly specified.
>> You would need to remove the periods and put / between the clauses.
>> (OTOH, you DON'T need a DO REPEAT in the first place).
>> I would solve this as follows .
>> -----
>> NUMERIC QoL0 TO QoL75.
>> VECTOR QoL= QoL0 TO QoL75.
>> COMPUTE QoL(Visit_day+1)=QoL_Score.
>> AGGREGATE OUTFILE */ BREAK PID / QoL0 TO QoL75=MAX(QoL0 TO QoL75).
>> HTH, David
>>
>> On Fri, 6 Aug 2010 15:19:36 +0200, Hans-Christian Stahl
>> <[hidden email]> wrote:
>>
>> >Thank you John!
>> >
>> >
>> >
>> >I have something like:
>> >
>> >
>> >
>> >Visitid   PID  Visit_day QoL_Score
>> >
>> >89        7    0         80
>> >
>> >122       7    7         90
>> >
>> >145       7    14        92
>> >
>> >76        10   0         76
>> >
>> >89        10   6         78
>> >
>> >101       10   9         82
>> >
>> >
>> >
>> >I need:
>> >
>> >
>> >
>> >PID       QoL0  QoL1 etc. QoL6 QoL7 etc. QoL9 etc. QoL14
>> >
>> >7         80   mis.      mis. 90        mis.      92
>> >
>> >10        76   mis.      78   mis.      82        mis.
>> >
>> >
>> >
>> >Am I right to correct your syntax according to:
>> >
>> >
>> >
>> >Do repeat
>> >
>> >Y = 0 to 75.
>> >
>> >Z = qol0 to qol75.
>> >
>> >If (visit_day=Y) Z=qol_score.
>> >
>> >End repeat.
>> >
>> >
>> >
>> >I will give it a try. Else I will look up what Bruce posted. Thank you very
>> >much!
>> >
>> >
>> >
>> >Christian
>> >
>> >
>> >
>> >From: John F Hall [mailto:[hidden email]]
>> >Sent: Freitag, 6. August 2010 14:56
>> >To: Hans-Christian Stahl; [hidden email]
>> >Subject: Re: do repeat...
>> >
>> >
>> >
>> >Christian
>> >
>> >
>> >
>> >If I understand what you are trying to do, something like (untested, but
>> >PASW 18 doesn't display any errors in the syntax)
>> >
>> >
>> >
>> >do repeat .
>> >
>> >x = visit_day0 to visit_day75 .
>> >
>> >y = 0 to 75 .
>> >
>> >z = qol0 to qol75 .
>> >
>> >if (x = y) z = <where does it get the score from?> .
>> >
>> >end repeat .
>> >
>> >
>> >
>> >It's not clear which variable has the QoL score for the day of visit.
>> >
>> >
>> >
>> >I did something recently on total incidents by day of season (football
>> >analogy) and used syntax:
>> >
>> >
>> >
>> >TSPLOT VARIABLES= <var>
>> >
>> >  /ID=Month
>> >  /NOLOG.
>> >
>> >
>> >
>> >. . . so you need something like:
>> >
>> >
>> >
>> >TSPLOT VARIABLES= <QoL score for visit day>
>> >
>> >  /ID= <visit day>  /NOLOG.
>> >
>> >
>> >
>> >Jon Peck, Bruce Weaver, Art Kendal, or one of the other regulars will give
>> >you something more appropriate.
>> >
>> >
>> >
>> >John Hall
>> >
>> >
>> >
>> >----- Original Message -----
>> >
>> >From:  <mailto:[hidden email]> Hans-Christian Stahl
>> >
>> >To:  <mailto:[hidden email]> [hidden email]
>> >
>> >Sent: Friday, August 06, 2010 1:03 PM
>> >
>> >Subject: do repeat...
>> >
>> >
>> >
>> >Hi,
>> >
>> >I have cases identified by unique visit ids. For each patient I can
>> >calculate the day of visit since registration (visit_day). During their
>> >visits patients were asked about their Quality of Life (QOL). I want to do a
>> >longitudinal analysis from visit day 0 to day 75 for each patient, starting
>> >from my original table where cases are identified by visit ids. Patients
>> >where asked about their QOL at different visit days. Therefore I want to
>> >compute variables:
>> >
>> >if (visit_day = 0) quality_of_life_score_at_day_0 (QOL_0) =
>> >quality_of_life_score_of_the_visit (QOL).
>> >if (visit_day = 1) quality_of_life_score_at_day_1 (QOL_1) =
>> >quality_of_life_score_of_the_visit (QOL).
>> >etc. until
>> >if (visit_day = 75) quality_of_life_score_at_day_1 (QOL_75) =
>> >quality_of_life_score_of_the_visit (QOL).
>> >
>> >Subsequently I want to use the aggregate function /break by pid to have the
>> >time series by patient ID (pid).
>> >
>> >How can I compute the 75 "if procedures" in a "do repeat - end repeat" slope
>> >or something equal? Any more elegant way to do this?
>> >
>> >Thank you for any help in advance!
>> >
>> >Christian
>> >
>> >=====================
>> >To manage your subscription to SPSSX-L, send a message to
>> > <mailto:[hidden email]> [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
>

=====================
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
Please reply to the list and not to my personal email.
Those desiring my consulting or training services please feel free to email me.
---
"Nolite dare sanctum canibus neque mittatis margaritas vestras ante porcos ne forte conculcent eas pedibus suis."
Cum es damnatorum possederunt porcos iens ut salire off sanguinum cliff in abyssum?"