| sim_mixed_df {faux} | R Documentation | 
Generate a mixed design from existing data
Description
sim_mixed_df() produces a data table with the same distributions of 
by-subject and by-item random intercepts as an existing data table.
Usage
sim_mixed_df(
  data,
  sub_n = NULL,
  item_n = NULL,
  dv = "y",
  sub_id = "sub_id",
  item_id = "item_id"
)
Arguments
| data | the existing tbl | 
| sub_n | the number of subjects to simulate (if NULL, returns data for the same subjects) | 
| item_n | the number of items to simulate (if NULL, returns data for the same items) | 
| dv | the column name or index containing the DV | 
| sub_id | the column name or index for the subject IDs | 
| item_id | the column name or index for the item IDs | 
Value
a tbl
Examples
sim_mixed_df(faceratings, 10, 10, "rating", "rater_id", "face_id")
[Package faux version 1.2.1 Index]