Skip to content

Latest commit

 

History

History
75 lines (51 loc) · 4.01 KB

README.md

File metadata and controls

75 lines (51 loc) · 4.01 KB

odksplit

odksplit is a Stata module to label the variables, assign corresponding value labels, and split and label multiple response variables generated from ODK. odksplit labels with all available languages from the XLSForm. odksplit is developed and maintained by ARCED Foundation and SotLab.

If ODK or SurveyCTO is used for data collection, the multiple response variables are downloaded as string variables. odksplit can be used to split those variables to create dummy variables as well as label the dummy variables. Additional options allow to do the other labeling excercises. If "SurveyCTO sync" is used to download data, and the 'Export select_multiple responses as series of 1/0 columns?' option was ticked, the dummy variables are already created in the dataset. However, odksplit does this again deleting the existing variables. odksplit uses the XLSform to identify the 'select_multiple' variables, and take the value labels from the choices sheet. odksplit was initially developed to work on multiple response variables, however, additional options were added based on user feedback.

This program will clear any data in memory. Therefore, the program asks whether you really want to clear data from memory. This will not work if the variable names include the group names as prefix.

Versions

Current version at GitHub : 4.0.0
Current version at SSC : 2.1.0

First released on July 2019. Last updated June 2023.

Change log

4.0.0

  • odksplit can label variables in repeat group. It also labels in multiple language. To see available languages write: label language. To change language to English write label language English. Tha language name is case sensitive. Use label() option of odksplit to make a specific language default. This version can also directly save the labelled dataset at specific location.

3.1.0

  • odksplit now adds the full questions as notes to the variables. To view the full question instead of Stata label, write notes varname. To view full questions for all variables, write notes in the Stata command window.

Installation

** Install from ssc
    ssc install odksplit

** Install from GitHub
    net install odksplit, all replace from(https://raw.githubusercontent.com/ARCED-Foundation/odksplit/master)

Syntax

odksplit [, options]

help odksplit

Options

Options Description
survey The name of the XLSform, including the path
data The name of the data file, including the path
label The language specified in the label column in ODK XLSform. For example, if the label column is 'label:English', write English. Language specified in this location will be made default.
dateformat Specify the date format, either MDY or DMY
clear To clear any data in memory
save To save labelled data in specific location

Example Syntax

    odksplit,   survey("X:\Projects 2018\Fieldwork\Tools\SurveyCTO files\Phase one_v1.xlsx") ///
                data("X:\Projects 2017\Fieldwork\Data\Data\raw\Phase one data.dta") ///
                save("X:\Projects 2017\Fieldwork\Data\Data\raw\Phase one data_labelled.dta") ///
                dateformat(MDY) ///
                label(English) clear


    odksplit,   survey("X:\Projects 2018\Fieldwork\Tools\SurveyCTO files\Phase one_v1.xlsx") ///
                data("X:\Projects 2017\Fieldwork\Data\Data\raw\Phase one data.dta") ///
                save("X:\Projects 2017\Fieldwork\Data\Data\raw\Phase one data_labelled.dta") 

    label language
    label language English

Please report all bugs/feature request to the github issues page.

Author

Mehrab Ali
Email: mehrabbabu@gmail.com