library(dplyr)
library(doubleheadr)
library(gt)

doubleheadr

lifecycle

This package provides helper functions for data exports from SurveyMonkey. Most useful will likely be the clean_headr() function, which will concatenate the column names + first row values from a SurveyMonkey data export that is .csv or .xlsx.

The Main Issue

Exported SurveyMonkey data contains a column and a second row containing column-name data, which typically requires data cleaning before starting analysis.

Why doubleheadr?

Lifecycle

This package is in the early stages of development. Any and all issues are welcome, please report them and I will be happy to troubleshoot anything that comes up.

Overview

Install doubleheadr

devtools::install_github('mattroumaya/doubleheadr')

Usage

Your downloaded or inherited .csv/.xlsx file will look something like the demo included in doubleheadr.

No worries though! Cleaning your column names is as easy as 1,2... that's it! Two steps.

Start with unhelpful column names:

colnames(doubleheadr::demo)
1. clean_headr()
demo %>% 
  clean_headr(., "...") %>% 
  colnames(.)
2. trim_headr()
demo %>% 
  clean_headr(., "...") %>% 
  trim_headr(., c("please_provide_your_contact_information_",
                  "i_wish_it_would_have_",
                  "_response")) %>% 
  colnames(.)
flag_mins()


mattroumaya/doubleheadr documentation built on Jan. 23, 2022, 12:44 p.m.