Date: Wed, 15 Oct 2008 15:32:41 -0600
Reply-To: Ken Barz <Ken.Barz@CPCMED.ORG>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: Ken Barz <Ken.Barz@CPCMED.ORG>
Subject: Re: Proc Plan (?) Question
In-Reply-To: A<ce1fb7450810151423q6a0ac493lca4848020731cf20@mail.gmail.com>
Content-Type: text/plain; charset="us-ascii"
Basically, for each user a measurement will be made for each combination
of grade (as in vertical incline in degrees) and position (front,
middle, back.) So the order of grade and position needs to be permuted
for each user making the measurements in random order.
-----Original Message-----
From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On Behalf Of ./
ADD NAME=Data _null_,
Sent: Wednesday, October 15, 2008 3:24 PM
To: SAS-L@LISTSERV.UGA.EDU
Subject: Re: Proc Plan (?) Question
I don't follow your description of the desired result. Here is the
data for USER=1
What do you want to happen to the values of GRADE?
data user1;
input
Obs grade user position;
cards;
1 0 1 1
2 0 1 2
3 0 1 3
4 1 1 1
5 1 1 2
6 1 1 3
7 5 1 1
8 5 1 2
9 5 1 3
10 6 1 1
11 6 1 2
12 6 1 3
13 7 1 1
14 7 1 2
15 7 1 3
16 12 1 1
17 12 1 2
18 12 1 3
19 14 1 1
20 14 1 2
21 14 1 3
22 17 1 1
23 17 1 2
24 17 1 3
25 18 1 1
26 18 1 2
27 18 1 3
;;;;
run;
On 10/15/08, Ken Barz <Ken.Barz@cpcmed.org> wrote:
> I'm assuming proc plan is right for this. I just haven't found the
> right syntax in the documentation yet. Basically what I want to do is
> permute the values of grade (after taking a random sample) and
position
> using user as a block. Here's the code so far:
>
> Thanks
>
>
>
> data allgrades;
>
> do grade = 0 to 18;
>
> output;
>
> end;
>
> run;
>
>
>
> proc surveyselect data=allgrades method=srs n=9 out=grades;
>
> run;
>
>
>
> data users;
>
> do user = 1 to 6;
>
> do position = 1 to 3;
>
> output;
>
> end;
>
> end;
>
> run;
>
>
>
> proc sql;
>
> create table combine as
>
> select a.*, b.*
>
> from grades a, users b
>
> order by b.user, a.grade, b.position ;
>
> quit;
>
>
>
> proc plan?
>