class Object
Constants
- INDEX
Generate a Resolution V Fractional Factorial design for the specified number of factors. The design is guaranteed to yield unconfounded interactions for all pairs of factors. The design uses standardized notation, i.e., -1 represents a low setting and 1 represents a high setting for each factor.
- Arguments
-
number_of_factors
-> the number of factors in your design. Limit is 120.
-
- Returns
-
a two-dimensional array specifying the design, where each column corresponds to a factor and each row is a design point.
-
- Author
-
Paul J Sanchez (pjs@alum.mit.edu)
- Copyright
-
Copyright © 2020 Paul J Sanchez
- License
-
MIT
- POWER
Public Instance Methods
make_design(number_of_factors)
click to toggle source
# File lib/datafarming/factorial_generator.rb, line 45 def make_design(number_of_factors) Array.new(number_of_factors) do |i| Array.new(POWER[number_of_factors], 0).tap { |a| a[INDEX[i]] = 1 }.hadamard end.transpose end