Preprocess report"

# Setup hiden variables
er = 0

# Setup settings
knitr::opts_chunk$set(echo=TRUE, message=FALSE, warning=FALSE)

This template follows the preprocessing framework described in Revol and al. (under review) and is stored in a R package esmbooks. Additional instructions on creating reports and also on preprocessing ESM data can be found on the ESM Preprocessing Gallery website.

Study and data collection procedure

Load packages

Import the packages:

# For instance:
library(ggplot2) # Used to create plots

Step 1: Import data and preliminary preprocessing

This section is dedicated to the first look at the data, the merging of data sources the first basic preprocessing methods (e.g., duplicates, branching items check), and checking the variable consistency when the data has just been imported.

Import the data:

data = read.csv("path_to_file.csv")

Issue r er=er+1 ; er: DESCRIPTION


Data inspection: DESCRIPTION


Data modification: DESCRIPTION


Step 2: Design and sample scheme checking

This section is dedicated to checking and solving issues due to inconsistencies between the planned and the actual design of the study.


Step 3: Participants response behaviors

This section is dedicated to investigating how well participants engaged with the ESM study looking particularly for problematic patterns of behaviors (e.g., invalid observations, response time, careless responding).


Step 4: Compute and transform variables

This section is dedicated to computing and modifying variables of interest that will later be used in visualization and statistical analysis.


Step 5: Descriptive statistics and visualization

This section is dedicated to examining various aspects of variables (such as distribution) and the differences both within and between participants.

Export preprocessed data

The preprocessed data is finally exported.


Session info

For reproducibility purposes, this section informs about the R session and packages used as well as their versions.

sessionInfo()

Additionally, we display the meta-information of the preprocessed dataset.

esmtools::dataInfo(file_path=file_path_preproc, 
                   read_fun = read.csv,
                   idvar="id", timevar="sent")


Try the esmtools package in your browser

Any scripts or data that you put into this service are public.

esmtools documentation built on May 29, 2024, 6:45 a.m.