Validates the marginal specification of the binary variables

Description

Checks whether the marginal specification of the binary part is valid and consistent.

Usage

1
validation.bin(n.B, prop.vec = NULL)

Arguments

n.B

Number of binary variables.

prop.vec

Probability vector for binary variables.

Value

The function returns TRUE if no specification problem is encountered. Otherwise, it returns an error message.

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
n.B<-3
prop.vec<-c(0.25,0.5,0.75)
validation.bin(n.B,prop.vec)

## Not run: 
n.B<-3
validation.bin(n.B)

n.B<--3
prop.vec<-c(0.25,0.5,0.75)
validation.bin(n.B,prop.vec)

n.B<-0
prop.vec<-c(0.25,0.5,0.75)
validation.bin(n.B,prop.vec)

n.B<-5
prop.vec<-c(0.25,0.5,0.75)
validation.bin(n.B,prop.vec)

n.B<-3
prop.vec<-c(0.25,0.5,-0.75)
validation.bin(n.B,prop.vec)

## End(Not run)