ocar: ocar data set

Description Usage Format Details Examples

Description

Car segment shares SGB regression with formula

Usage

1
data("ocar")

Format

List of 25 items, see regSGB.

Details

ocar is the same regression as object3 in regSGB, Example 3.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
data(ocar)
ocar
summary(ocar)   # regSGB summary
ocar[["kkt1"]]  # first KKT condition
ocar[["V"]]     # matrix of log-ratio transformation

#######################################################
## ocar has been created by the following commands:
## Car segment shares
 data(carseg)
 
## Extract the compositions
uc <- as.matrix(carseg[,(1:5)])

## Define the log-ratio transformation matrix
Vc <- matrix(c( 1, 0, 0, 0,
               -1, 1, 0, 0,
                0,-1, 1, 0,
                0, 0,-1, 1,
                0, 0, 0,-1),ncol=4,byrow=TRUE)
colnames(Vc) <- c("AB","BC","CD","DE")
rownames(Vc) <- colnames(uc)
Vc

## Formula
Form <- Formula(AB | BC | CD | DE ~  log(expend) + I(PAC*log(expend)) + log(sent) + log(FBCF) + 
                 log(price) + rates)
ocar <- regSGB(Form, data = list(carseg, uc, Vc),shape10=4.4)
##########################################################

SGB documentation built on March 26, 2020, 8:02 p.m.