Skip to contents

There is increasing need to make user-friendly and production ready Tables for machine learning data. This function is a simplified quick summary and the output is a formatted table. This is very handy for those who do not have the time to write codes for user-friendly summaries.

Usage

quicksummary(
  x,
  Type,
  Cut = deprecated(),
  Up = deprecated(),
  Down = deprecated(),
  ci = 0.95
)

Arguments

x

The data to be summarised. Only numeric data is allowed.

Type

The type of data to be summarised. There are two options here 1 or 2, 1 = Continuous and 2 = Likert-type

Cut

[Deprecated]

Up

[Deprecated]

Down

[Deprecated]

ci

Confidence interval which is defaults to 0.95.

Value

The function returns formatted tables of the Quick summary

Summary

List of two data.frames

Examples

library(tidyverse)
# Likert-type data
quicksummary(x = Quicksummary, Type = 2)
#> $Summary
#>                  Mean   SD SE.Mean Nobs Rank
#> Likert scores 1  4.34 1.13    0.11  103    1
#> Likert scores 14 3.85 1.35    0.13  103    2
#> Likert scores 3  3.49 1.36    0.13  103    3
#> Likert scores 10 3.49 1.51    0.15  103    4
#> Likert scores 15 3.43 1.38    0.14  103    5
#> Likert scores 19 3.43 1.23    0.12  103    6
#> Likert scores 17 3.41 1.25    0.12  103    7
#> Likert scores 2  3.23 1.57    0.15  103    8
#> Likert scores 18 3.23 1.21    0.12  103    9
#> Likert scores 4  3.17 1.34    0.13  103   10
#> Likert scores 7  3.07 1.32    0.13  103   11
#> Likert scores 21 3.07 1.32    0.13  103   12
#> Likert scores 26 3.03 1.22    0.12  103   13
#> Likert scores 20 2.98 1.18    0.12  103   14
#> Likert scores 16 2.94 1.47    0.14  103   15
#> Likert scores 22 2.94 1.31    0.13  103   16
#> Likert scores 13 2.93 1.37    0.14  103   17
#> Likert scores 11 2.89 1.20    0.12  103   18
#> Likert scores 25 2.88 1.31    0.13  103   19
#> Likert scores 23 2.84 1.48    0.15  103   20
#> Likert scores 8  2.83 1.33    0.13  103   21
#> Likert scores 6  2.77 1.44    0.14  103   22
#> Likert scores 24 2.71 1.30    0.13  103   23
#> Likert scores 5  2.67 1.27    0.13  103   24
#> Likert scores 9  2.63 1.34    0.13  103   25
#> Likert scores 12 2.41 1.26    0.12  103   26
#> Likert scores 27 2.41 1.35    0.13  103   27
#> Likert scores 29 0.89 1.78    0.18  103   28
#> Likert scores 28 0.26 0.83    0.08  103   29
#> 
#> $Means
#>                  Arithmetic Geometric Quadratic Harmonic Cubic
#> Likert scores 1        4.34       4.1      4.48      3.7   4.6
#> Likert scores 2        3.23       2.7      3.59      2.2   3.8
#> Likert scores 3        3.49       3.1      3.74      2.7   3.9
#> Likert scores 4        3.17       2.8      3.43      2.5   3.6
#> Likert scores 5        2.67       2.3      2.95      2.0   3.2
#> Likert scores 6        2.77       2.4      3.12      2.0   3.4
#> Likert scores 7        3.07       2.7      3.34      2.3   3.5
#> Likert scores 8        2.83       2.5      3.12      2.1   3.4
#> Likert scores 9        2.63       2.3      2.95      2.0   3.2
#> Likert scores 10       3.49       3.0      3.80      2.5   4.0
#> Likert scores 11       2.89       2.6      3.13      2.3   3.3
#> Likert scores 12       2.41       2.1      2.72      1.8   3.0
#> Likert scores 13       2.93       2.5      3.24      2.1   3.5
#> Likert scores 14       3.85       3.5      4.08      3.0   4.2
#> Likert scores 15       3.43       3.1      3.69      2.6   3.9
#> Likert scores 16       2.94       2.5      3.28      2.2   3.6
#> Likert scores 17       3.41       3.1      3.63      2.7   3.8
#> Likert scores 18       3.23       2.9      3.45      2.5   3.6
#> Likert scores 19       3.43       3.1      3.64      2.8   3.8
#> Likert scores 20       2.98       2.7      3.20      2.4   3.4
#> Likert scores 21       3.07       2.7      3.34      2.4   3.5
#> Likert scores 22       2.94       2.6      3.22      2.2   3.4
#> Likert scores 23       2.84       2.4      3.20      2.0   3.5
#> Likert scores 24       2.71       2.4      3.00      2.0   3.2
#> Likert scores 25       2.88       2.5      3.16      2.1   3.4
#> Likert scores 26       3.03       2.7      3.26      2.4   3.5
#> Likert scores 27       2.41       0.0      2.76      0.0   3.0
#> Likert scores 28       0.26       0.0      0.86      0.0   1.4
#> Likert scores 29       0.89       0.0      1.98      0.0   2.6
#> 

# Continuous data
x <- select(linearsystems, 1:6)
quicksummary(x = x, Type = 1)
#> $Summary
#>          MKTcost    Age Experience Years spent in formal education
#> Mean      3911.6  38.13      11.78                           10.35
#> SD        2754.2  11.14       4.55                            5.19
#> SE.Mean    275.4   1.11       0.46                            0.52
#> Min          0.0  20.00       2.00                            0.00
#> Median    2950.0  36.50      11.00                           12.00
#> Max      14000.0  68.00      20.00                           20.00
#> Q1        1850.0  30.00       8.75                            7.00
#> Q3        5760.0  45.00      15.00                           14.00
#> Skewness     1.2   0.83       0.38                           -0.72
#> Kurtosis     1.3   0.01      -0.77                           -0.42
#> Nobs       100.0 100.00     100.00                          100.00
#>          Household size Years as a cooperative member
#> Mean               8.30                         10.16
#> SD                 3.60                          3.80
#> SE.Mean            0.36                          0.38
#> Min                0.00                          2.00
#> Median             8.00                         10.00
#> Max               17.00                         20.00
#> Q1                 5.00                          7.75
#> Q3                11.00                         12.00
#> Skewness           0.18                          0.64
#> Kurtosis          -0.37                         -0.20
#> Nobs             100.00                        100.00
#> 
#> $Means
#>            MKTcost Age Experience Years spent in formal education
#> Arithmetic    3912  38       11.8                              10
#> Geometric        0  37       10.9                               0
#> Quadratic     4776  40       12.6                              12
#> Harmonic         0  35        9.8                               0
#> Cubic         5562  41       13.4                              12
#>            Household size Years as a cooperative member
#> Arithmetic            8.3                          10.2
#> Geometric             0.0                           9.5
#> Quadratic             9.0                          10.8
#> Harmonic              0.0                           8.7
#> Cubic                 9.7                          11.5
#>