From 6f2cb827b2ac8627926b4f6a23120304b0897229 Mon Sep 17 00:00:00 2001 From: Jennifer Thom Date: Tue, 26 Sep 2023 12:42:02 +0100 Subject: [PATCH] update documentation --- NAMESPACE | 1 - man/add_nsu_cohort.Rd | 3 ++- man/add_ppa_flag.Rd | 3 ++- man/apply_cost_uplift.Rd | 3 ++- man/correct_cij_vars.Rd | 11 +++----- man/create_cohort_lookups.Rd | 11 +++----- man/create_cost_inc_dna.Rd | 11 +++----- man/create_episode_file.Rd | 16 +++++++++++ man/fill_missing_cij_markers.Rd | 11 +++----- man/join_cohort_lookups.Rd | 34 +++++++++++++++++------ man/link_delayed_discharge_eps.Rd | 3 ++- man/load_ep_file_vars.Rd | 11 +++----- man/lookup_uplift.Rd | 3 ++- man/run_episode_file.Rd | 45 ------------------------------- man/store_ep_file_vars.Rd | 13 +++------ 15 files changed, 71 insertions(+), 108 deletions(-) delete mode 100644 man/run_episode_file.Rd diff --git a/NAMESPACE b/NAMESPACE index 3e631047f..b5436d21e 100644 --- a/NAMESPACE +++ b/NAMESPACE @@ -156,7 +156,6 @@ export(read_sc_all_alarms_telecare) export(read_sc_all_care_home) export(read_sc_all_home_care) export(read_sc_all_sds) -export(run_episode_file) export(setup_keyring) export(start_fy) export(start_fy_quarter) diff --git a/man/add_nsu_cohort.Rd b/man/add_nsu_cohort.Rd index 0673c3bf3..43118a087 100644 --- a/man/add_nsu_cohort.Rd +++ b/man/add_nsu_cohort.Rd @@ -28,11 +28,12 @@ Other episode_file: \code{\link{correct_cij_vars}()}, \code{\link{create_cohort_lookups}()}, \code{\link{create_cost_inc_dna}()}, +\code{\link{create_episode_file}()}, \code{\link{fill_missing_cij_markers}()}, +\code{\link{join_cohort_lookups}()}, \code{\link{link_delayed_discharge_eps}()}, \code{\link{load_ep_file_vars}()}, \code{\link{lookup_uplift}()}, -\code{\link{run_episode_file}()}, \code{\link{store_ep_file_vars}()} } \concept{episode_file} diff --git a/man/add_ppa_flag.Rd b/man/add_ppa_flag.Rd index a067188b6..f19f81009 100644 --- a/man/add_ppa_flag.Rd +++ b/man/add_ppa_flag.Rd @@ -24,11 +24,12 @@ Other episode_file: \code{\link{correct_cij_vars}()}, \code{\link{create_cohort_lookups}()}, \code{\link{create_cost_inc_dna}()}, +\code{\link{create_episode_file}()}, \code{\link{fill_missing_cij_markers}()}, +\code{\link{join_cohort_lookups}()}, \code{\link{link_delayed_discharge_eps}()}, \code{\link{load_ep_file_vars}()}, \code{\link{lookup_uplift}()}, -\code{\link{run_episode_file}()}, \code{\link{store_ep_file_vars}()} } \concept{episode_file} diff --git a/man/apply_cost_uplift.Rd b/man/apply_cost_uplift.Rd index 2802eb8b2..5461d15be 100644 --- a/man/apply_cost_uplift.Rd +++ b/man/apply_cost_uplift.Rd @@ -22,11 +22,12 @@ Other episode_file: \code{\link{correct_cij_vars}()}, \code{\link{create_cohort_lookups}()}, \code{\link{create_cost_inc_dna}()}, +\code{\link{create_episode_file}()}, \code{\link{fill_missing_cij_markers}()}, +\code{\link{join_cohort_lookups}()}, \code{\link{link_delayed_discharge_eps}()}, \code{\link{load_ep_file_vars}()}, \code{\link{lookup_uplift}()}, -\code{\link{run_episode_file}()}, \code{\link{store_ep_file_vars}()} } \concept{episode_file} diff --git a/man/correct_cij_vars.Rd b/man/correct_cij_vars.Rd index be6c550e5..5fd265d22 100644 --- a/man/correct_cij_vars.Rd +++ b/man/correct_cij_vars.Rd @@ -1,24 +1,18 @@ % Generated by roxygen2: do not edit by hand -% Please edit documentation in R/create_episode_file.R, R/run_episode_file.R +% Please edit documentation in R/create_episode_file.R \name{correct_cij_vars} \alias{correct_cij_vars} \title{Correct the CIJ variables} \usage{ -correct_cij_vars(data) - correct_cij_vars(data) } \arguments{ \item{data}{The in-progress episode file data.} } \value{ -The data with CIJ variables corrected. - The data with CIJ variables corrected. } \description{ -Correct the CIJ variables - Correct the CIJ variables } \seealso{ @@ -28,11 +22,12 @@ Other episode_file: \code{\link{apply_cost_uplift}()}, \code{\link{create_cohort_lookups}()}, \code{\link{create_cost_inc_dna}()}, +\code{\link{create_episode_file}()}, \code{\link{fill_missing_cij_markers}()}, +\code{\link{join_cohort_lookups}()}, \code{\link{link_delayed_discharge_eps}()}, \code{\link{load_ep_file_vars}()}, \code{\link{lookup_uplift}()}, -\code{\link{run_episode_file}()}, \code{\link{store_ep_file_vars}()} } \concept{episode_file} diff --git a/man/create_cohort_lookups.Rd b/man/create_cohort_lookups.Rd index 1e9ac5b13..934354375 100644 --- a/man/create_cohort_lookups.Rd +++ b/man/create_cohort_lookups.Rd @@ -1,11 +1,9 @@ % Generated by roxygen2: do not edit by hand -% Please edit documentation in R/create_episode_file.R, R/run_episode_file.R +% Please edit documentation in R/create_episode_file.R \name{create_cohort_lookups} \alias{create_cohort_lookups} \title{Create the cohort lookups} \usage{ -create_cohort_lookups(data, year, update = latest_update()) - create_cohort_lookups(data, year, update = latest_update()) } \arguments{ @@ -16,13 +14,9 @@ create_cohort_lookups(data, year, update = latest_update()) \item{update}{The update to use.} } \value{ -The data unchanged (the cohorts are written to disk) - The data unchanged (the cohorts are written to disk) } \description{ -Create the cohort lookups - Create the cohort lookups } \seealso{ @@ -32,11 +26,12 @@ Other episode_file: \code{\link{apply_cost_uplift}()}, \code{\link{correct_cij_vars}()}, \code{\link{create_cost_inc_dna}()}, +\code{\link{create_episode_file}()}, \code{\link{fill_missing_cij_markers}()}, +\code{\link{join_cohort_lookups}()}, \code{\link{link_delayed_discharge_eps}()}, \code{\link{load_ep_file_vars}()}, \code{\link{lookup_uplift}()}, -\code{\link{run_episode_file}()}, \code{\link{store_ep_file_vars}()} } \concept{episode_file} diff --git a/man/create_cost_inc_dna.Rd b/man/create_cost_inc_dna.Rd index 304079bd4..d78e9c907 100644 --- a/man/create_cost_inc_dna.Rd +++ b/man/create_cost_inc_dna.Rd @@ -1,24 +1,18 @@ % Generated by roxygen2: do not edit by hand -% Please edit documentation in R/create_episode_file.R, R/run_episode_file.R +% Please edit documentation in R/create_episode_file.R \name{create_cost_inc_dna} \alias{create_cost_inc_dna} \title{Create cost total net inc DNA} \usage{ -create_cost_inc_dna(data) - create_cost_inc_dna(data) } \arguments{ \item{data}{The in-progress episode file data.} } \value{ -The data with cost including dna. - The data with cost including dna. } \description{ -Create cost total net inc DNA - Create cost total net inc DNA } \seealso{ @@ -28,11 +22,12 @@ Other episode_file: \code{\link{apply_cost_uplift}()}, \code{\link{correct_cij_vars}()}, \code{\link{create_cohort_lookups}()}, +\code{\link{create_episode_file}()}, \code{\link{fill_missing_cij_markers}()}, +\code{\link{join_cohort_lookups}()}, \code{\link{link_delayed_discharge_eps}()}, \code{\link{load_ep_file_vars}()}, \code{\link{lookup_uplift}()}, -\code{\link{run_episode_file}()}, \code{\link{store_ep_file_vars}()} } \concept{episode_file} diff --git a/man/create_episode_file.Rd b/man/create_episode_file.Rd index c1ce0e063..3ce6c815d 100644 --- a/man/create_episode_file.Rd +++ b/man/create_episode_file.Rd @@ -47,3 +47,19 @@ a \link[tibble:tibble-package]{tibble} containing the episode file \description{ Produce the Source Episode file } +\seealso{ +Other episode_file: +\code{\link{add_nsu_cohort}()}, +\code{\link{add_ppa_flag}()}, +\code{\link{apply_cost_uplift}()}, +\code{\link{correct_cij_vars}()}, +\code{\link{create_cohort_lookups}()}, +\code{\link{create_cost_inc_dna}()}, +\code{\link{fill_missing_cij_markers}()}, +\code{\link{join_cohort_lookups}()}, +\code{\link{link_delayed_discharge_eps}()}, +\code{\link{load_ep_file_vars}()}, +\code{\link{lookup_uplift}()}, +\code{\link{store_ep_file_vars}()} +} +\concept{episode_file} diff --git a/man/fill_missing_cij_markers.Rd b/man/fill_missing_cij_markers.Rd index ce654495e..7918329a7 100644 --- a/man/fill_missing_cij_markers.Rd +++ b/man/fill_missing_cij_markers.Rd @@ -1,24 +1,18 @@ % Generated by roxygen2: do not edit by hand -% Please edit documentation in R/create_episode_file.R, R/run_episode_file.R +% Please edit documentation in R/create_episode_file.R \name{fill_missing_cij_markers} \alias{fill_missing_cij_markers} \title{Fill any missing CIJ markers for records that should have them} \usage{ -fill_missing_cij_markers(data) - fill_missing_cij_markers(data) } \arguments{ \item{data}{The in-progress episode file data.} } \value{ -A data frame with CIJ markers filled in for those missing. - A data frame with CIJ markers filled in for those missing. } \description{ -Fill any missing CIJ markers for records that should have them - Fill any missing CIJ markers for records that should have them } \seealso{ @@ -29,10 +23,11 @@ Other episode_file: \code{\link{correct_cij_vars}()}, \code{\link{create_cohort_lookups}()}, \code{\link{create_cost_inc_dna}()}, +\code{\link{create_episode_file}()}, +\code{\link{join_cohort_lookups}()}, \code{\link{link_delayed_discharge_eps}()}, \code{\link{load_ep_file_vars}()}, \code{\link{lookup_uplift}()}, -\code{\link{run_episode_file}()}, \code{\link{store_ep_file_vars}()} } \concept{episode_file} diff --git a/man/join_cohort_lookups.Rd b/man/join_cohort_lookups.Rd index e674396c6..142a2c1ee 100644 --- a/man/join_cohort_lookups.Rd +++ b/man/join_cohort_lookups.Rd @@ -1,12 +1,18 @@ % Generated by roxygen2: do not edit by hand -% Please edit documentation in R/create_episode_file.R, R/run_episode_file.R +% Please edit documentation in R/create_episode_file.R \name{join_cohort_lookups} \alias{join_cohort_lookups} \title{Join cohort lookups} \usage{ -join_cohort_lookups(data, year, update = latest_update()) - -join_cohort_lookups(data, year, update = latest_update()) +join_cohort_lookups( + data, + year, + update = latest_update(), + demographic_cohort = read_file(get_demographic_cohorts_path(year, update), col_select = + c("chi", "demographic_cohort")), + service_use_cohort = read_file(get_service_use_cohorts_path(year, update), col_select = + c("chi", "service_use_cohort")) +) } \arguments{ \item{data}{The in-progress episode file data.} @@ -18,12 +24,24 @@ join_cohort_lookups(data, year, update = latest_update()) \item{demographic_cohort, service_use_cohort}{The cohort data} } \value{ -The data including the Demographic and Service Use lookups. - The data including the Demographic and Service Use lookups. } \description{ Join cohort lookups - -Join cohort lookups } +\seealso{ +Other episode_file: +\code{\link{add_nsu_cohort}()}, +\code{\link{add_ppa_flag}()}, +\code{\link{apply_cost_uplift}()}, +\code{\link{correct_cij_vars}()}, +\code{\link{create_cohort_lookups}()}, +\code{\link{create_cost_inc_dna}()}, +\code{\link{create_episode_file}()}, +\code{\link{fill_missing_cij_markers}()}, +\code{\link{link_delayed_discharge_eps}()}, +\code{\link{load_ep_file_vars}()}, +\code{\link{lookup_uplift}()}, +\code{\link{store_ep_file_vars}()} +} +\concept{episode_file} diff --git a/man/link_delayed_discharge_eps.Rd b/man/link_delayed_discharge_eps.Rd index 9ae86688d..245fa2754 100644 --- a/man/link_delayed_discharge_eps.Rd +++ b/man/link_delayed_discharge_eps.Rd @@ -32,10 +32,11 @@ Other episode_file: \code{\link{correct_cij_vars}()}, \code{\link{create_cohort_lookups}()}, \code{\link{create_cost_inc_dna}()}, +\code{\link{create_episode_file}()}, \code{\link{fill_missing_cij_markers}()}, +\code{\link{join_cohort_lookups}()}, \code{\link{load_ep_file_vars}()}, \code{\link{lookup_uplift}()}, -\code{\link{run_episode_file}()}, \code{\link{store_ep_file_vars}()} } \concept{episode_file} diff --git a/man/load_ep_file_vars.Rd b/man/load_ep_file_vars.Rd index 393a9c415..965e8bfce 100644 --- a/man/load_ep_file_vars.Rd +++ b/man/load_ep_file_vars.Rd @@ -1,11 +1,9 @@ % Generated by roxygen2: do not edit by hand -% Please edit documentation in R/create_episode_file.R, R/run_episode_file.R +% Please edit documentation in R/create_episode_file.R \name{load_ep_file_vars} \alias{load_ep_file_vars} \title{Load the unneeded episode file variables} \usage{ -load_ep_file_vars(data, year) - load_ep_file_vars(data, year) } \arguments{ @@ -14,13 +12,9 @@ load_ep_file_vars(data, year) \item{year}{The year to process, in FY format.} } \value{ -The full SLF data. - The full SLF data. } \description{ -Load the unneeded episode file variables - Load the unneeded episode file variables } \seealso{ @@ -31,10 +25,11 @@ Other episode_file: \code{\link{correct_cij_vars}()}, \code{\link{create_cohort_lookups}()}, \code{\link{create_cost_inc_dna}()}, +\code{\link{create_episode_file}()}, \code{\link{fill_missing_cij_markers}()}, +\code{\link{join_cohort_lookups}()}, \code{\link{link_delayed_discharge_eps}()}, \code{\link{lookup_uplift}()}, -\code{\link{run_episode_file}()}, \code{\link{store_ep_file_vars}()} } \concept{episode_file} diff --git a/man/lookup_uplift.Rd b/man/lookup_uplift.Rd index a463aad3b..356a25d4a 100644 --- a/man/lookup_uplift.Rd +++ b/man/lookup_uplift.Rd @@ -23,10 +23,11 @@ Other episode_file: \code{\link{correct_cij_vars}()}, \code{\link{create_cohort_lookups}()}, \code{\link{create_cost_inc_dna}()}, +\code{\link{create_episode_file}()}, \code{\link{fill_missing_cij_markers}()}, +\code{\link{join_cohort_lookups}()}, \code{\link{link_delayed_discharge_eps}()}, \code{\link{load_ep_file_vars}()}, -\code{\link{run_episode_file}()}, \code{\link{store_ep_file_vars}()} } \concept{episode_file} diff --git a/man/run_episode_file.Rd b/man/run_episode_file.Rd deleted file mode 100644 index cd25908c4..000000000 --- a/man/run_episode_file.Rd +++ /dev/null @@ -1,45 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/run_episode_file.R -\name{run_episode_file} -\alias{run_episode_file} -\title{Produce the Source Episode file} -\usage{ -run_episode_file( - processed_data_list, - year, - write_to_disk = TRUE, - anon_chi_out = TRUE -) -} -\arguments{ -\item{processed_data_list}{containing data from processed extracts.} - -\item{year}{The year to process, in FY format.} - -\item{write_to_disk}{(optional) Should the data be written to disk default is -\code{TRUE} i.e. write the data to disk.} - -\item{anon_chi_out}{(Default:TRUE) Should \code{anon_chi} be used in the output -(instead of chi)} -} -\value{ -a \link[tibble:tibble-package]{tibble} containing the episode file -} -\description{ -Produce the Source Episode file -} -\seealso{ -Other episode_file: -\code{\link{add_nsu_cohort}()}, -\code{\link{add_ppa_flag}()}, -\code{\link{apply_cost_uplift}()}, -\code{\link{correct_cij_vars}()}, -\code{\link{create_cohort_lookups}()}, -\code{\link{create_cost_inc_dna}()}, -\code{\link{fill_missing_cij_markers}()}, -\code{\link{link_delayed_discharge_eps}()}, -\code{\link{load_ep_file_vars}()}, -\code{\link{lookup_uplift}()}, -\code{\link{store_ep_file_vars}()} -} -\concept{episode_file} diff --git a/man/store_ep_file_vars.Rd b/man/store_ep_file_vars.Rd index cab617713..687bdcecb 100644 --- a/man/store_ep_file_vars.Rd +++ b/man/store_ep_file_vars.Rd @@ -1,11 +1,9 @@ % Generated by roxygen2: do not edit by hand -% Please edit documentation in R/create_episode_file.R, R/run_episode_file.R +% Please edit documentation in R/create_episode_file.R \name{store_ep_file_vars} \alias{store_ep_file_vars} \title{Store the unneeded episode file variables} \usage{ -store_ep_file_vars(data, year, vars_to_keep) - store_ep_file_vars(data, year, vars_to_keep) } \arguments{ @@ -17,13 +15,9 @@ store_ep_file_vars(data, year, vars_to_keep) will be stored.} } \value{ -\code{data} with only the \code{vars_to_keep} kept - \code{data} with only the \code{vars_to_keep} kept } \description{ -Store the unneeded episode file variables - Store the unneeded episode file variables } \seealso{ @@ -34,10 +28,11 @@ Other episode_file: \code{\link{correct_cij_vars}()}, \code{\link{create_cohort_lookups}()}, \code{\link{create_cost_inc_dna}()}, +\code{\link{create_episode_file}()}, \code{\link{fill_missing_cij_markers}()}, +\code{\link{join_cohort_lookups}()}, \code{\link{link_delayed_discharge_eps}()}, \code{\link{load_ep_file_vars}()}, -\code{\link{lookup_uplift}()}, -\code{\link{run_episode_file}()} +\code{\link{lookup_uplift}()} } \concept{episode_file}