Description Usage Arguments Details Value Note Author(s) References See Also Examples
Calculating to return answer which are descriptive statistics values for a discrete variable or discrete variables in data frame.
1 | Frequencies(x, plot = FALSE, r = 2, answer = 1)
|
x |
A discrete variable or a data frame contain discrete variable. |
plot |
Let plot=TRUE to paint pie graph. |
r |
Rounds the answer to the specified number of decimal places (default 2). |
answer |
Form of answers are returned. Let answer=1 or answer=2 (default 1) |
Statistic descriptive values are calculated by theory of base statistic.
N |
Length sample |
NaN |
Number NA values |
xi |
Length of xi |
You must not withdraw continuously variables from data frame. When you let a data frame in to this function which will auto withdraw continuously variables and calculate descriptive statistic to discrete variables.
Hong Viet Minh <hongvietminh@gmail.com>
Theory of base statistic.
1 2 3 4 5 6 7 8 9 | #Loading data
library(MASS)
attach(quine)
#Descriptive for a discrete variable
Frequencies(Age,plot=TRUE)
#Descriptive for discrete more variables
Frequencies(quine,answer=2,plot=TRUE)
|
Loading required package: MASS
Loading required package: TSA
Attaching package: 'TSA'
The following objects are masked from 'package:stats':
acf, arima
The following object is masked from 'package:utils':
tar
Loading required package: TTR
Loading required package: tseries
Loading required package: urca
Attaching package: 'AnalyzeTS'
The following object is masked from 'package:base':
pmax
N: 146
NaN: 0
F0: 27
F1: 46
F2: 40
F3: 33
$Eth
N: NaN: A: N:
146 0 69 77
$Sex
N: NaN: F: M:
146 0 80 66
$Age
N: NaN: F0: F1: F2: F3:
146 0 27 46 40 33
$Lrn
N: NaN: AL: SL:
146 0 83 63
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.