Learn R Programming

LOGAN (version 1.0.1)

PlotStrategybyCatPerformance: Check response time by var

Description

This is a function that reports the number of students and number of actions (min-max) aggregated by a specific variable.

Usage

PlotStrategybyCatPerformance(data, strategy.var, categ.var, namexlab, nameylab)

Value

This function returns a data.frame with the number of students and number de actions (min-max) aggregated by a specific variable.

Arguments

data

A matrix or data.frame

strategy.var

strategy variable

categ.var

categorizing variable

namexlab

name of the variable in the x-axis

nameylab

name of the variable in the y-axis

Examples

Run this code
# Data preparation
df <- cp025q01.treated
df$categ <- cut(df$PV1CPRO, c(0, 423, 488, 553, 900))
df.dataplot <- df[, c("top", "categ")]
df.dataplot[, 1] <- as.factor(df.dataplot[, 1])
df.dataplot[, 2] <- as.factor(df.dataplot[, 2])

# Function demonstration
m2$PlotStrategybyCatPerformance(
  df.dataplot, top, categ,
  "Proficiency levels", "Percentage"
)

Run the code above in your browser using DataLab