Dataset to illustrate the selection of variables in regression
Usage
data(milk)
Format
Dataset with 85 rows and 6 columns :
85 milks described by the 5 variables: density, fat content, protein, casein, dry, yield
Examples
data(milk)
res = RegBest(y=milk[,6],x=milk[,-6])
res$best
Results
R version 3.3.1 (2016-06-21) -- "Bug in Your Hair"
Copyright (C) 2016 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu (64-bit)
R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.
R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.
Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.
> library(FactoMineR)
> png(filename="/home/ddbj/snapshot/RGM3/R_CC/result/FactoMineR/milk.Rd_%03d_medium.png", width=480, height=480)
> ### Name: milk
> ### Title: milk
> ### Aliases: milk
> ### Keywords: datasets
>
> ### ** Examples
>
>
> data(milk)
> res = RegBest(y=milk[,6],x=milk[,-6])
> res$best
Call:
lm(formula = as.formula(as.character(formul)), data = don)
Residuals:
Min 1Q Median 3Q Max
-0.60149 -0.25261 -0.01715 0.24097 1.07494
Coefficients:
Estimate Std. Error t value Pr(>|t|)
(Intercept) 1.84751 1.34436 1.374 0.173149
fat 0.10449 0.03028 3.451 0.000891 ***
protein 0.11660 0.03432 3.398 0.001056 **
dry 0.04036 0.01790 2.255 0.026821 *
---
Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
Residual standard error: 0.3169 on 81 degrees of freedom
Multiple R-squared: 0.6027, Adjusted R-squared: 0.588
F-statistic: 40.96 on 3 and 81 DF, p-value: 3.296e-16
>
>
>
>
>
> dev.off()
null device
1
>