TESTERS NEEDED: Generate Saturated Models Add-InI've written an add-in that automatically generates saturated models for use in the Stepwise Fit Model platform, and I could use some testers. Essentially, what it does is interrogates each of the Factor (X) columns selected, finds the number of discrete levels in them, then builds up the model effects table based on that. So, in other words, if you ran a full-factorial design across these parameters:
| Enzyme A | Enzyme B | Yeast |
| 10 | 20 | A |
| 20 | 40 | B |
| 30 | 60 | C |
| | 80 | |
The factors table would be built as:
Fit Model(
Effects(
:Enzyme A,
:Enzyme A * :Enzyme A,
:Enzyme B,
:Enzyme B * :Enzyme A,
:Enzyme B * :Enzyme A * :Enzyme A,
:Enzyme B * :Enzyme B,
:Enzyme B * :Enzyme B * :Enzyme A,
:Enzyme B * :Enzyme B * :Enzyme A * :Enzyme A,
:Enzyme B * :Enzyme B * :Enzyme B,
:Enzyme B * :Enzyme B * :Enzyme B * :Enzyme A,
:Enzyme B * :Enzyme B * :Enzyme B * :Enzyme A * :Enzyme A,
:Yeast,
:Yeast * :Enzyme A,
:Yeast * :Enzyme A * :Enzyme A,
:Yeast * :Enzyme B,
:Yeast * :Enzyme B * :Enzyme A,
:Yeast * :Enzyme B * :Enzyme A * :Enzyme A,
:Yeast * :Enzyme B * :Enzyme B,
:Yeast * :Enzyme B * :Enzyme B * :Enzyme A,
:Yeast * :Enzyme B * :Enzyme B * :Enzyme A * :Enzyme A,
:Yeast * :Enzyme B * :Enzyme B * :Enzyme B,
:Yeast * :Enzyme B * :Enzyme B * :Enzyme B * :Enzyme A,
:Yeast * :Enzyme B * :Enzyme B * :Enzyme B * :Enzyme A * :Enzyme A
)
);
I've run into a few issues in testing, but I believe I've fixed them now. If this kind of model fitting applies to your work, please test out the attached add-in! It will install under the Add-Ins menu as NovoJMP, with a pop-out menu including the Generate Saturated Model function. I recommend the Stepwise platform because it's easier to use than the Standard Least Squares platform and handles any model over-specification without complaint.
Re: TESTERS NEEDED: Generate Saturated Models Add-InI've added a simple version of Jameel's suggestion, as well as an automated analysis module that allows selection of Ys, Xs, By Groups, and Order, generates the saturated model, runs it through Stepwise, and saves the prediction formulas and confidence intervals back to the table. The latter part, especially, is fairly complex, so that needs some more testing for sure!
EDIT: JSDE caught a bug where the add-in would fail silently if no Y column or X column was selected. Updated version has been uploaded (I also updated the file on the original post).
(plus as a bonus you get the experimental batch fermentation analysis module, designed for Ankom pressure monitors [but it should work for any curve with a lag phase and upper saturation level)
~Michael
Re: TESTERS NEEDED: Generate Saturated Models Add-InIs there value in assuming and adding some sort of 'maximum polynomial degree' to the addin that could reflect some knowlege of the reaction mechanism? Eg, if we assume each enzyme operates with a second order maximum, then you might add '5' as a maximum (Enzyme A^2 * Enzyme B^2 x Yeast) = 5 orders. Or a dropdown next to each factor that sets the max polynomial for that particular factor. This reduces the chance of abuse via overfitting (the ever polular "click and go" style) and ensures differences are more conservative.
Re: TESTERS NEEDED: Generate Saturated Models Add-InYeah, a good example is something like the interaction of glucoamylase loading with alpha-amylase loading. Both molecules are capable of acting on starch, but glucoamylase prefers to work on soluble long-chain sugars. So, with enough glucoamylase, alpha-amylase will no longer increase final glucose yield, and with enough alpha-amylase, you don't need as much glucoamylase to maximize glucose yield.
Since the loading of each determines when the glucose vs dose curve saturates (and not just where the whole curve sits on the y axis), the higher order polynomial interactions are necessary to describe the response with adequate precision to make the kind of treatment-to-treatment discrimination we need.
I've attached a data table with made-up but realistic curves for GA/AA interactions, as an example.
Re: TESTERS NEEDED: Generate Saturated Models Add-InNice, everything seems to be working as intended.
I think my main hurdle is mostly to do with not being exposed to enzyme mechanics at all. I understand the need for interactions in a model, it's the complexity of the interactions being evaluated here that's putting me in awe (as I would rarely even bother to model something like x^2*y unless I had a terribly good reason to do so, much less x^2*y^3). Sounds like life is pretty complicated for y'all over there 
Best,
-Adam (ABI)
Re: TESTERS NEEDED: Generate Saturated Models Add-InI just realized I can demo this in JMP, haha.
In the attached data table, I've used nonlinear equations to generate 3 columns, then used the Saturated Models add-in to fit those nonlinear models in a linear expansion. The bottom script (Compare Linear to Nonlinear) will produce the Fit Model report generated after using the Stepwise platform (Settings: minimum AICc, Forward, Whole Effects). I've also fit it with the Heredity restriction in place using the Combine rule instead of Whole Effects, which I've saved as "[Heredity] Compare Linear to Nonlinear".
Re: TESTERS NEEDED: Generate Saturated Models Add-In"Also, I'm not used to seeing complex interactions like ":Enzyme B * :Enzyme B * :Enzyme B * :Enzyme A * :Enzyme A", as most of my work is much simplier. If an effect like this was significant, how would you explain it?"
My understanding of linear modeling is it's akin to a Taylor Series expansion (https://en.wikipedia.org/wiki/Taylor_series#Examples). With something that follows a nonlinear curve like a saturation curve vs enzyme dose (Mechanistic Growth model in the Nonlinear platform fits well, btw), you're expanding the nonlinear equation into an approximation using linear terms. That is, based on the amount of data you have, you are coming closer and closer to approximating the "true" curve by estimating additional linear terms.
I wonder if GIFs work hereI wonder if GIFs work here
So there isn't a physical explanation for the terms, per se, except that you could say that the magnitude of the EnzymeA^3 effect is dependent on the value of the EnzymeB^2 term.
I'm not sure whether I would rely on this technique for predictive modeling (maybe interpolation, but not extrapolation), but it's extremely useful in descriptive modeling, which puts it soundly in George Box's famous statement "All models are wrong, but some are useful." 
Re: TESTERS NEEDED: Generate Saturated Models Add-InAh, sorry, yeah, I should have mentioned. Your "Enzyme A" and "Enzyme B" columns are set to Nominal. Polynomials will only be generated for Continuous columns, because you can't model, e.g., "Yeast A^2", but you can model "20^2" for enzyme dose.
Re: TESTERS NEEDED: Generate Saturated Models Add-InHi Michael,
Can you go into more detail about the use of this add-in? I tried it out and it produced the same result as the "Full Factorial" Macro would in Fit Model (i.e., it didn't include all the listed effects in your post)
I might have set up my example table incorrectly. This is what I used:
InputTableInputTable
Result from script:
ScriptResultScriptResult
Result from "Full Factorial" macro:
MacroResultMacroResult
Did I set up something incorrectly?
Also, I'm not used to seeing complex interactions like ":Enzyme B * :Enzyme B * :Enzyme B * :Enzyme A * :Enzyme A", as most of my work is much simplier. If an effect like this was significant, how would you explain it?
Thanks!