Skip to content
This repository was archived by the owner on Oct 24, 2023. It is now read-only.
This repository was archived by the owner on Oct 24, 2023. It is now read-only.

Problems with kobo_load_data function #80

@DesertRatilla

Description

@DesertRatilla

Please briefly describe your context, your problem and what output you expect.

Please include if possible a minimal reproducible example (AKA a reprex). If you've never heard of a reprex before, start by reading https://www.tidyverse.org/help/#reprex.


Context

I am using kobotoolbox to collect household level data on a daily basis to inform a Community based Surveillance System. If a household member gets sick, his/her symptoms are entered using a "Repeat"-type module. Similarly, if a household member gives birth, data related to this birth is entered using a "Repeat"-type module.

Problem

I use the kobo toolbox online interface to download the hierarchical data in csv files per module (as in https://unhcr.github.io/koboloadeR/docs/articles/Getting_data.html#using-the-online-interface-1). I create instanceID variable in all csv files. When I use the kobo_load_data function it never loads any of the "repeat"-type modules.

Current result

The log says :

loading Birth_report file ..
[1] "There was an error in the data processing step!!! \n\n"
$message
[1] "unused argument (stringsAsFactors = F)"

$call
readr::read_csv(paste0(mainDir, "/data-raw/", configInfoOrigin[configInfoOrigin$name ==
dbr, "path"]), stringsAsFactors = F)

attr(,"class")
[1] "try-error"

Possible Fix

I think maybe it has to do with the fact that for some households there are not any sick members or births to report, and maybe that is causing problems when loading the data, but I cannot find the reason nor how to fix it. Thanks

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions