Description Usage Arguments Details Value Author(s) References See Also Examples

View source: R/mainfunctions.R

This function checks the equivalence of two balanced covering stars of `PG(n-1,2)`

by comparing sorted bitstring representations.

1 | ```
checkStarEquivalence(star1, star2)
``` |

`star1` |
A star of |

`star2` |
A star of |

This code checks if two stars of `PG(n-1,2)`

are equivalent using the bitstring representation of Spencer et al. (2019). Both input stars should be formatted as 3-dimensional arrays with `spread1[i,j,k]`

indicating whether or not the `i`

th basic factor is present in the `j`

th effect of the `k`

th flat of spread1.

A Boolean indicating whether or not the two stars are equivalent.

Neil Spencer, Pritam Ranjan, Franklin Mendivil

Spencer, N.A., Ranjan, P., and Mendivil, F., (2019), "Isomorphism Check for *2^n* Factorial Designs with Randomization Restrictions", Journal of Statistical Theory and Practice, 13(60),1-24 [https://doi.org/10.1007/s42519-019-0064-5]

`checkStarIsomorphism`

for checking the isomorphism of stars.

`checkSpreadEquivalence`

for checking the equivalence of spreads.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 | ```
## Example 1: two non-equivalent stars of PG(4,2)
data(starn5t3a)
data(starn5t3b)
# test their equivalence
(test1 <- checkStarEquivalence(starn5t3a, starn5t3b))
## Example 2: two equivalent stars of PG(7,2) consisting of 6-flats
data(starn8t5a)
#permute the flats and flat order of starn8t5a to create a second equivalent spread equiv_starn8t5a.
equiv_starn8t5a <- starn8t5a
dims <- dim(equiv_starn8t5a)
for(i in 1:(dims[3])){
equiv_starn8t5a[,,i] <- equiv_starn8t5a[,sample(1:dims[2], dims[2]),i]
}
equiv_starn8t5a <- starn8t5a[,,sample(1:dims[3], dims[3])]
(test2 <- checkStarEquivalence(starn8t5a, equiv_starn8t5a))
``` |

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.