# How to compute sobol indices from a multi-variate regression model?

I have a dataset that consists of 300 input variables, 200 response variables, and 15000 samples. These response variables are basically a profile of 200 different values of the same response and they are 200 sequential geometrical points along the 1D line. You can visualize this as a line graph of 200 points for each observation. It turns out that this output profile of 200 points can be represented by a polynomial of some degree (let's say 6). So a polynomial line with 7 coefficients (including intercept) is fitted on each sample in the output space. A multi-variate lasso regression model is then built to predict these 7 coefficients that are used to transform back to 200 data points by polynomial interpolation.

Most of the input variables are highly correlated with each other. I'd like to perform a sensitivity analysis to determine the contribution of each predictor to each of the 200 responses. I have never done sensitivity analysis before. How do I compute first order and total sobol indices for each input variable on each response?

I'm thinking of using sobolEff() or soboljansen() or fast99() function from sensivity package in r. Which one works best?

Lets say I'm using sobolEff() function which has the following syntax:

sobolEff(model = NULL, X1, X2, order=1, nboot = 0, conf = 0.95, ...)


How do I get samples X1 and X2?

I think I'd have to write a custom function that takes the 300 input, predicts 7 polynomial coefficients from the lasso model object, and then returns the respective 200 outputs. How do I incorporate that into sobolEff() function? I'm guessing I'd have to use tell() function and use model=NULL. I'd really appreciate it if someone can give me clarity on how to approach this.

Thank you!