linear mixed-effects model (fitlme) add array variable

1 visualización (últimos 30 días)
P. Dodo
P. Dodo el 24 de En. de 2023
Comentada: Jeff Miller el 25 de En. de 2023
Hello community!
I would like to run a linear mixed-effect model using fitlme and include one fixed effect which instead of having one value per observations has an array (i.e., a reflectance spectrum) for each observation. The other fixed (and random) effect are instead single values.
I want to understand the variance contribution from the entire array (i.e., full spectrum) on my response variable rather than from its individual elements (i.e., reflectance at single wavelengths). How to modify the fitlme synthax for this?
Thank you in advance for any suggestion.

Respuestas (2)

Jeff Miller
Jeff Miller el 24 de En. de 2023
I'm pretty sure the predictors have to be single values, so you can't feed in an array as a single unified predictor. You could feed in the individual elements, but you say you don't want to do that.
The only other possibility would be to use a single categorical predictor to represent the whole spectrum array for each case. For example, if you had only two spectrum patterns across your whole dataset, then you could use a predictor variable coding them as type A and type B (or whatever). Something like this would work if you can group the different spectrum arrays into a small-ish number of categories; otherwise, I have no idea.
  2 comentarios
P. Dodo
P. Dodo el 25 de En. de 2023
Thank you for your answer Jeff. The categorical predictor approach would not work because spectra are very variable and cannot be grouped into types, but I see your point.
Jeff Miller
Jeff Miller el 25 de En. de 2023
Too bad. In that case, the PCA approach suggested by @the cyclist seems the most promising.
Just out of curiousity, can you describe what sort of output you would hope to get if you could get fitlme to handle a vector-type predictor? I'm having trouble envisioning just what is meant by the "variance contribution from the entire array" as opposed to the individual elements. If you mean contributions due to (say) products of pairs of elements, products of triples, etc, then you could form those in advance and feed them into the equation as further individual predictors, like in polynomial regression.

Iniciar sesión para comentar.


the cyclist
the cyclist el 25 de En. de 2023
I am by no means an expert on image processing, but one possibility is to preprocess your images to extract individual "features" that can then be used in a regression model. If you have an m-by-n array (of some kind of reflectance measure), then you have m*n features in the original data space. That will capture a certain amount of noise, but if you do some kind of dimensional reduction technique (such as PCA), then you might be able to extract a smaller number of more meaningful features (e.g. things like "overall reflectance", or "left-brighter-than-right") that could be predictors of the response.
You will not have one fit coefficent for "fixed effect of image", but you may end up with just a few.

Categorías

Más información sobre Dimensionality Reduction and Feature Extraction en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by