# Source file: objects.R
#
# MIT License
#
# Copyright (c) 2019 Victor Ordu
#' Builtin Objects For JHPIEGO GBV Projects
#'
#' @rdname jgbv-objects
#'
#' @export
raampStates <- c("Abia", "Akwa Ibom", "Ogun", "Bauchi")
#' @rdname jgbv-objects
#'
#' @export
tool.sectors <-
structure(
sectors <- c(
"Health",
"Judicial",
"Legal",
"Referral",
"Security",
"Social",
"Temporary"
),
names = tolower(sectors),
class = "Tools"
)
#' Print Out The Tools Object
#'
#' Print the \code{tool.sectors} object in an easy to read format.
#'
#' @param x A \code{Tools} object
#' @param ... Additional arguments passed on to \code{print.default}
#'
#' @export
print.Tools <- function(x, ...) {
print(unclass(unname(x)), ...)
}
#' @rdname jgbv-objects
#'
#' @note \code{new.varnames} is a named vector of new variable names that will
#' be applied to the imported raw data. It is named to allow for indexing.
#' These names are equally used in the database, so the actual values are SQL
#' compliant, while the names are more R-focused.
#'
#' Not all the values are necessarily named; just those that are actually
#' in use at the project level. The unnamed ones are usually extracted using
#' regular expressions, especially for multi-response questions.
#'
#' @export
new.varnames <- c(
start = "int_start",
end = "int_end",
today = "today",
"username",
"simserial",
device.id = "device_id",
phonenum = "phonenumber",
"prelim_guid",
gps.loc = "gps_loc",
gps.lat = "gps_lat",
gps.long = "gps_long",
gps.alt = "gps_alt",
gps.prec = "gps_prec",
has.office = "has_office",
has.phone = "has_phone",
"only_basic_info",
continue = "continue_mapping",
"get_consent",
consent = "respondent_consent",
"reason_no_consent",
orgname = "org_name",
state = "stateorigin",
lga = "LGA",
ward = "ward",
address = "address",
phone = "org_phone",
email = "org_email",
interviewer = "interviewer_name",
interviewer.contact = "interviewer_contact",
"wb_proj_list",
proj.name = "wb_proj_name",
org.type = "org_type",
govt.spec = "govt_spec",
oth.org.type = "other_org_type",
opstart = "started_ops",
gbvstart = "started_gbv",
"funding",
"funding_nig_govt",
"funding_foreign_govt",
"funding_intl_org",
"funding_pvt_donor",
"funding_fees",
"funding_other",
oth.fund.dscrb = "describe_other_funding",
fulltime.staff = "num_fulltime",
partime.staff = "num_parttime",
female.staff = "num_female",
age = "age_grp_served",
"openday",
"openday_sun",
"openday_mon",
"openday_tue",
"openday_wed",
"openday_thu",
"openday_fri",
"openday_sat",
open.247 = "open_247",
open.time = "open_time",
close.time = "close_time",
info = "respondent_info",
staffname = "respondent_names",
title = "respondent_title",
"gbvaddr",
"gbvaddr_sexviol",
"gbvaddr_physasslt",
"gbvaddr_ipv",
"gbvaddr_csa",
"gbvaddr_earlymar",
"gbvaddr_earlypreg",
"gbvaddr_fgm",
"gbvaddr_other",
oth.gbv.dscrb = "describe_other_gbv",
"doc_sight",
uses.docs = "doc_areused",
showed.docs = "doc_showable",
doc.photo = "doc_photo",
"docused",
"docused_sexviol",
"docused_ipv",
"docused_earlymar",
"docused_earlypreg",
"docused_fgm",
"docused_other",
oth.docs.dscrb = "describe_other_docused",
process.nodoc = "nodoc_process",
child.docs = "docs_child",
standard.forms = "standard_forms",
how.data = "data_storage",
data.is.stored = "secure_physical",
computer.secured = "secure_computer",
choose.treatment = "choice_treat",
contact.authority = "contact_auth",
why.contact = "contact_whysome",
contact.case = "contact_casetyp",
contact.authtype = "contact_authtyp",
priv = "privacy",
priv.room = "private_room",
private.ques = "private_questions",
"facmiss",
"facmiss_staff",
"facmiss_cap",
"facmiss_equip",
"facmiss_space",
"facmiss_other",
"facmiss_nothing",
no.equipment = "missing_equip",
details.miss.equip = "describe_other_facmiss",
serve.disabled = "disabled_srv",
disabled.special = "disabled_spec",
oth.disabl.dscrb = "describe_other_disabled",
coc.signed = "coc_signed",
coc.copies = "coc_copy",
coc.photo = "coc_pic",
coc.confidentiality = "coc_conf",
coc.equity = "coc_equity",
has.focalperson = "gbv_focal",
focalperson.contact = "fp_contact",
has.gbv.trained = "gbvtrain",
num.gbv.trained = "gbvtrain_num",
which.gbv.trained = "gbvtrain_which",
who.gbv.trained = "gbvtrain_who",
has.refdir = "refdir",
refdir.pic = "refdir_pic",
"refto",
refto.health = "refto_health",
refto.psych = "refto_psych",
refto.police = "refto_police",
refto.legal = "refto_legal",
refto.shelt = "refto_shelt",
refto.econ = "refto_econ",
refto.other = "refto_other",
oth.refto.dscrb = "describe_other_refto",
update.refdir = "refdir_update",
gbvcase.contact = "gbvcase_contact",
choose.referral = "choice_ref",
why.nochoose.ref = "choice_ref_whynot",
coordination = "coord",
which.coord = "coord_which",
comment.coord = "coord_comments",
service.types = "srvtype",
service.health = "srvtype_health",
service.legal = "srvtype_legal",
service.psychosocial = "srvtype_psych",
service.police = "srvtype_police",
service.shelter = "srvtype_shelt",
service.economic = "srvtype_econ",
service.others = "srvtype_other",
service.othersdetail = "describe_other_srvtype",
hf.type = "hf_type",
hf.type.others = "hf_other",
"srvhealth",
"srvhealth_clinrape",
"srvhealth_injuries",
"srvhealth_pep",
"srvhealth_contra",
"srvhealth_hiv",
"srvhealth_sti",
"srvhealth_foren",
"srvhealth_psycho",
"srvhealth_case",
"srvhealth_basic",
"srvhealth_other",
oth.srvhealth.dscrb = "describe_other_srvhealth",
total.health = "health_num",
has.pep = "pep_72hr",
has.no.pep = "pep_72hr_not",
has.contracep = "contra_120",
has.no.contracep = "contra_120_not",
health.paid = "health_fees",
access.srv = "srv_access",
healthfee.clin = "healthfee_clin",
healthfee.inj = "healthfee_inj",
healthfee.pep = "healthfee_pep",
healthfee.contra = "healthfee_contra",
healthfee.hiv = "healthfee_hiv",
healthfee.sti = "healthfee_sti",
healthfee.foren = "healthfee_foren",
healthfee.psych = "healthfee_psych",
healthfee.case = "healthfee_case",
healthfee.basic = "healthfee_basic",
healthfee.other = "healthfee_other",
forms.yes = "forms_yes",
"formtyp",
"formtyp_foren",
"formtyp_consentrape",
"formtyp_consenthiv",
"formtyp_safety",
"formtyp_patient",
"elem",
"elem_consroom",
"elem_waitroom",
"elem_cabinet",
comment.elem = "comment_elem",
"suppl",
"suppl_hivkit",
"suppl_pregkit",
"suppl_contra",
"suppl_pep",
"suppl_sti",
"suppl_analg",
"suppl_anaes",
"suppl_antibio",
"suppl_tt",
comment.suppl = "comment_suppl",
"hlthtrain",
"hlthtrain_medicare",
"hlthtrain_clinrape",
"hlthtrain_psycho",
"hlthtrain_other",
oth.hlthtrain.dscrb = "describe_other_hlthtrain",
qual.staff = "qual_staff",
"srvleg",
"srvleg_consult",
"srvleg_rep",
"srvleg_court",
"srvleg_med",
"srvleg_secur",
"srvleg_counsel",
"srvleg_other",
oth.srvleg.dscrb = "describe_other_srvleg",
total.legal = "legal_num",
legal.paid = "legal_fees",
legal.access = "legal_access",
legalfee.consult = "legalfee_consult",
legalfee.rep = "legalfee_rep",
legalfee.court = "legalfee_court",
legalfee.med = "legalfee_med",
legalfee.secur = "legalfee_secur",
legalfee.counsel = "legalfee_counsel",
legalfee.other = "legalfee_other",
support.for.court = "support_court",
no.resources1 = "noresource1",
no.resources2 = "other_action",
"srvpsy",
"srvpsy_counsel",
"srvpsy_case",
"srvpsy_therapy",
"srvpsy_safety",
"srvpsy_other",
oth.srvpsy.dscrb = "describe_other_srvpsy",
total.psychosocial = "psych_num",
psych.paid = "psych_fees",
psych.access = "psych_access",
psychfee.counsel = "psychfee_counsel",
psychfee.case = "psychfee_case",
psychfee.therapy = "psychfee_therapy",
psychfee.safety = "psychfee_safety",
psychfee.other = "psychfee_other",
"psytrain",
"psytrain_safety",
"psytrain_child",
"psytrain_counsel",
"psytrain_therapy",
"psytrain_case",
"psytrain_other",
oth.psychtrain.dscrb = "describe_other_psytrain",
qualstaff.id = "id_qualstaff",
"srvpol",
"srvpol_caseinv",
"srvpol_safety",
"srvpol_other",
oth.srvpol.dscrb = "describe_other_srvpol",
gbv.police = "gbvpolice",
who.gbvpolice = "gbvpolice_who",
refer.otherpolice = "ref_otherpol",
"poltrain",
"poltrain_surv",
"poltrain_child",
"poltrain_inv",
trainedpolice.id = "id_trainedpolice",
"polnum",
total.police.rape = "polnum_rape",
total.police.ipv = "polnum_ipv",
total.police.csa = "polnum_csa",
total.police.fgm = "polnum_fgm",
total.police.oth = "polnum_other",
oth.polnum.dscrb = "describe_other_polnum",
police.fees = "police_fees",
police.access = "pol_access",
policefee.case = "policefee_case",
policefee.safety = "policefee_safety",
policefee.other = "policefee_other",
"polresrc",
"polresrc_vehcl",
"polresrc_bike",
"polresrc_fuel",
"polresrc_other",
oth.policeresrc.dscrb = "describe_other_polresrc",
police.followup = "pol_ffup",
police.confidential = "pol_ffup_conf",
"srvshelt",
"srvshelt_hous",
"srvshelt_psych",
"srvshelt_safety",
"srvshelt_case",
"srvshelt_basic",
"srvshelt_health",
"srvshelt_other",
health.srvshelt.dscrb = "descr_health_srvshelt",
oth.srvshelt.dscrb = "descr_oth_srvshelt",
shelter.famfriendly = "shelt_fam",
shelter.kidfriendly = "shelt_childfrndly",
"sheltpriv",
"sheltpriv_wall",
"sheltpriv_guard",
"sheltpriv_cctv",
"sheltpriv_locks",
"sheltpriv_other",
oth.sheltpriv.dscrb = "descr_oth_sheltpriv",
"sheltamen",
"sheltamen_food",
"sheltamen_cloth",
"sheltamen_shwr",
"sheltamen_other",
oth.sheltamen.dscrb = "descr_oth_sheltamen",
electricwater = "shelt_elecwtr",
total.shelter.f = "shelt_num_f",
total.shelter.m = "shelt_num_m",
shelter.support = "shelt_givsupp",
shelter.new.support = "shelt_capsupp",
"srvecon",
"srvecon_agric",
"srvecon_train",
"srvecon_incomegen",
"srvecon_loans",
"srvecon_cash",
"srvecon_land",
"srvecon_other",
oth.srvecon.dscrb = "describe_other_srvecon",
total.economic = "econ_num",
econ.areas = "econ_areas",
econ.reject = "econ_reject",
"complete",
"thanks",
"version1",
"version2",
"version_001",
"op1year",
"id",
"uuid",
"submission_time",
"validation_status",
"notes",
"status",
"submitted_by",
"tags",
"index"
)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.