Dear Experts,
Greetings
I have the following type of repeated measures data (table 1), and events
data in table 2 (single measure). I want to perform the following tasks (in
R or excel sheet please).
- To filter subjects who had any response at least 3 days.
- Response should be > 5 in each day.
- Then table 1 should have another column, date first response recorded.
- Then both tables should be merged
Table 1 ? Response Data
Sub_No Response Date1 5 01-Jan1 5
02-Jan2 5 01-Jan2 10 02-Jan2
10 03-Jan2 10 04-Jan2 10
05-Jan3 10 01-Jan3 10 02-Jan3
10 03-Jan4 5 01-Jan4 5
02-Jan4 10 03-Jan4 10 04-Jan4
10 05-Jan
Table 2 ? Event Data
Sub_No Response Date1 No2 Yes 30
Jan3 Yes 29 Jan4 No
Thanks for your help.
Regards,
Analysing data with repeated measure variable
3 messages · Ahmad Raza, Bert Gunter, PIKAL Petr
This looks like homework. We don't do homework on this list. To see what is done here, read and follow the posting guide linked below. If not homework, I think it is still very much out of bounds anyway, as you appear to be asking us to do your work for you.
On Thu, May 6, 2021, 2:32 PM Ahmad Raza <clinical0910 at gmail.com> wrote:
Dear Experts,
Greetings
I have the following type of repeated measures data (table 1), and events
data in table 2 (single measure). I want to perform the following tasks (in
R or excel sheet please).
- To filter subjects who had any response at least 3 days.
- Response should be > 5 in each day.
- Then table 1 should have another column, date first response recorded.
- Then both tables should be merged
Table 1 ? Response Data
Sub_No Response Date1 5 01-Jan1 5
02-Jan2 5 01-Jan2 10 02-Jan2
10 03-Jan2 10 04-Jan2 10
05-Jan3 10 01-Jan3 10 02-Jan3
10 03-Jan4 5 01-Jan4 5
02-Jan4 10 03-Jan4 10 04-Jan4
10 05-Jan
Table 2 ? Event Data
Sub_No Response Date1 No2 Yes 30
Jan3 Yes 29 Jan4 No
Thanks for your help.
Regards,
[[alternative HTML version deleted]]
______________________________________________ R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.
3 days later
Hi Do not post in HTML, if you do not want your data to be messed. see ?ifelse and/or logical operations maybe ?sort or ?order and ?min maybe ?merge Cheers Petr
-----Original Message-----
From: R-help <r-help-bounces at r-project.org> On Behalf Of Ahmad Raza
Sent: Thursday, May 6, 2021 9:41 PM
To: r-help at r-project.org
Subject: [R] Analysing data with repeated measure variable
Dear Experts,
Greetings
I have the following type of repeated measures data (table 1), and events
data in table 2 (single measure). I want to perform the following tasks (in R
or excel sheet please).
- To filter subjects who had any response at least 3 days.
- Response should be > 5 in each day.
- Then table 1 should have another column, date first response recorded.
- Then both tables should be merged
Table 1 ? Response Data
Sub_No Response Date1 5 01-Jan1 5
02-Jan2 5 01-Jan2 10 02-Jan2
10 03-Jan2 10 04-Jan2 10
05-Jan3 10 01-Jan3 10 02-Jan3
10 03-Jan4 5 01-Jan4 5
02-Jan4 10 03-Jan4 10 04-Jan4
10 05-Jan
Table 2 ? Event Data
Sub_No Response Date1 No2 Yes 30
Jan3 Yes 29 Jan4 No
Thanks for your help.
Regards,
[[alternative HTML version deleted]]
______________________________________________ R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting- guide.html and provide commented, minimal, self-contained, reproducible code.