| sobocinski | R Documentation |
NA values.By default, the objects created with the algebra() function represent a mathematical
algebra capable to work on the [0,1] interval. If NA appears as a value instead,
it is propagated to the result. That is, any operation with NA results in NA, by default.
This scheme of handling missing values is also known as Bochvar's. To change this default
behavior, the following functions may be applied.
sobocinski(algebra)
kleene(algebra)
dragonfly(algebra)
nelson(algebra)
lowerEst(algebra)
algebra |
the underlying algebra object to be modified – see the |
The sobocinski(), kleene(), nelson(), lowerEst() and dragonfly() functions modify the algebra to
handle the NA in a different way than is the default. Sobocinski's algebra simply ignores NA values
whereas Kleene's algebra treats NA as "unknown value". Dragonfly approach is a combination
of Sobocinski's and Bochvar's approach, which preserves the ordering 0 <= NA <= 1
to obtain from compositions (see compose())
the lower-estimate in the presence of missing values.
In detail, the behavior of the algebra modifiers is defined as follows:
Sobocinski's negation for n being the underlying algebra:
| a | n(a) |
| NA | 0 |
Sobocinski's operation for op being one of t, pt, c, pc, i, pi, s, ps
from the underlying algebra:
| b | NA | |
| a | op(a, b) | a |
| NA | b | NA |
Sobocinski's operation for r from the underlying algebra:
| b | NA | |
| a | r(a, b) | n(a) |
| NA | b | NA |
Kleene's negation is identical to n from the underlying algebra.
Kleene's operation for op being one of t, pt, i, pi from the underlying algebra:
| b | NA | 0 | |
| a | op(a, b) | NA | 0 |
| NA | NA | NA | 0 |
| 0 | 0 | 0 | 0 |
Kleene's operation for op being one of c, pc, s, ps from the underlying algebra:
| b | NA | 1 | |
| a | op(a, b) | NA | 1 |
| NA | NA | NA | 1 |
| 1 | 1 | 1 | 1 |
Kleene's operation for r from the underlying algebra:
| b | NA | 1 | |
| a | r(a, b) | NA | 1 |
| NA | NA | NA | 1 |
| 0 | 1 | 1 | 1 |
Dragonfly negation is identical to n from the underlying algebra.
Dragonfly operation for op being one of t, pt, i, pi from the underlying algebra:
| b | NA | 0 | 1 | |
| a | op(a, b) | NA | 0 | a |
| NA | NA | NA | 0 | NA |
| 0 | 0 | 0 | 0 | 0 |
| 1 | b | NA | 0 | 1 |
Dragonfly operation for op being one of c, pc, s, ps from the underlying algebra:
| b | NA | 0 | 1 | |
| a | op(a, b) | a | a | 1 |
| NA | b | NA | NA | 1 |
| 0 | b | NA | 0 | 1 |
| 1 | 1 | 1 | 1 | 1 |
Dragonfly operation for r from the underlying algebra:
| b | NA | 0 | 1 | |
| a | r(a, b) | NA | n(a) | 1 |
| NA | b | 1 | NA | 1 |
| 0 | 1 | 1 | 1 | 1 |
| 1 | b | NA | 0 | 1 |
A list of function of the same structure as is the list returned from the algebra() function
Michal Burda
a <- algebra('lukas')
b <- sobocinski(a)
a$t(0.3, NA) # NA
b$t(0.3, NA) # 0.3
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.