Skip to contents

Get names and class of all columns in a data frame in a friendly format.

Usage

nn(df)

Arguments

df

A data frame.

Value

A data frame with index and class.

Examples

nn(iris)
#> # A tibble: 5 × 3
#>   var          index class  
#>   <chr>        <int> <chr>  
#> 1 Sepal.Length     1 numeric
#> 2 Sepal.Width      2 numeric
#> 3 Petal.Length     3 numeric
#> 4 Petal.Width      4 numeric
#> 5 Species          5 factor