RC201 Creating Data Forms In REDCap - Fred Hutch

Transcription

RC201Creating Data Forms in REDCapredcap@fredhutch.orgCollaborative Data Services (CDS)

Agendal QuickTour around REDCapl Usingthe Online Designer to create/edit formsl Usingthe Data Dictionary to create/edit formsl Creatinga Codebook & PDFs of formsl Developmentvs Production

Quick Tour around REDCap

My Projects Page

Project NavbarAccess to most parts ofREDCap including otherpages (My Projects, ProjectHome, etc.),Data collection,Other stuff (Applications),Reports,Help

Project HomeBrief project overviewincluding users and generalusage statistics

Project SetupAccess to online designer,data dictionary, mainproject settings, optionalmodules andcustomizations, user rights,etc.

Record Home PageWhen you click on subject id,you will move to a focusedview of a single record andaccess to "actions for record"

Record Status DashboardOverview of all yourrecords; access to customdashboards.

Add/Edit RecordsAllows you to.1. Select a recordby subject id.2. Add a newrecord.3. Search for arecord by anyfield inproject.

Using the OnlineDesigner to create/editforms

Creating a data form using the designerlStarting the designerlClick Designer link under Project Home andDesign on left-hand navigation barlClick Online Designer button under Designyour data collection instruments & enableyour surveys under Project Setup tab

Initial ProjectllFor new projects using the Fred Hutch template, you will startwith a single data collection instrument, Sample InstrumentDo not delete this instrument; rename it instead

Your first formlllIt will always havethe record id(subject id) fieldDon’t delete thisfield; it is theprimary key of yourproject.You may, however,rename it

Creating a data form using the designerlStarting the designerlClick Designer link under Project Home andDesign on left-hand navigation barlClick Online Designer button under Designyour data collection instruments & enableyour surveys under Project Setup tab

Editing a fieldllClicking the pencil icon next to a field, brings youto the Edit Field dialogThis dialog will vary depending on the Field Typeselected

Adding a fieldllClicking the Add Fieldbutton, brings you tothe Add New FielddialogThis dialog will againvary depending on theField Type selected

Field Types Standard fields Text Box REDCap supports autocomplete based on biomedical ontologies(e.g., ICD-10 codes).Notes Box – paragraph of textCalculated Field – numeric calculationMultiple Choice – Drop-down List (Single Answer)Multiple Choice – Radio buttons (Singe Answer)Checkboxes (Multiple Answers)Yes – No – yes/no radio buttonTrue – False – true/false radio buttonSignature – draw signature with mouse or fingerFile Upload – attach documents to formSlider / Visual Analog Scale – slider from 1 to 100Descriptive Text – does not capture dataBegin New Section – also does not capture dataDynamic Query (SQL) – dropdown hooked up to another project. Requires admin to setupMatrix fields Adds a group of radio button or checkbox fields sharing same set of responses

Field PropertieslField Type – type of fieldlField Label – the prompt the user seeslVariable Name – the field name used at export and when branching and piping; must be unique acrosslValidation – simple validationlRequired – is field mandatory in order to save record?lIdentifier – does this contain PII?lCustom Alignment – positions field (answers) on pagelField Note – help text displayed underneath field in smaller fontlField Annotation – note to designer or way to designate special field status; not displayed to data entryuserentire project

Required fields, identifier, & validationlRequiredlllIdentifierlllAny field can be marked as requiredCan be over-ruled by user at data entry timeAny field can be marked as IdentifierWill be stripped from exports (unless user has see “full data set” right)ValidationlllOnly for textbox fieldsConstrain user to entering valid date, integer, number, email address, phone number,zipcode, etc.You can also specify min and max values for numeric/date types; but boundaries can beoverridden at data entry time

CalculationslNumeric calculationslllllNo text or date calculations!Possible workarounds: use branching logic to display alternate textmessages; use Data Entry Triggers (a programming extension) for datecalculationsReference field names using [field name] syntaxCan reference fields on other forms!l When using longitudinal project (discussed in 301 seminar), you need tomodify this syntax if field is from a different eventREDCap has a number of numeric, datetime, and boolean functions tosupport calculations (and branching, reports, and DQRs)

