mirror of
https://github.com/agdamsbo/REDCapCAST.git
synced 2024-11-21 13:00:23 +01:00
191 lines
17 KiB
HTML
191 lines
17 KiB
HTML
<!DOCTYPE html>
|
|
<!-- Generated by pkgdown: do not edit by hand --><html lang="en">
|
|
<head>
|
|
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
|
<meta charset="utf-8">
|
|
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
|
<title>REDCap Castellated Data Handling And Metadata Casting • REDCapCAST</title>
|
|
<!-- favicons --><link rel="icon" type="image/png" sizes="16x16" href="favicon-16x16.png">
|
|
<link rel="icon" type="image/png" sizes="32x32" href="favicon-32x32.png">
|
|
<link rel="apple-touch-icon" type="image/png" sizes="180x180" href="apple-touch-icon.png">
|
|
<link rel="apple-touch-icon" type="image/png" sizes="120x120" href="apple-touch-icon-120x120.png">
|
|
<link rel="apple-touch-icon" type="image/png" sizes="76x76" href="apple-touch-icon-76x76.png">
|
|
<link rel="apple-touch-icon" type="image/png" sizes="60x60" href="apple-touch-icon-60x60.png">
|
|
<script src="deps/jquery-3.6.0/jquery-3.6.0.min.js"></script><meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
|
<link href="deps/bootstrap-5.3.1/bootstrap.min.css" rel="stylesheet">
|
|
<script src="deps/bootstrap-5.3.1/bootstrap.bundle.min.js"></script><link href="deps/font-awesome-6.4.2/css/all.min.css" rel="stylesheet">
|
|
<link href="deps/font-awesome-6.4.2/css/v4-shims.min.css" rel="stylesheet">
|
|
<script src="deps/headroom-0.11.0/headroom.min.js"></script><script src="deps/headroom-0.11.0/jQuery.headroom.min.js"></script><script src="deps/bootstrap-toc-1.0.1/bootstrap-toc.min.js"></script><script src="deps/clipboard.js-2.0.11/clipboard.min.js"></script><script src="deps/search-1.0.0/autocomplete.jquery.min.js"></script><script src="deps/search-1.0.0/fuse.min.js"></script><script src="deps/search-1.0.0/mark.min.js"></script><!-- pkgdown --><script src="pkgdown.js"></script><meta property="og:title" content="REDCap Castellated Data Handling And Metadata Casting">
|
|
<meta name="description" content="Originally forked from the R part of REDCapRITS by Paul Egeler. See <https://github.com/pegeler/REDCapRITS>. REDCap database casting and handling of castellated data when using repeated instruments and longitudinal projects. Keeps a focused data export approach, by allowing to only export required data from the database. Also for casting new REDCap databases based on datasets from other sources. REDCap (Research Electronic Data Capture) is a secure, web-based software platform designed to support data capture for research studies, providing 1) an intuitive interface for validated data capture; 2) audit trails for tracking data manipulation and export procedures; 3) automated export procedures for seamless data downloads to common statistical packages; and 4) procedures for data integration and interoperability with external sources (Harris et al (2009) <doi:10.1016/j.jbi.2008.08.010>; Harris et al (2019) <doi:10.1016/j.jbi.2019.103208>).">
|
|
<meta property="og:description" content="Originally forked from the R part of REDCapRITS by Paul Egeler. See <https://github.com/pegeler/REDCapRITS>. REDCap database casting and handling of castellated data when using repeated instruments and longitudinal projects. Keeps a focused data export approach, by allowing to only export required data from the database. Also for casting new REDCap databases based on datasets from other sources. REDCap (Research Electronic Data Capture) is a secure, web-based software platform designed to support data capture for research studies, providing 1) an intuitive interface for validated data capture; 2) audit trails for tracking data manipulation and export procedures; 3) automated export procedures for seamless data downloads to common statistical packages; and 4) procedures for data integration and interoperability with external sources (Harris et al (2009) <doi:10.1016/j.jbi.2008.08.010>; Harris et al (2019) <doi:10.1016/j.jbi.2019.103208>).">
|
|
<meta property="og:image" content="https://agdamsbo.github.io/REDCapCAST/logo.png">
|
|
</head>
|
|
<body>
|
|
<a href="#main" class="visually-hidden-focusable">Skip to contents</a>
|
|
|
|
|
|
<nav class="navbar navbar-expand-lg fixed-top bg-light" data-bs-theme="light" aria-label="Site navigation"><div class="container">
|
|
|
|
<a class="navbar-brand me-2" href="index.html">REDCapCAST</a>
|
|
|
|
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">24.11.1</small>
|
|
|
|
|
|
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">
|
|
<span class="navbar-toggler-icon"></span>
|
|
</button>
|
|
|
|
<div id="navbar" class="collapse navbar-collapse ms-3">
|
|
<ul class="navbar-nav me-auto">
|
|
<li class="nav-item"><a class="nav-link" href="reference/index.html">Reference</a></li>
|
|
<li class="nav-item dropdown">
|
|
<button class="nav-link dropdown-toggle" type="button" id="dropdown-articles" data-bs-toggle="dropdown" aria-expanded="false" aria-haspopup="true">Articles</button>
|
|
<ul class="dropdown-menu" aria-labelledby="dropdown-articles">
|
|
<li><a class="dropdown-item" href="articles/Database-creation.html">Database-creation</a></li>
|
|
<li><a class="dropdown-item" href="articles/Introduction.html">Introduction</a></li>
|
|
<li><a class="dropdown-item" href="articles/Shiny-app.html">Shiny-app</a></li>
|
|
</ul>
|
|
</li>
|
|
<li class="nav-item"><a class="nav-link" href="news/index.html">Changelog</a></li>
|
|
</ul>
|
|
<ul class="navbar-nav">
|
|
<li class="nav-item"><form class="form-inline" role="search">
|
|
<input class="form-control" type="search" name="search-input" id="search-input" autocomplete="off" aria-label="Search site" placeholder="Search for" data-search-index="search.json">
|
|
</form></li>
|
|
<li class="nav-item"><a class="external-link nav-link" href="https://github.com/agdamsbo/REDCapCAST/" aria-label="GitHub"><span class="fa fab fa-github fa-lg"></span></a></li>
|
|
</ul>
|
|
</div>
|
|
|
|
|
|
</div>
|
|
</nav><div class="container template-home">
|
|
<div class="row">
|
|
<main id="main" class="col-md-9">
|
|
<div class="section level1">
|
|
<div class="page-header">
|
|
<img src="logo.png" class="logo" alt=""><h1 id="redcapcast-package-">REDCapCAST package <a class="anchor" aria-label="anchor" href="#redcapcast-package-"></a>
|
|
</h1>
|
|
</div>
|
|
<p>REDCap database casting and handling of castellated data when using repeated instruments and longitudinal projects.</p>
|
|
<p>This package is a fork of <a href="https://github.com/pegeler/REDCapRITS" class="external-link">pegeler/REDCapRITS</a>. The <code>REDCapRITS</code> represents great and extensive work to handle castellated REDCap data in different programming languages. This fork is purely minded on R usage and includes a few implementations of the main <code>REDCap_split</code> function. The <code>REDCapRITS</code> as well as <code>REDCapCAST</code> would not be possible without the outstanding work in <a href="https://ouhscbbmc.github.io/REDCapR/" class="external-link"><code>REDCapR</code></a>.</p>
|
|
<div class="section level2">
|
|
<h2 id="what-problem-does-redcapcast-solve">What problem does <code>REDCapCAST</code> solve?<a class="anchor" aria-label="anchor" href="#what-problem-does-redcapcast-solve"></a>
|
|
</h2>
|
|
<p>I started working on this project as the castellated longitudinal data set was a little challenging. Later, I have come to learn of the <a href="https://github.com/vubiostat/redcapAPI" class="external-link"><code>redcapAPI</code></a> package, which would also cover this functionality. I find the <code>redcapAPI</code>package quite advanced and a little difficult to work with. This have led to the continued work on this package, as an easy-to-use approach for data migration, data base creation and data handling. This package is very much to be seen as an attempt at a R-to-REDCap-to-R foundry for handling both the transition from dataset/variable list to database and the other way, from REDCap database to a tidy dataset. The goal was also to allow for a “minimal data” approach by allowing to filter records, instruments and variables in the export to only download data needed. I think this approach is desirable for handling sensitive, clinical data. Please refer to <a href="https://redcap-tools.github.io/" class="external-link">REDCap-Tools</a> for other great tools for working with REDCap in R.</p>
|
|
<p>For any more advanced uses, consider using the <a href="https://github.com/vubiostat/redcapAPI" class="external-link"><code>redcapAPI</code></a> or <a href="https://ouhscbbmc.github.io/REDCapR/" class="external-link"><code>REDCapR</code></a> packages.</p>
|
|
<p>What is unique in this package, is the work towards making it a lot easier to move data from different sources to REDCap databases: casting REDCap metadata based on a spreadsheet. This is all wrapped in <code><a href="reference/shiny_cast.html">shiny_cast()</a></code>and <a href="https://agdamsbo.shinyapps.io/redcapcast/" class="external-link">hosted for all to use here</a>.</p>
|
|
</div>
|
|
<div class="section level2">
|
|
<h2 id="main-functionality">Main functionality<a class="anchor" aria-label="anchor" href="#main-functionality"></a>
|
|
</h2>
|
|
<p>Here is just a short description of the main functions:</p>
|
|
<ul>
|
|
<li><p><code>REDcap_split()</code>: Works largely as the original <code>REDCapRITS::REDCap_split()</code>. It takes a REDCap dataset and metadata (data dictionary) to split the data set into a list of dataframes of instruments.</p></li>
|
|
<li><p><code><a href="reference/read_redcap_tables.html">read_redcap_tables()</a></code>: wraps the use of <a href="https://github.com/OuhscBbmc/REDCapR" class="external-link"><code>REDCapR::redcap_read()</code></a> with <code><a href="reference/REDCap_split.html">REDCap_split()</a></code> to ease the export of REDCap data. Default output is a list of data frames with one data frame for each REDCap instrument.</p></li>
|
|
<li><p><code><a href="reference/redcap_wider.html">redcap_wider()</a></code>: joins and pivots a list of data frames with repeated instruments to a wide format utilizing the <a href="https://tidyr.tidyverse.org/reference/pivot_wider.html" class="external-link"><code>tidyr::pivot_wider()</code></a> from the <a href="https://www.tidyverse.org/" class="external-link">tidyverse</a>.</p></li>
|
|
<li><p><code><a href="reference/easy_redcap.html">easy_redcap()</a></code>: combines secure API key storage with the <code>keyring</code>-package, focused data retrieval and optional widening. This is the recommended approach for easy data access and analysis.</p></li>
|
|
<li><p><code><a href="reference/ds2dd_detailed.html">ds2dd_detailed()</a></code>: Converts a data set to a data dictionary for upload to a new REDCap database. Variables (fields) and instruments in a REDCap data base are defined by this data dictionary.</p></li>
|
|
<li><p><code><a href="reference/doc2dd.html">doc2dd()</a></code>: Converts a document table to data dictionary. This allows to specify instrument or whole data dictionary in text document, which for most is easier to work with and easily modifiable. Very much like a easy version of just working directly in the data dictionary file itself.</p></li>
|
|
<li><p><code><a href="reference/shiny_cast.html">shiny_cast()</a></code>: <a href="https://shiny.posit.co/" class="external-link">Shiny</a> application to ease the process of converting a spreadsheet/data set to a REDCap database. The app runs locally and data is transferred securely. You can just create and upload the data dictionary, but you can also transfer the given data in the same process. The app is <a href="https://agdamsbo.shinyapps.io/redcapcast/" class="external-link">hosted on shinyapps.io</a>.</p></li>
|
|
</ul>
|
|
</div>
|
|
<div class="section level2">
|
|
<h2 id="future">Future<a class="anchor" aria-label="anchor" href="#future"></a>
|
|
</h2>
|
|
<p>The plan with this package is to be bundled with a Handbook on working with REDCap from R. This work is in progress but is limited by the time available. Please feel free to contact me or create and issue with ideas for future additions.</p>
|
|
</div>
|
|
<div class="section level2">
|
|
<h2 id="installation">Installation<a class="anchor" aria-label="anchor" href="#installation"></a>
|
|
</h2>
|
|
<p>The package is available on CRAN. Install the latest version:</p>
|
|
<pre><code><span><span class="fu"><a href="https://rdrr.io/r/utils/install.packages.html" class="external-link">install.packages</a></span><span class="op">(</span><span class="st">"REDCapCAST"</span><span class="op">)</span></span></code></pre>
|
|
<p>Install the latest version directly from GitHub:</p>
|
|
<pre><code><span><span class="kw"><a href="https://rdrr.io/r/base/library.html" class="external-link">require</a></span><span class="op">(</span><span class="st"><a href="https://remotes.r-lib.org" class="external-link">"remotes"</a></span><span class="op">)</span></span>
|
|
<span><span class="fu">remotes</span><span class="fu">::</span><span class="fu"><a href="https://remotes.r-lib.org/reference/install_github.html" class="external-link">install_github</a></span><span class="op">(</span><span class="st">"agdamsbo/REDCapCAST"</span><span class="op">)</span></span></code></pre>
|
|
<p>Launch the REDCapCAST app interface directly on your own machine:</p>
|
|
<pre><code><span><span class="fu">REDCapCAST</span><span class="fu">::</span><span class="fu"><a href="reference/shiny_cast.html">shiny_cast</a></span><span class="op">(</span><span class="op">)</span></span></code></pre>
|
|
</div>
|
|
<div class="section level2">
|
|
<h2 id="code-of-conduct">Code of Conduct<a class="anchor" aria-label="anchor" href="#code-of-conduct"></a>
|
|
</h2>
|
|
<p>Please note that the REDCapCAST project is released with a <a href="https://agdamsbo.github.io/REDCapCAST/CODE_OF_CONDUCT.html">Contributor Code of Conduct</a>. By contributing to this project, you agree to abide by its terms.</p>
|
|
</div>
|
|
</div>
|
|
|
|
</main><aside class="col-md-3"><div class="links">
|
|
<h2 data-toc-skip>Links</h2>
|
|
<ul class="list-unstyled">
|
|
<li><a href="https://cloud.r-project.org/package=REDCapCAST" class="external-link">View on CRAN</a></li>
|
|
<li><a href="https://github.com/agdamsbo/REDCapCAST/" class="external-link">Browse source code</a></li>
|
|
<li><a href="https://github.com/agdamsbo/REDCapCAST/issues" class="external-link">Report a bug</a></li>
|
|
</ul>
|
|
</div>
|
|
|
|
<div class="license">
|
|
<h2 data-toc-skip>License</h2>
|
|
<ul class="list-unstyled">
|
|
<li><a href="LICENSE.html">Full license</a></li>
|
|
<li><small>GPL (>= 3)</small></li>
|
|
</ul>
|
|
</div>
|
|
|
|
<div class="community">
|
|
<h2 data-toc-skip>Community</h2>
|
|
<ul class="list-unstyled">
|
|
<li><a href="CODE_OF_CONDUCT.html">Code of conduct</a></li>
|
|
</ul>
|
|
</div>
|
|
|
|
<div class="citation">
|
|
<h2 data-toc-skip>Citation</h2>
|
|
<ul class="list-unstyled">
|
|
<li><a href="authors.html#citation">Citing REDCapCAST</a></li>
|
|
</ul>
|
|
</div>
|
|
|
|
<div class="developers">
|
|
<h2 data-toc-skip>Developers</h2>
|
|
<ul class="list-unstyled">
|
|
<li>Andreas Gammelgaard Damsbo <br><small class="roles"> Author, maintainer </small> <a href="https://orcid.org/0000-0002-7559-1154" target="orcid.widget" aria-label="ORCID" class="external-link"><span class="fab fa-orcid orcid" aria-hidden="true"></span></a> </li>
|
|
<li>Paul Egeler <br><small class="roles"> Author </small> <a href="https://orcid.org/0000-0001-6948-9498" target="orcid.widget" aria-label="ORCID" class="external-link"><span class="fab fa-orcid orcid" aria-hidden="true"></span></a> </li>
|
|
</ul>
|
|
</div>
|
|
|
|
<div class="dev-status">
|
|
<h2 data-toc-skip>Dev status</h2>
|
|
<ul class="list-unstyled">
|
|
<li><a href="https://github.com/agdamsbo/REDCapCAST" class="external-link"><img src="https://img.shields.io/github/r-package/v/agdamsbo/REDCapCAST" alt="GitHub R package version"></a></li>
|
|
<li><a href="https://CRAN.R-project.org/package=REDCapCAST" class="external-link"><img src="https://img.shields.io/cran/v/REDCapCAST" alt="CRAN/METACRAN"></a></li>
|
|
<li><a href="https://doi.org/10.5281/zenodo.8013984" class="external-link"><img src="https://zenodo.org/badge/DOI/10.5281/zenodo.8013984.svg" alt="DOI"></a></li>
|
|
<li><a href="https://github.com/agdamsbo/REDCapCAST/actions/workflows/rhub.yaml" class="external-link"><img src="https://github.com/agdamsbo/REDCapCAST/actions/workflows/rhub.yaml/badge.svg" alt="R-hub"></a></li>
|
|
<li><a href="https://github.com/agdamsbo/REDCapCAST/actions/workflows/R-CMD-check.yaml" class="external-link"><img src="https://github.com/agdamsbo/REDCapCAST/actions/workflows/R-CMD-check.yaml/badge.svg" alt="R-CMD-check"></a></li>
|
|
<li><a href="https://github.com/agdamsbo/REDCapCAST/actions/workflows/pages/pages-build-deployment" class="external-link"><img src="https://github.com/agdamsbo/REDCapCAST/actions/workflows/pages/pages-build-deployment/badge.svg" alt="Page deployed"></a></li>
|
|
<li><a href="https://app.codecov.io/gh/agdamsbo/REDCapCAST?branch=master" class="external-link"><img src="https://codecov.io/gh/agdamsbo/REDCapCAST/branch/master/graph/badge.svg" alt="Codecov test coverage"></a></li>
|
|
<li><a href="https://cran.r-project.org/package=REDCapCAST" class="external-link"><img src="https://cranlogs.r-pkg.org/badges/grand-total/REDCapCAST" alt="CRAN downloads"></a></li>
|
|
<li><a href="https://lifecycle.r-lib.org/articles/stages.html" class="external-link"><img src="https://img.shields.io/badge/lifecycle-experimental-orange.svg" alt="Lifecycle: experimental"></a></li>
|
|
</ul>
|
|
</div>
|
|
|
|
</aside>
|
|
</div>
|
|
|
|
|
|
<footer><div class="pkgdown-footer-left">
|
|
<p>Developed by Andreas Gammelgaard Damsbo, Paul Egeler.</p>
|
|
</div>
|
|
|
|
<div class="pkgdown-footer-right">
|
|
<p>Site built with <a href="https://pkgdown.r-lib.org/" class="external-link">pkgdown</a> 2.1.1.</p>
|
|
</div>
|
|
|
|
</footer>
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
</body>
|
|
</html>
|