random_responding_time_filter: Random responding time filter

Description Usage Arguments Value Examples

View source: R/biasdetection_functions.R

Description

Detects the random responses in the stated preference dataset. It is based on the time spent by respondents in filling up different parts of the survey. The responses having time group values lower than the first quartiles of the respective time group are identified as random responding. For each Time Group and for each respondent, the results of the random responses are recorded as binary (where 1 is true and 0 is false ). It also creates 2 additional columns (RR_Total and percent_RR_Total) containing the sum of the random responses for each Time Group, and the total percentage of random responses for each respondent, respectively.

Usage

1
random_responding_time_filter(rr_data, excluded_time_groups, num_time_groups)

Arguments

rr_data

A dataframe containing unique responses (based on id) from the original panel data

excluded_time_groups

A list containing the indices of excluded time groups. Excluded time groups could be the ones which record time spent by respondents in filling up groups like introduction.

num_time_groups

Number of time groups

Value

A list containing the updated data having a new column containing the percentage of random responding for each respondent random_responding_time_filter()

Examples

1
2
3
4
## Not run: 
random_responding_time_filter(dataframe, list(1,4,7), 8)

## End(Not run)

Rupanjan22/biasdetection documentation built on April 14, 2021, 10:46 a.m.