| stats_df | R Documentation |
This function creates a latex table or data frame with the basic statistics of a data frame.
stats_df(
data,
missingval = -999,
ret = "tbl",
capt = "Statistics data frame",
align = "p{2cm}p{1cm}p{1cm}p{4cm}p{1.7cm}p{1.7cm}p{0.8cm}p{1.3cm}",
size = "\\footnotesize",
...
)
data |
a data frame for which the overview should be created |
missingval |
numeric with the value that indicates missing values, if NULL no missings will be recorded |
ret |
a character vector to define what kind of output should be returned (either "dfrm", "tbl", "file") |
capt |
character with the caption of the table (not used in case data frame is returned) |
align |
alignment of the table passed to general_tbl (not used in case data frame is returned) |
size |
character with font size as for the table general_tbl |
... |
additional arguments passed to general_tbl |
This function can be used to create a table with basic statistics of a data frame. The function will list the min, max, number of NA/missing values, number of unique categories and type of variable of all data items within a data frame. In case a data item has less than 10 unique categories, it will list the unique values. The main reason to use this function is to create a structured table with statistics of a data frame to be included in documentation.
either tex code for table a data frame
Richard Hooijmaijers
stats_df(Theoph)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.