data_quality_date

55 views
Skip to first unread message

elda....@gmail.com

unread,
Apr 7, 2021, 9:22:39 PM4/7/21
to redcap open
Hi Experts, 
for my institution I am using the longitudinal structure for a study. I have a form/page that I have made cyclical (repeatable for an undefined number of times, it is a follow up visit). How can I put a check in data-quality so that the visit dates (dd/mm/yyyy) are progressive? Thanks for your help, I'm learning how to use data-quality rules.

Elda

(Peter MacIsaac)

unread,
Apr 7, 2021, 11:18:14 PM4/7/21
to redcap open
One option is to use the automated date entry options so that there is less option for data entry error and also speeds up the process,  that way the entries will have to follow a time sequence order - unless you are trying to fix some other issue?

lakshmikanth

unread,
Apr 8, 2021, 2:42:15 AM4/8/21
to (Peter MacIsaac), elda....@gmail.com, redcap open
I have used a repeatable instrument with a calculated field (Hidden) which compare the instance values of the date field using the following condition

if(if(datediff ([date][previous-instance], [date], "d","dmy", true)!='',datediff ([date][previous-instance], [date], "d","dmy", true),0) >=0
and
if(datediff ([date][next-instance], [date], "d","dmy", true)!='',datediff ([date][next-instance], [date], "d","dmy", true),0) <=0,1,0)

Later this field is used to populate a message accordingly

image.png

Kindly see if it helps you




Thanking You
Lakshmi Kanth L R

--
You received this message because you are subscribed to the Google Groups "redcap open" group.
To unsubscribe from this group and stop receiving emails from it, send an email to redcap_open...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/redcap_open/a930c042-867a-41ec-8be1-6bde0e897818n%40googlegroups.com.

Luke Stevens

unread,
Apr 8, 2021, 3:05:10 AM4/8/21
to elda....@gmail.com, redcap open

You could show a message that a date entered is prior to the date in the corresponding field in the previous instance using a descriptive text field and branching logic utilising some instance smart variables...

 

              The date entered is prior to the date entered for the previous visit ([rpt_event_arm_1][visitdt][previous-instance])

 

              datediff([rpt_event_arm_1][visitdt][previous-instance], [rpt_event_arm_1][visitdt][current-instance], "d", true) < 0

 

Does that help?

 

Regards,

Luke

 

From: redca...@googlegroups.com <redca...@googlegroups.com> On Behalf Of elda....@gmail.com
Sent: Thursday, 8 April 2021 11:23
To: redcap open <redca...@googlegroups.com>
Subject: [EXTERNAL]data_quality_date

 

CAUTION:  External Email. Please be cautious with attachments and clicking links

 

Hi Experts, 

for my institution I am using the longitudinal structure for a study. I have a form/page that I have made cyclical (repeatable for an undefined number of times, it is a follow up visit). How can I put a check in data-quality so that the visit dates (dd/mm/yyyy) are progressive? Thanks for your help, I'm learning how to use data-quality rules.

 

Elda

--

You received this message because you are subscribed to the Google Groups "redcap open" group.
To unsubscribe from this group and stop receiving emails from it, send an email to redcap_open...@googlegroups.com.



This e-mail and any attachments to it (the "Communication") are, unless otherwise stated, confidential, may contain copyright material and is for the use only of the intended recipient. If you receive the Communication in error, please notify the sender immediately by return e-mail, delete the Communication and the return e-mail, and do not read, copy, retransmit or otherwise deal with it. Any views expressed in the Communication are those of the individual sender only, unless expressly stated to be those of Murdoch Children’s Research Institute (MCRI) ABN 21 006 566 972 or any of its related entities. MCRI does not accept liability in connection with the integrity of or errors in the Communication, computer virus, data corruption, interference or delay arising from or in respect of the Communication.

el_ da

unread,
Apr 8, 2021, 8:20:54 PM4/8/21
to Luke Stevens, redcap open

Thank you very much, with your suggestions I was able to put the correct control. Really, thank you for your incredible support!

Regards.

Elda

Peter Macisaac (POP)

unread,
Apr 12, 2021, 7:50:19 PM4/12/21
to el_ da, Luke Stevens, redcap open
Elda

I am also sure there is a way to automate the prepopulation of the date using @DEFAULT

I am a believer in reducing unneeded user input (clicks or data entry) - one of the principles of good software design (and building redcap projects is actually  software development and needs to use the disciplines that make it easy for users :)

That way the most recent instance will always be later than the first and if automated will save effort

You can still use the solutions suggested in case someone really wants to make an error by manually inputing the date

Cheers

Peter

Reply all
Reply to author
Forward
0 new messages