View source: R/constructDataSkeleton.R
constructDataSkeleton | R Documentation |
Representing the structure of a data set without including any observation of the data frame. Numerical values are uniformly drawn between 'min(x) - sm' and 'max(x) + sm' where 'sm' is a "safety margin" to not get insights about the minimum and maximum of a feature. Categorical features first contains the factor levels to ensure all levels in the skeleton. The remaining observations are then filled by randomly sampling from the factor levels.
constructDataSkeleton(dat, n = NULL, sm = 0.01, handler = warning, ...)
dat |
['data.frame()'] Data set for which the skeleton is calculated |
n |
['integer(1L)'] Number of observations of the skeleton. The default equals the maximal number of factor levels. |
sm |
['numeric(1L)'] Fraction of the range used as safety margin (default 'sm = 0.01'). |
handler |
['function'] Function used as feedback if a feature cannot be processed. Default is 'handler = warning' which prints a warning. The first argument of the handler is a string naming the feature which cannot be processed. |
... |
Additional arguments passed to 'handler'. |
Skeleton 'data.frame'
constructDataSkeleton(iris, n = 10L)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.