piping display

21 views
Skip to first unread message

Amandine Carmagnac

unread,
Jun 6, 2024, 9:16:02 PMJun 6
to redca...@googlegroups.com
Dear all

I have a question about piping, and I hope you will be able to help me out.

Below is an example of the piping I'm aiming to use.
 [clinical_id], [treatment], C[treatment_cycle]

Currently this is what I will see displayed in REDCap.

1234563451345, ______ C______

 The reason behind this is that there is currently no data entered for both [treatment] and [treatment_cycle]. Although I can work with that, I'm wondering, from an aesthetic point of view, if it would be possible to only have the fields where data has been entered to be displayed.

For the example above  rather than,
1234563451345, ______ C______

I wonder if it would be possible to only see this instead 
1234563451345

Thank you so much.

Amandine

David Edwards

unread,
Jun 6, 2024, 10:11:27 PMJun 6
to Amandine Carmagnac, redca...@googlegroups.com
Sorry no time for a thorough answer but...

Have you tried a textbox field with the @CALCTEXT action tag?
Then you could use nested ifs to decide what to show depending on what has a value and what doesn't. Here's a simple version:

@CALTEXT(if(([treatment]<>'' and [treatment_cycle]<>''),  "[clinical_id], [treatment], C[treatment_cycle]",  "[clinical_id]"))

But you could have nested ifs to cover other scenarios.


From: redca...@googlegroups.com <redca...@googlegroups.com> on behalf of Amandine Carmagnac <amandine....@gmail.com>
Sent: 07 June 2024 01:15
To: redca...@googlegroups.com <redca...@googlegroups.com>
Subject: [REDCap Open] piping display
 
--
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/CAByum3D%3Dh5OVuwoQmWadUwgPO6TKn3Gzu0ve9Db4S0cjD9MSYQ%40mail.gmail.com.

David Edwards

unread,
Jun 6, 2024, 10:12:52 PMJun 6
to Amandine Carmagnac, redca...@googlegroups.com
P.s. And if you don't like the aesthetic appearance of the CALCTEXT field, you could always pipe that into a descriptive field so it looks better.


From: redca...@googlegroups.com <redca...@googlegroups.com> on behalf of David Edwards <dw...@hotmail.com>
Sent: 07 June 2024 02:11
To: Amandine Carmagnac <amandine....@gmail.com>; redca...@googlegroups.com <redca...@googlegroups.com>
Subject: Re: [REDCap Open] piping display
 

Luke Stevens

unread,
Jun 6, 2024, 10:29:40 PMJun 6
to David Edwards, Amandine Carmagnac, redca...@googlegroups.com

@CALCTEXT is a good option. Another one is to use embedded descriptive text fields with appropriate branching logic.

 

For example, you have the fields:

  • clinical_id
  • treatment
  • treatment_cycle

 

Create a counterpart descriptive text field for each:

  • clinical_id_desc
    • Label "[clinical_id]"
    • Branching [clinical_id]<> ''
  • treatment_desc
    • Label "[treatment]"
    • Branching [treatment]<> ''
  • treatment_cycle_desc
    • Label "C[treatment_cycle]"
    • Branching [treatment_cycle]<> ''

 

And then a descriptive text field to bring them together:

  • display_desc
    • Label "{clinical_id_desc} {treatment_desc} {treatment_cycle_desc}"

 

You can include commas or other punctuation if you really need via their own individual descriptive text fields – it can just be a bit fiddly with the branching logic making sure only the ones you want displayed get displayed.

 

HTH

Luke

Luke Stevens
Research Data Systems Manager
Clinical Epidemiology & Biostatistics Unit (CEBU)
Murdoch Children's Research Institute
The Royal Children's Hospital, 50 Flemington Road
Parkville, Victoria 3052 Australia
T   +61 3 9345 6552
E   luke.s...@mcri.edu.au
W  mcri.edu.au

 

 

 

From: redca...@googlegroups.com <redca...@googlegroups.com> On Behalf Of David Edwards


Sent: Friday, June 7, 2024 12:13 PM
To: Amandine Carmagnac <amandine....@gmail.com>; redca...@googlegroups.com

Subject: [EXTERNAL]Re: [REDCap Open] piping display

 

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

 



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.

Reply all
Reply to author
Forward
0 new messages