04-09-2024
vnreddy
Quartz | Level 8
Member since
11-27-2019
- 104 Posts
- 14 Likes Given
- 0 Solutions
- 2 Likes Received
-
Latest posts by vnreddy
Subject Views Posted 2770 04-07-2024 10:50 AM 2812 04-07-2024 09:14 AM 2813 04-07-2024 09:12 AM 2908 04-06-2024 11:01 PM 1554 03-06-2024 12:03 PM 1582 03-06-2024 11:31 AM 1612 03-06-2024 10:30 AM 1653 03-06-2024 09:42 AM 1495 02-14-2024 01:02 PM 1522 02-14-2024 12:49 PM -
Activity Feed for vnreddy
- Liked Re: Total and Average in Proc report for PaigeMiller. 04-07-2024 03:15 PM
- Posted Re: Total and Average in Proc report on ODS and Base Reporting. 04-07-2024 10:50 AM
- Posted Re: Total and Average in Proc report on ODS and Base Reporting. 04-07-2024 09:14 AM
- Posted Re: Total and Average in Proc report on ODS and Base Reporting. 04-07-2024 09:12 AM
- Posted Total and Average in Proc report on ODS and Base Reporting. 04-06-2024 11:01 PM
- Posted Re: Excel formula in SAS on SAS Programming. 03-06-2024 12:03 PM
- Posted Re: Excel formula in SAS on SAS Programming. 03-06-2024 11:31 AM
- Posted Re: Excel formula in SAS on SAS Programming. 03-06-2024 10:30 AM
- Posted Excel formula in SAS on SAS Programming. 03-06-2024 09:42 AM
- Posted Re: Proc SQL group by is not working on SAS Programming. 02-14-2024 01:02 PM
- Posted Proc SQL group by is not working on SAS Programming. 02-14-2024 12:49 PM
- Posted Re: Proc report how to eliminate zeros and Duplicate date values from reporting on ODS and Base Reporting. 02-08-2024 06:31 AM
- Posted Proc report how to eliminate zeros and Duplicate date values from reporting on ODS and Base Reporting. 02-07-2024 08:18 PM
- Liked Re: MTD % for Kurt_Bremser. 08-04-2023 11:25 AM
- Liked Re: MTD % for Quentin. 08-04-2023 11:25 AM
- Posted Re: MTD % on SAS Programming. 08-04-2023 10:30 AM
- Posted Re: MTD % on SAS Programming. 08-04-2023 09:53 AM
- Posted Re: MTD % on SAS Programming. 08-04-2023 09:20 AM
- Posted Re: MTD % on SAS Programming. 08-04-2023 09:01 AM
- Posted MTD % on SAS Programming. 08-04-2023 08:44 AM
-
Posts I Liked
Subject Likes Author Latest Post 1 1 1 1 1 -
My Liked Posts
Subject Likes Posted 1 08-10-2021 09:01 AM 1 08-04-2021 09:12 AM
07-11-2022
07:41 AM
Hi, Could someone help me with below :
data want;
input REGION $ NAME $ DATE :datetime20. DCODE $ TRAVEL;
format date datetime20.;
datalines;
EAST LEE 01JUN2022:00:00:00 AP64389 21.09
EAST LEE 03JUN2022:00:00:00 AP64389 15.19
EAST SAM 05JUN2022:00:00:00 PS1234 4.14
EAST LEE 07JUN2022:00:00:00 GP38299 2.09
WEST DAN 07JUN2022:00:00:00 CX78934 10.07
WEST DAN 07JUN2022:00:00:00 CX78934 8.07
WEST DAN 07JUN2022:00:00:00 PB53468 10.07
WEST DAN 07JUN2022:00:00:00 PB53468 10.07
SOUTH TIM 02JUN2022:00:00:00 SU18934 52.23
;
run;
Expected output :
I need to show the total count of codes based on the user level, from above NAME LEE has to AP64389 repeated two times so the count will be 2. and the tot_travel is total of AP64389 (21.09+15.19 = 36.28) and the avg_travel will be (36.28/2 = 18.14)
and the bottom of each name i need to show the total of count, tot_travel, and the avg_travel should be total of tot_travel/total of count i.e., 38.37/3 = 12.79
I need the report in same format, could someone help me how can i achive this.
... View more
07-05-2022
12:57 PM
Hi,
Could someone help me with any macros that i can use to schedule the report on 2nd working day of every month for UK
Thanks,
vnreddy
... View more
09-23-2021
09:37 AM
Hi,
Could someone help me how to set minimum and maximum values for a figure.
proc template;
define statgraph viz;
begingraph;
annotate;
layout lattice / columns=2 columnweights=(0.6 0.4);
layout overlay / yaxisopts=(label='Cumulative Proportion of Patients')
xaxisopts=(label="Change from Baseline in &endpointlabel.[1]" ) ;
seriesplot x=&end y=viz / group=&var name='line';
referenceline y=0.5 / curvelabel="Median" curvelabellocation=inside lineattrs=(color=red pattern=dash);
referenceline x=0 / curvelabel="No Change" curvelabellocation=inside lineattrs=(color=black pattern=ShortDash);
discretelegend 'line' / location=outside;
endlayout;
layout overlay / xaxisopts=(type=discrete label='Difference from No Change'
display=(label)) ;
blockplot x=cut block=diff / class=label display=(outline values label)
repeatedvalues=true;
endlayout;
endlayout;
endgraph;
end;
run;
... View more
08-10-2021
09:17 AM
as per the data I can see only one TRT per usubjid
updated data with one more usubjid
... View more
08-10-2021
08:32 AM
Hi,
DATA avg_score ; INFILE DATALINES DLM="09"X DSD; input USUBJID$1-8 VISIT$9-20 GROUP$21-30 TRT$31-40 avg_score 8.; datalines ; I0001-23 Week 1 RESPONSE Ap 6 mg 36.66666667 I0001-23 Week 1 NORESPONSE Ap 6 mg 26.66666667 I0001-23 Week 2 RESPONSE Ap 6 mg 8.333333333 I0001-23 Week 2 NORESPONSE Ap 6 mg 10 I0001-23 Week 3 RESPONSE Ap 6 mg 8.333333333 I0001-23 Week 3 NORESPONSE Ap 6 mg 10 I0004-27 Week 4 RESPONSE SM 6 mg 20.23809524 I0004-27 Week 4 NORESPONSE SM 6 mg 25.71428571 I0004-27 Week 6 RESPONSE SM 6 mg 51.19047619 I0004-27 Week 6 NORESPONSE SM 6 mg 63.14285714 I0004-27 Week 8 RESPONSE SM 6 mg 23.05555556 I0004-27 Week 8 NORESPONSE SM 6 mg 31.66666667 run;
I have below table as a source and I want to create two tables from this: 1) Total, 2) concatenate total with existing table.
USUBJID
VISIT
GROUP
TRT
avg_score
I0001-23
Week 1
RESPONSE
Ap 6 mg
36.66666667
I0001-23
Week 1
NORESPONSE
Ap 6 mg
26.66666667
I0001-23
Week 2
RESPONSE
Ap 6 mg
8.333333333
I0001-23
Week 2
NORESPONSE
Ap 6 mg
10
I0001-23
Week 3
RESPONSE
Ap 6 mg
8.333333333
I0001-23
Week 3
NORESPONSE
Ap 6 mg
10
I0004-27
Week 4
RESPONSE
SM 6 mg
20.23809524
I0004-27
Week 4
NORESPONSE
SM 6 mg
25.71428571
I0004-27
Week 6
RESPONSE
SM 6 mg
51.19047619
I0004-27
Week 6
NORESPONSE
SM 6 mg
63.14285714
I0004-27
Week 8
RESPONSE
SM 6 mg
23.05555556
I0004-27
Week 8
NORESPONSE
SM 6 mg
31.66666667
expected output 1)
USUBJID
VISIT
GROUP
TRT
avg_score
I0001-23
Week 1
TOTAL
Ap 6 mg
31.66666667
I0001-23
Week 2
TOTAL
Ap 6 mg
9.166666667
I0001-23
Week 3
TOTAL
Ap 6 mg
9.166666667
I0004-27
Week 4
TOTAL
SM 6 mg
22.97619048
I0004-27
Week 6
TOTAL
SM 6 mg
57.16666667
I0004-27
Week 8
TOTAL
SM 6 mg
27.36111111
output 1: avg_score derived by averaging the response and noreponse by week wise.
expected output 2).
USUBJID
VISIT
GROUP
TRT
avg_score
I0001-23
Week 1
RESPONSE
Ap 6 mg
36.66666667
I0001-23
Week 1
NORESPONSE
Ap 6 mg
26.66666667
I0001-23
Week 1
TOTAL
Ap 6 mg
31.66666667
I0001-23
Week 2
RESPONSE
Ap 6 mg
8.333333333
I0001-23
Week 2
NORESPONSE
Ap 6 mg
10
I0001-23
Week 2
TOTAL
Ap 6 mg
9.166666667
I0001-23
Week 3
RESPONSE
Ap 6 mg
8.333333333
I0001-23
Week 3
NORESPONSE
Ap 6 mg
10
I0001-23
Week 3
TOTAL
Ap 6 mg
9.166666667
I0004-27
Week 4
RESPONSE
SM 6 mg
20.23809524
I0004-27
Week 4
NORESPONSE
SM 6 mg
25.71428571
I0004-27
Week 4
TOTAL
SM 6 mg
22.97619048
I0004-27
Week 6
RESPONSE
SM 6 mg
51.19047619
I0004-27
Week 6
NORESPONSE
SM 6 mg
63.14285714
I0004-27
Week 6
TOTAL
SM 6 mg
57.16666667
I0004-27
Week 8
RESPONSE
SM 6 mg
23.05555556
I0004-27
Week 8
NORESPONSE
SM 6 mg
31.66666667
I0004-27
Week 8
TOTAL
SM 6 mg
27.36111111
... View more
08-04-2021
09:12 AM
1 Like
/*Week 2, 'PP01','PP04','PP09','PP10' is missing that means symptoms average for week 2 should be missing*/ /*out of 5 questions only 1 question was answered*/ DATA TEST ;
INFILE DATALINES DLM="09"X DSD;
input ID $ TESTCD$ TEST:$13-42 SCORE DAY Period $;
datalines
;
M21136 PP01 SeverityofItch 6 3 Week 1
M21136 PP01 SeverityofItch 6 5 Week 1
M21136 PP01 SeverityofItch 6 6 Week 1
M21136 PP01 SeverityofItch 7 1 Week 1
M21136 PP01 SeverityofItch 7 2 Week 1
M21136 PP01 SeverityofItch 7 4 Week 1
M21136 PP02 SeverityofDryness 5 2 Week 1
M21136 PP02 SeverityofDryness 6 4 Week 1
M21136 PP02 SeverityofDryness 6 6 Week 1
M21136 PP02 SeverityofDryness 7 1 Week 1
M21136 PP02 SeverityofDryness 7 3 Week 1
M21136 PP02 SeverityofDryness 7 5 Week 1
M21136 PP03 SeverityofCracking 5 4 Week 1
M21136 PP03 SeverityofCracking 6 1 Week 1
M21136 PP03 SeverityofCracking 6 2 Week 1
M21136 PP03 SeverityofCracking 6 3 Week 1
M21136 PP03 SeverityofCracking 6 6 Week 1
M21136 PP03 SeverityofCracking 7 5 Week 1
M21136 PP04 SeverityofSkin Tightness 4 4 Week 1
M21136 PP04 SeverityofSkin Tightness 6 1 Week 1
M21136 PP04 SeverityofSkin Tightness 6 6 Week 1
M21136 PP04 SeverityofSkin Tightness 7 2 Week 1
M21136 PP04 SeverityofSkin Tightness 7 3 Week 1
M21136 PP04 SeverityofSkin Tightness 8 5 Week 1
M21136 PP05 SeverityofScaling 5 4 Week 1
M21136 PP05 SeverityofScaling 6 1 Week 1
M21136 PP05 SeverityofScaling 6 2 Week 1
M21136 PP05 SeverityofScaling 6 3 Week 1
M21136 PP05 SeverityofScaling 6 6 Week 1
M21136 PP05 SeverityofScaling 7 5 Week 1
M21136 PP06 SeverityofShredding or Flaking 5 3 Week 1
M21136 PP06 SeverityofShredding or Flaking 5 4 Week 1
M21136 PP06 SeverityofShredding or Flaking 6 1 Week 1
M21136 PP06 SeverityofShredding or Flaking 6 6 Week 1
M21136 PP06 SeverityofShredding or Flaking 7 2 Week 1
M21136 PP06 SeverityofShredding or Flaking 7 5 Week 1
M21136 PP07 SeverityofRedness 5 1 Week 1
M21136 PP07 SeverityofRedness 5 4 Week 1
M21136 PP07 SeverityofRedness 6 2 Week 1
M21136 PP07 SeverityofRedness 6 3 Week 1
M21136 PP07 SeverityofRedness 6 6 Week 1
M21136 PP07 SeverityofRedness 7 5 Week 1
M21136 PP08 SeverityofBleeding 0 1 Week 1
M21136 PP08 SeverityofBleeding 0 3 Week 1
M21136 PP08 SeverityofBleeding 1 2 Week 1
M21136 PP08 SeverityofBleeding 1 6 Week 1
M21136 PP08 SeverityofBleeding 5 4 Week 1
M21136 PP08 SeverityofBleeding 7 5 Week 1
M21136 PP09 SeverityofBurning 5 4 Week 1
M21136 PP09 SeverityofBurning 6 1 Week 1
M21136 PP09 SeverityofBurning 6 5 Week 1
M21136 PP09 SeverityofBurning 6 6 Week 1
M21136 PP09 SeverityofBurning 7 2 Week 1
M21136 PP09 SeverityofBurning 7 3 Week 1
M21136 PP10 SeverityofStinging 5 4 Week 1
M21136 PP10 SeverityofStinging 6 1 Week 1
M21136 PP10 SeverityofStinging 6 2 Week 1
M21136 PP10 SeverityofStinging 6 6 Week 1
M21136 PP10 SeverityofStinging 7 3 Week 1
M21136 PP10 SeverityofStinging 7 5 Week 1
M21136 PP11 SeverityofPain from Psoriasis 5 4 Week 1
M21136 PP11 SeverityofPain from Psoriasis 5 6 Week 1
M21136 PP11 SeverityofPain from Psoriasis 6 1 Week 1
M21136 PP11 SeverityofPain from Psoriasis 6 5 Week 1
M21136 PP11 SeverityofPain from Psoriasis 7 2 Week 1
M21136 PP11 SeverityofPain from Psoriasis 7 3 Week 1
M21136 PP02 SeverityofDryness 3 12 Week 2
M21136 PP02 SeverityofDryness 4 7 Week 2
M21136 PP02 SeverityofDryness 4 10 Week 2
M21136 PP02 SeverityofDryness 4 11 Week 2
M21136 PP02 SeverityofDryness 4 13 Week 2
M21136 PP02 SeverityofDryness 5 9 Week 2
M21136 PP02 SeverityofDryness 6 8 Week 2
M21136 PP03 SeverityofCracking 3 11 Week 2
M21136 PP03 SeverityofCracking 4 12 Week 2
M21136 PP03 SeverityofCracking 4 13 Week 2
M21136 PP03 SeverityofCracking 5 7 Week 2
M21136 PP03 SeverityofCracking 5 9 Week 2
M21136 PP03 SeverityofCracking 5 10 Week 2
M21136 PP03 SeverityofCracking 7 8 Week 2
M21136 PP05 SeverityofScaling 3 11 Week 2
M21136 PP05 SeverityofScaling 4 7 Week 2
M21136 PP05 SeverityofScaling 4 12 Week 2
M21136 PP05 SeverityofScaling 4 13 Week 2
M21136 PP05 SeverityofScaling 5 9 Week 2
M21136 PP05 SeverityofScaling 6 10 Week 2
M21136 PP05 SeverityofScaling 7 8 Week 2
M21136 PP06 SeverityofShredding or Flaking 4 10 Week 2
M21136 PP06 SeverityofShredding or Flaking 4 11 Week 2
M21136 PP06 SeverityofShredding or Flaking 4 12 Week 2
M21136 PP06 SeverityofShredding or Flaking 4 13 Week 2
M21136 PP06 SeverityofShredding or Flaking 5 7 Week 2
M21136 PP06 SeverityofShredding or Flaking 5 9 Week 2
M21136 PP06 SeverityofShredding or Flaking 6 8 Week 2
M21136 PP07 SeverityofRedness 3 11 Week 2
M21136 PP07 SeverityofRedness 3 13 Week 2
M21136 PP07 SeverityofRedness 4 7 Week 2
M21136 PP07 SeverityofRedness 4 12 Week 2
M21136 PP07 SeverityofRedness 5 9 Week 2
M21136 PP07 SeverityofRedness 5 10 Week 2
M21136 PP07 SeverityofRedness 7 8 Week 2
M21136 PP08 SeverityofBleeding 0 7 Week 2
M21136 PP08 SeverityofBleeding 0 8 Week 2
M21136 PP08 SeverityofBleeding 0 9 Week 2
M21136 PP08 SeverityofBleeding 0 10 Week 2
M21136 PP08 SeverityofBleeding 0 11 Week 2
M21136 PP08 SeverityofBleeding 0 12 Week 2
M21136 PP08 SeverityofBleeding 0 13 Week 2
M21136 PP11 SeverityofPain from Psoriasis 3 10 Week 2
M21136 PP11 SeverityofPain from Psoriasis 4 7 Week 2
M21136 PP11 SeverityofPain from Psoriasis 4 9 Week 2
M21136 PP11 SeverityofPain from Psoriasis 4 11 Week 2
M21136 PP11 SeverityofPain from Psoriasis 4 13 Week 2
M21136 PP11 SeverityofPain from Psoriasis 5 12 Week 2
M21136 PP11 SeverityofPain from Psoriasis 6 8 Week 2
;
run;
... View more
08-03-2021
05:35 AM
could you please give me some tip on how to achieve the missing part based on the PP group and number of days subject answered the questions.
For symptoms subjects should answer at least 2 out of 5 questions on a daily basis.
similarly for sign subjects should answer at least 3 out of 6 questions on a daily basis.
... View more
08-03-2021
04:26 AM
Hi @PaigeMiller
it's average of that particular id : avg(score)*10
... View more
08-02-2021
11:42 AM
data test;
infile datalines delimiter=' ';
input ID$1-6 ARM$8-14 RSN 17 QSDY VISIT$23-30;
datalines;
M21136 M 3 mg 4 1 Week 1
M21136 M 3 mg 2 2 Week 1
M21136 M 3 mg 1 3 Week 1
M21136 M 3 mg 4 4 Week 1
M21136 M 3 mg 1 5 Week 1
M21136 M 3 mg 2 6 Week 1
M21137 P 3 8 Week 2
M21137 P 4 9 Week 2
M21138 M 3 mg 3 15 Week 3
M21138 M 3 mg 2 16 Week 3
M21138 M 3 mg 1 17 Week 3
M21138 M 3 mg 4 18 Week 3
M21138 M 3 mg 2 19 Week 3
M21138 M 3 mg 1 20 Week 3
M21139 L 3 mg 2 21 Week 4
M21139 L 3 mg 1 22 Week 4
;
run;
sorry, code is now fixed for Base SAS.
... View more
08-02-2021
10:56 AM
Hi,
Could someone help me with below problem, i have subject data with days(qsdy), arm, rsn(score) and visit(week1, week2,...till week 52).
I want to create an intermediate table : if subjects missing to give rsn for more than 3 days in a week then the score should be blank, else rsn = score
similarly i want the average of the score by weekly based on the intermediate table which we derived.
Input data:
data test;
infile datalines dlm='09'X dsd missover;
input ID$ ARM $ RSN QSDY VISIT$;
datalines;
M21136 M 3 mg 4 1 Week 1
M21136 M 3 mg 2 2 Week 1
M21136 M 3 mg 1 3 Week 1
M21136 M 3 mg 4 4 Week 1
M21136 M 3 mg 1 5 Week 1
M21136 M 3 mg 2 6 Week 1
M21137 P 3 8 Week 2
M21137 P 4 9 Week 2
M21138 M 3 mg 3 15 Week 3
M21138 M 3 mg 2 16 Week 3
M21138 M 3 mg 1 17 Week 3
M21138 M 3 mg 4 18 Week 3
M21138 M 3 mg 2 19 Week 3
M21138 M 3 mg 1 20 Week 3
M21139 L 3 mg 2 21 Week 4
M21139 L 3 mg 1 22 Week 4
;
run;
Expected output 1:
ID
ARM
RSN
QSDY
VISIT
score
M21136
M 3 mg
4
1
Week 1
4
M21136
M 3 mg
2
2
Week 1
2
M21136
M 3 mg
1
3
Week 1
1
M21136
M 3 mg
4
4
Week 1
4
M21136
M 3 mg
1
5
Week 1
1
M21136
M 3 mg
2
6
Week 1
2
M21137
P
3
8
Week 2
M21137
P
4
9
Week 2
M21138
M 3 mg
3
15
Week 3
3
M21138
M 3 mg
2
16
Week 3
2
M21138
M 3 mg
1
17
Week 3
1
M21138
M 3 mg
4
18
Week 3
4
M21138
M 3 mg
2
19
Week 3
2
M21138
M 3 mg
1
20
Week 3
1
M21139
L 3 mg
2
21
Week 4
M21139
L 3 mg
1
22
Week 4
expected output 2:
ID
ARM
VISIT
Average
M21136
M 3 mg
Week 1
23.33333
M21137
P
Week 2
M21138
M 3 mg
Week 3
21.66667
M21139
L 3 mg
Week 4
... View more
07-30-2021
07:08 PM
A total PP score with a range of 0 to 100 will be derived from taking the average of the symptom and sign scores.
Total score can only be derived after deriving the symptoms and signs
Missing values can be determined be using the day variable : e.g., for symptom : To obtain a symptom score on a given day, responses to at least 2 of the 5 questions must be available. If more than 3 questions are missing, the symptom score is considered missing.
For sign : Responses to at least 3 of the 6 questions must be available in order to obtain a sign score for a given day. If more than 3 questions are missing, the sign score is considered missing.
This can be achieved by using the day variable for each ID we have 1-7 days in week 1 and so on... in my original data i have data more than 50 weeks.
On a daily based every ID will answer some questions (11 questions - 5 belongs to symptoms and 6 belongs to signs). if they answer only 1 in symptoms then we will flag them as missing for that particular day.
as per the task :
The PP is an 11-item subject-reported instrument that assesses severity of symptoms and subject observed signs commonly associated in plaque psoriasis. It has been shown to be reliable and valid in measuring symptoms and signs of subjects with moderate-to-severe plaque psoriasis in the clinic and has strong psychometric properties in assessing treatment effects in clinical trials. Subjects are asked to rate the severity of each item on an 11-point Numeric Rating Scale ranging from 0 (absent) to 10 (worst imaginable).
A symptom score will be derived by averaging the 5 questions (i.e., itch, pain, stinging, burning, skin tightness) included in the symptom score and multiplying by 10. To obtain a symptom score on a given day, responses to at least 2 of the 5 questions must be available. If more than 3 questions are missing, the symptom score is considered missing.
A sign score will be derived by averaging the 6 questions (i.e., skin dryness, cracking, scaling, shedding or flaking, redness, bleeding) included in the sign score and multiplying by 10. Responses to at least 3 of the 6 questions must be available in order to obtain a sign score for a given day. If more than 3 questions are missing, the sign score is considered missing.
Both symptom and sign scores range from 0 to 100, where 0 represents the least severe symptom/sign and 100 the most severe.
A total PP score with a range of 0 to 100 will be derived from taking the average of the symptom and sign scores.
Trial administered the PP with a 24-hour recall period on a daily basis. To calculate the scores at each visit, the daily scores with 24-hour recall periods over the prior 7 days will be used and the average score to each of the 11 questions will be used as the score at that visit. In case missing data arise during the 7 days prior to the visit, daily scores of at least 4 days out of the 7 can be used. If greater than 3 scores are missing, the average score will be missing. The baseline PP scores are calculated based on the daily diary collected data during the screening period.
I believe the intermediate table will be averages on a daily basis,
To calculate the scores at each visit, the daily scores with 24-hour recall periods over the prior 7 days will be used and the average score to each of the 11 questions will be used as the score at that visit. In case missing data arise during the 7 days prior to the visit, daily scores of at least 4 days out of the 7 can be used. If greater than 3 scores are missing, the average score will be missing.
This has already been calculated and derived as DAY variable.
... View more