Learn R Programming

glmmrBase (version 0.4.6)

cross_df: Generate crossed block structure

Description

Generate a data frame with crossed rows from two other data frames

Usage

cross_df(df1, df2)

Value

data frame

Arguments

df1

data frame

df2

data frame

Details

For two data frames `df1` and `df2`, the function will return another data frame that crosses them, which has rows with every unique combination of the input data frames

Examples

Run this code
cross_df(data.frame(t=1:4),data.frame(cl=1:3))

Run the code above in your browser using DataLab