l: List observations

Description Usage Arguments Value Examples

View source: R/l.R

Description

'l' lists observations in a data frame, just like the 'l' command in Stata.

Usage

1
l(df, by = NULL, n = 20)

Arguments

df

'df' should be a data frame.

by

'by' should be a string indicating variables in the data frame.

n

'n' should be a positive integer.

Value

'l(df)' returns a data frame.

Examples

1
2
3
library(dplyr)
abdata = haven::read_dta("http://www.stata-press.com/data/r13/abdata.dta")
abdata %>% select(id, year, wage) %>% l("id", n = 30)

jjchern/meda documentation built on May 19, 2019, 11:38 a.m.