Package: redcapAPI 2.10.1

Shawn Garbett

redcapAPI: Interface to 'REDCap'

Access data stored in 'REDCap' databases using the Application Programming Interface (API). 'REDCap' (Research Electronic Data CAPture; <https://projectredcap.org>, Harris, et al. (2009) <doi:10.1016/j.jbi.2008.08.010>, Harris, et al. (2019) <doi:10.1016/j.jbi.2019.103208>) is a web application for building and managing online surveys and databases developed at Vanderbilt University. The API allows users to access data and project meta data (such as the data dictionary) from the web programmatically. The 'redcapAPI' package facilitates the process of accessing data with options to prepare an analysis-ready data set consistent with the definitions in a database's data dictionary.

Authors:Benjamin Nutter [ctb, aut], Shawn Garbett [cre, ctb], Savannah Obregon [ctb], Thomas Obadia [ctb], Marcus Lehr [ctb], Brian High [ctb], Stephen Lane [ctb], Will Beasley [ctb], Will Gray [ctb], Nick Kennedy [ctb], Tan Hsi-Nien [ctb], Jeffrey Horner [aut], Jeremy Stephens [ctb], Cole Beck [ctb], Bradley Johnson [ctb], Philip Chase [ctb], Paddy Tobias [ctb], Michael Chirico [ctb]

redcapAPI_2.10.1.tar.gz
redcapAPI_2.10.1.zip(r-4.5)redcapAPI_2.10.1.zip(r-4.4)redcapAPI_2.10.1.zip(r-4.3)
redcapAPI_2.10.1.tgz(r-4.4-any)redcapAPI_2.10.1.tgz(r-4.3-any)
redcapAPI_2.10.1.tar.gz(r-4.5-noble)redcapAPI_2.10.1.tar.gz(r-4.4-noble)
redcapAPI_2.10.1.tgz(r-4.4-emscripten)redcapAPI_2.10.1.tgz(r-4.3-emscripten)
redcapAPI.pdf |redcapAPI.html
redcapAPI/json (API)
NEWS

# Install 'redcapAPI' in R:
install.packages('redcapAPI', repos = c('https://vubiostat.r-universe.dev', 'https://cloud.r-project.org'))

Peer review:

Bug tracker:https://github.com/vubiostat/redcapapi/issues

On CRAN:

10.53 score 21 stars 2 packages 141 scripts 1.1k downloads 1 mentions 130 exports 23 dependencies

Last updated 17 days agofrom:25ab82335e. Checks:OK: 7. Indexed: yes.

TargetResultDate
Doc / VignettesOKNov 04 2024
R-4.5-winOKNov 04 2024
R-4.5-linuxOKNov 04 2024
R-4.4-winOKNov 04 2024
R-4.4-macOKNov 04 2024
R-4.3-winOKNov 04 2024
R-4.3-macOKNov 04 2024

Exports:allocationTableallocationTable_offlineassembleCodebookcastCheckCodecastCheckCodeCharactercastCheckedcastCheckedCharactercastCheckForImportcastCheckLabelcastCheckLabelCharactercastCodecastCodeCharactercastDpCharactercastDpNumericcastForImportcastLabelcastLabelCharactercastLogicalcastRawcastTimeHHMMcastTimeMMSSchangedRecordscheckbox_suffixescreateFileRepositoryFoldercreateRedcapProjectdefault_cast_characterdefault_cast_no_factordeleteArmsdeleteDagsdeleteEventsdeleteFileRepositorydeleteFilesdeleteFromFileRepositorydeleteRecordsdeleteUserRolesdeleteUsersexportArmsexportBulkRecordsexportBundleexportDagsexportDataQualityexportEventsexportFieldNamesexportFileRepositoryexportFileRepositoryListingexportFilesexportFilesMultipleexportFromFileRepositoryexportInstrumentsexportLoggingexportMappingsexportMetaDataexportNextRecordNameexportProjectInformationexportProjectXmlexportRecordsexportRecords_offlineexportRecordsTypedexportRepeatingInstrumentsEventsexportReportsexportReportsTypedexportSurveyLinkexportSurveyParticipantsexportSurveyQueueLinkexportSurveyReturnCodeexportUserDagAssignmentsexportUserRoleAssignmentsexportUserRolesexportUsersexportVersionfieldChoiceMappingguessCastguessDateimportArmsimportDagsimportEventsimportFileRepositoryimportFilesimportFileToRecordimportMappingsimportMetaDataimportProjectInformationimportRecordsimportRepeatingInstrumentsEventsimportToFileRepositoryimportUserDagAssignmentsimportUserRoleAssignmentsimportUserRolesimportUsersisNAorBlankmakeApiCallmChoiceCastmissingSummarymissingSummary_offlinena_valuesofflineConnectionparseBranchingLogicprepUserImportDatapreserveProjectpurgeProjectraw_castreadPreservedProjectrecastRecordsrecodeCheckreconstituteFileFromExportREDCAP_METADATA_FIELDTYPEREDCAP_METADATA_VALIDATION_TYPEREDCAP_PROJECT_PURPOSEREDCAP_REPEAT_INSTRUMENT_STRUCTUREREDCAP_SYSTEM_FIELDSredcapConnectionredcapFactorFlipredcapProjectInforenameRecordrestoreProjectreviewInvalidRecordsskip_validationsplitFormsstripHTMLandUnicodestripHTMLTagsstripUnicodeswitchDagunitsFieldAnnotationunlockREDCapvalChoicevalPhonevalRxvalSkipvectorToApiBodyListwiderRepeated

Dependencies:askpassassertthatbackportscheckmatechroncpp11curlfilelockgenericsgetPassjsonlitekeyringlabelVectorlubridatemimeopensslR6rappdirsrstudioapisodiumsystimechangeyaml

Casting Data

Rendered fromredcapAPI-casting-data.Rnwusingutils::Sweaveon Nov 04 2024.

Last update: 2023-11-13
Started: 2023-11-13

Data Validation with exportRecordsTyped

Rendered fromredcapAPI-data-validation.Rnwusingutils::Sweaveon Nov 04 2024.

Last update: 2023-11-13
Started: 2023-11-13

Getting Started: Connecting to REDCap

Rendered fromredcapAPI-getting-started-connecting.Rnwusingutils::Sweaveon Nov 04 2024.

Last update: 2023-11-13
Started: 2023-11-13

Missing Data Detection with exportRecordsTyped

Rendered fromredcapAPI-missing-data-detection.Rnwusingutils::Sweaveon Nov 04 2024.

Last update: 2023-11-13
Started: 2023-11-13

redcapAPI Best Practices

Rendered fromredcapAPI-best-practices.Rnwusingutils::Sweaveon Nov 04 2024.

Last update: 2023-06-12
Started: 2023-06-12

redcapAPI FAQ

Rendered fromredcapAPI-faq.Rnwusingutils::Sweaveon Nov 04 2024.

Last update: 2024-01-08
Started: 2024-01-08

redcapAPI Offline Connections

Rendered fromredcapAPI-offline-connection.Rnwusingutils::Sweaveon Nov 04 2024.

Last update: 2023-10-11
Started: 2023-10-11

Readme and manuals

Help Manual

Help pageTopics
Generate Allocation Tables for the Randomization ModuleallocationTable allocationTable.redcapApiConnection allocationTable_offline
Export, Import, and Delete Arms from a ProjectarmsMethods deleteArms deleteArms.redcapApiConnection exportArms exportArms.redcapApiConnection importArms importArms.redcapApiConnection
S3 method to turn curl response into characteras.character.response
Assemble Codebook From the Data Dictionaryas.list.redcapCodebook assembleCodebook assembleCodebook.redcapConnection
returns a list of record IDs changed (adds, updates, deletes)changedRecords
Checkbox Suffixescheckbox_suffixes
Construct a Link to a REDCap FormconstructLinkToRedcapForm constructLinkToRedcapForm.redcapApiConnection constructLinkToRedcapForm.redcapOfflineConnection
Create a Folder in the File RepositorycreateFileRepositoryFolder createFileRepositoryFolder.redcapApiConnection
Create REDCap ProjectcreateRedcapProject createRedcapProject.redcapApiConnection
Export and Import Users Assigned to Data Access GroupsdagAssignmentMethods exportUserDagAssignments exportUserDagAssignments.redcapApiConnection importUserDagAssignments importUserDagAssignments.redcapApiConnection
Export, Import, Delete Data Access Groups from a ProjectdagMethods deleteDags deleteDags.redcapApiConnection exportDags exportDags.redcapApiConnection importDags importDags.redcapApiConnection
Delete Records from a ProjectdeleteRecords deleteRecords.redcapApiConnection
Deprecated Functionsdeprecated_redcapProjectInfo redcapProjectInfo redcapProjectInfo.redcapApiConnection
Drop Row Where Repeat Instrument Is NAdropRepeatingNA
Export, Import, and Delete Event SettingsdeleteEvents deleteEvents.redcapApiConnection eventsMethods exportEvents exportEvents.redcapApiConnection importEvents importEvents.redcapApiConnection
A helper function to export multiple records and forms using a single call.exportBulkRecords
Perform a bundle of API calls.exportBundle exportBundle.redcapApiConnection
A helper function to export data queries from the Data Quality REDCap module.exportDataQuality
Export Codebook Mappings for Fields with External DependenciesexportExternalCoding exportExternalCoding.redcapApiConnection
Export the Complete Field Names for a REDCap ProjectexportFieldNames exportFieldNames.redcapApiConnection exportFieldNamesArgs
Export a Listing of Folders and Files in the File RepositoryexportFileRepositoryListing exportFileRepositoryListing.redcapApiConnection
Export Multiple Files From a ProjectexportFilesMultiple exportFilesMultiple.redcapApiConnection
Export Instruments Defined in a ProjectexportInstruments exportInstruments.redcapApiConnection
Export Logging RecordsexportLogging exportLogging.redcapApiConnection
Export PDF file of Data Collection InstrumentsexportPdf exportPdf.redcapApiConnection
Export Entire Project as REDCap XML FileexportProjectXml exportProjectXml.redcapApiConnection
Export the REDCap Version NumberexportVersion exportVersion.redcapApiConnection
Extraction and Assignment for 'redcapFactor'sExtraction print.redcapFactor [.redcapFactor
Functions for Casting Fields After Export (Post Processing)castForImport fieldCastingFunctions guessCast guessDate mChoiceCast recastRecords
Split a Field Choice Mapping Into a Two Column MatrixfieldChoiceMapping fieldChoiceMapping.character fieldChoiceMapping.redcapApiConnection
Convert a REDCap Data Field to an R VectorfieldToVar
Helper functions for 'exportRecordsTyped' Validation and CastingcastCheckCode castCheckCodeCharacter castChecked castCheckedCharacter castCheckForImport castCheckLabel castCheckLabelCharacter castCode castCodeCharacter castDpCharacter castDpNumeric castLabel castLabelCharacter castLogical castRaw castTimeHHMM castTimeMMSS default_cast_character default_cast_no_factor fieldValidationAndCasting isNAorBlank na_values raw_cast skip_validation valChoice valPhone valRx valSkip
Export, Import, or Delete Files to a Field in a REDCap ProjectdeleteFiles deleteFiles.redcapApiConnection exportFiles exportFiles.redcapApiConnection fileMethods importFiles importFiles.redcapApiConnection
Export, Import, or Delete Multiple Files from the File RepositorydeleteFileRepository deleteFileRepository.redcapApiConnection exportFileRepository exportFileRepository.redcapApiConnection fileRepositoryMethods importFileRepository importFileRepository.redcapApiConnection
Reconstruct the file repository pathfileRepositoryPath
Remove Rows Containing Only Missing ValuesfilterEmptyRow
Export, Import, and Delete Individual Files from the File RepositorydeleteFromFileRepository deleteFromFileRepository.redcapApiConnection exportFromFileRepository exportFromFileRepository.redcapApiConnection fromFileRepositoryMethods importToFileRepository importToFileRepository.redcapApiConnection
Return a vector of the Project ID FieldsgetProjectIdFields
Import a File With Option to Create A Record to Receive the FileimportFileToRecord
Import Records to a ProjectimportRecords importRecords.redcapApiConnection
Helper functions for formatting validation failure reportformat.invalid invalidSummary print.invalid summary.invalid
Identify Check Fields with a Zero Coded OptionisZeroCodedCheckField warnOfZeroCodedCheckCasting warnZeroCodedFieldPresent
Make REDCap API CallsmakeApiCall
Export and Import Instrument-Event MappingsexportMappings exportMappings.redcapApiConnection importMappings importMappings.redcapApiConnection mappingMethods
Export and Import the Project Meta Data (Data Dictionary)exportMetaData exportMetaData.redcapApiConnection importMetaData importMetaData.redcapApiConnection metaDataMethods metaDataMethodsArgs
Report of Missing ValuesmissingSummary missingSummary.redcapApiConnection missingSummary_offline
Parse Branching LogicparseBranchingLogic
Prepare User Data for ImportprepUserImportData
Preserve Project Data LocallypreserveProject preserveProject.redcapApiConnection readPreservedProject readPreservedProject.character readPreservedProject.list
Export and Import Project SettingsexportProjectInformation exportProjectInformation.redcapApiConnection importProjectInformation importProjectInformation.redcapApiConnection projectInformationMethods
Purge and Restore Project DatapurgeProject purgeProject.redcapApiConnection purgeRestoreProject restoreProject restoreProject.list restoreProject.redcapApiConnection
Change labeling of 'checkbox' variablesrecodeCheck
Save a File to a Local Directory from a ResponsereconstituteFileFromExport
Export Next Record Name or Rename a RecordexportNextRecordName exportNextRecordName.redcapApiConnection recordsManagementMethods renameRecord renameRecord.redcapApiConnection
Export Records and ReportsexportRecords exportRecords.redcapApiConnection exportRecords_offline exportReports exportReports.redcapApiConnection recordsMethods
Export Records or Reports From a ProjectexportRecordsTyped exportRecordsTyped.redcapApiConnection exportRecordsTyped.redcapOfflineConnection exportReportsTyped exportReportsTyped.redcapApiConnection recordsTypedMethods
Connect to a REDCap DatabaseofflineConnection print.redcapApiConnection print.redcapOfflineConnection redcapConnection
REDCap Data StructuresredcapDataStructures REDCAP_METADATA_FIELDTYPE REDCAP_METADATA_VALIDATION_TYPE REDCAP_PROJECT_PURPOSE REDCAP_REPEAT_INSTRUMENT_STRUCTURE REDCAP_SYSTEM_FIELDS validateRedcapData
Convert REDCap factors between labeled and codedredcapFactorFlip
Export or Import Repeating Instrument and Events SettingsexportRepeatingInstrumentsEvents exportRepeatingInstrumentsEvents.redcapApiConnection importRepeatingInstrumentsEvents importRepeatingInstrumentsEvents.redcapApiConnection repeatingInstrumentEventMethods repeatingInstrumentMethods
Review Invalid Records Following Field ValidationreviewInvalidRecords
Split a Data Frame into its FormssplitForms
Remove Undesired Characters From StringsstringCleanup stripHTMLTags stripUnicode
Helper Functions for 'exportRecordsType' AttributesstripHTMLandUnicode unitsFieldAnnotation
Export Survey Participant InformationexportSurveyLink exportSurveyLink.redcapApiConnection exportSurveyParticipants exportSurveyParticipants.redcapApiConnection exportSurveyQueueLink exportSurveyQueueLink.redcapApiConnection exportSurveyReturnCode exportSurveyReturnCode.redcapApiConnection surveyMethods
Switch Data Access Group Assignment for the Current UserswitchDag switchDag.redcapApiConnection switchDagArgs
Synchronize coding of checkbox variables between meta data and records field names.syncUnderscoreCodings
Open REDCap connections using cryptolocker for storage of API_KEYs.unlockREDCap
Export, Import, or Delete Users and User PermissisonsdeleteUsers deleteUsers.redcapApiConnection exportUsers exportUsers.redcapApiConnection importUsers importUsers.redcapApiConnection userMethods
Export or Import User-Role AssignmentsexportUserRoleAssignments exportUserRoleAssignments.redcapApiConnection importUserRoleAssignments importUserRoleAssignments.redcapApiConnection userRoleAssignmentMethods
Export, Import, or Delete User Roles in a ProjectdeleteUserRoles deleteUserRoles.redcapApiConnection exportUserRoles exportUserRoles.redcapApiConnection importUserRoles importUserRoles.redcapApiConnection userRoleMethods
Validate Data Frames for ImportvalidateImport
Convert R Vector To List for the API Call BodyvectorToApiBodyList
Transform Data Into Wide FormatwiderRepeated
Prepare a Data Frame for Import Through the APIwriteDataForImport