Skip to contents

Easy Import/Export

read_data() write_data()
Import and export with various data formats

Stata-like Functions

browse()
Browse columns like Stata's browse command
ds() ds_as_column() names_as_column()
List column names by tidyselect
variables() variables_search()
Show the variable list of a dataset
codebook() codebook_detail()
View the codebook of a dataset or selected columns
summ() tabstat()
Summarise columns
tab() tab1() tab2() fre() fre1() fre2()
Tabulate columns
row_mean() row_sum() row_max() row_miss() row_non_miss() row_min() row_median() row_var() row_sd() row_unique()
Generate a variable based on row-wise operations.

Easy Regression

regress() regress_coef() regress_stat() regress_data()
Directly obtain the regression results
tidy_coef()
Directly obtain the regression results

Type Conversion

na_if_value() value_if_na()
NA Conversion
as_character() as_numeric()
Better type conversion

Small Tools

print_headtail() print_interval() slice_headtail() slice_interval()
Print a long tibble with selected rows
cut_quantile() cut_length() cut_breaks()
Cut a numeric vector into intervals.
s_ggsave()
Quickly save a ggplot to a file
s_match()
Tidyselect columns in stata style
s_plot()
Quick plot
s_select()
Enhanced select() with data-masking
s_time()
Time spent on a function
s_try()
Try a function and return a logical
s_type() s_unit()
Know the type of an object.
set_seed()
Set seeds with pipeline.
skew() kurtosis()
Skewness and kurtosis

Sample Data

lifeexp
Life expectancy data in 1998
starwars
Starwars characters