Copy value of field from another data form[bas height]

BMI Calculation (lbs/inches)lWithout rounding([bas weight]/([bas height]*[bas height]))*703lWith roundinground(([bas weight]/([bas height]*[bas height]))*703,1)Example from Baseline Interview in Training -- Classic Project

Action TagslOriginally added to REDCap in version 6.7lGoes in Field Annotation property of fieldlMore added every so often

Action TagslVersion 7.6 added a bunch of useful action tags, includingl@HIDEBUTTON – use to hide today/now button for a date/time fieldl@HIDECHOICE – use to retire one or more choices for a multiple-choicefield (radio, drop-down, checkbox)l@MAXCHECKED – specify max no. of checkboxes that can be checkedl@MAXCHOICE – causes choice to be disabled after so many records haveselected the choicel@NONEOFTHEABOVE – allows for a checkbox to designate one (or morethan one) choice that is mutually exclusive of all other choicesl@CHARLIMIT, @WORDLIMIT – for text & notes fieldsl@RANDOMORDER – randomizes order of choices

Branching (a.k.a. skip logic) You can use Drag-N-Drop or Advanced syntax

Branching Example: displaying or hiding pregnancy question

Branching logic examples Checking if a field is not null (i.e., answered)[bas packs] '2' and [bas packs] '' Checking if a field is null[enr birth date] "" Referencing checkbox fieldFor quotes, youcan use eithersinge (') ordouble ("), but beconsistent insame expression![enr race(6)] '1'Examples from Enrollment and Baseline Interview in Training -- Classic Project

Matrix Fields

Copying fields & choiceslCopy fieldlCopy choices

PipinglAllows you to copy the value from one field into various other places on a formllllllllllllField LabelField NoteSection HeaderMatrix field column headersOption labels for multiple choice fields (radio, drop-down, checkbox)Slider field labels (i.e. text displayed above slider bar)Custom record locking text (if defined, displayed at bottom of form)Survey InstructionsSurvey Completion TextSurvey invitation emails (sent via Participant List or Automated Invitations) - includes bothsubject and message Simply use same syntax as when referring to fields in calculations and branching, i.e.[field name]

Piping Example Designer Data entry time

Using the Data Dictionaryto create/edit forms

Data DictionaryllEverything discussed using Designer can also be done using thedownloaded data dictionaryYou can develop projects using either llllDesignerData Dictionaryor both!My stylellI like to use Designer most of the timeBut I use the Data Dictionary when I need to create similar fields multipletimes on same form or on different forms or fix a bunch of fields because achange in field name used in branching logic in multiple places

Data Dictionary

Data DictionarylEach column maps to a property in the designerlDownload and upload using CSV formatllNot TSV!lNot Excel!Note: if you use non-English language characters in your fieldlabels or choices, you will want to save using the "CSV UTF-8"format. Otherwise, non-English language characters will turninto funny ? characters

Data Dictionary (1 of 2)

Data Dictionary (2 of 2)

Data Dictionaryl UploadingChangesREDCap will list out any errors and/or warnings beforeyou can commit your changesl Don't forget to click Commit Changesl

Creating Codebook &PDFs of forms

Codebook & PDFslCodebooklPDFs of forms (with or without data)lOpen form (in data collection mode)

Development vs.Production

Development & Production ModesllIndicated in Navigation bar(and a few other places)You can do anything in Development mode

Development & Production ModeslOnce in Production ModelClick on Online Designer from Project Setup tablChanges will be held in draft mode and need to be submitted &approved before going live (production)lCDS approves all production changes (except for automatically approvedones)!l This is for your data safety!This topic discussed in much greater detail in RC 302 class

Thank you!redcap@fredhutch.orgCollaborative Data Services (CDS)

Data Dictionary lEverything discussed using Designer can also be done using the downloaded data dictionary lYou can develop projects using either lDesigner lData Dictionary lor both! lMy style lI like to use Designer most of the time lBut I use the Data Dictionary when I need to create similar fields multiple