-
-
Notifications
You must be signed in to change notification settings - Fork 21
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow to give Distributions for param_range
#99
Comments
I second this suggestion. It would be great if the input parameters could be sampled from a distribution rather than simply from a range. For example, I'm using the eFAST method and I'd like to be able to choose a normal distribution with a specified mean and variance for some of my input parameters. |
This makes sense but I would appreciate if you have some reference of how the sampling should be done from that for it to be space-filling. Meanwhile you could already do the sampling on your end and pass in the design matrix https://docs.sciml.ai/GlobalSensitivity/stable/tutorials/parallelized_gsa/#Direct-Use-of-Design-Matrices |
Actually, it won't work for eFAST but work for Sobol. eFAST is defined by its unique sampling as described here https://docs.sciml.ai/GlobalSensitivity/stable/methods/efast/. I don't think it can be used for non-uniform distribution, but I might be wrong so would be interested to see if it has been done somewhere. Also note that there are some methods that require a distribution, and hence might be better suited for you so take a look at those in docs |
There appears to be Matlab package made at the University of Michigan which accepts distributions for the input parameters. Here is their website with their scripts: http://malthus.micro.med.umich.edu/lab/usadata/. (see parameterdist.m file). I've seen distributions used for input parameters for eFAST in a few places in the literature, for example https://www.sciencedirect.com/science/article/pii/S0304380021002088 (see tables in appendices) but they don't give any details on how they implemented it. And Saltelli's original paper on eFAST suggests the use of input parameter pdfs (see Table 6) https://scholar.google.com/citations?view_op=view_citation&hl=en&user=vqhLsGkAAAAJ&citation_for_view=vqhLsGkAAAAJ:9yKSN-GCB0IC. The math here is above my head, so I'm not sure how difficult this would be to implement, or if these sources are useful to you, but I appreciate you spending the time to take a look at this. Thanks! |
Thanks for sharing the references, I'll take a look! |
Comparing the implementation of GlobalSensitivityAnalysis.jl and the Matlab implementation linked above I think all that is needed is a change on this line: GlobalSensitivity.jl/src/eFAST_sensitivity.jl Line 101 in 8a5a179
So instead of constructing a |
That makes sense, sorry I haven't had time to look into this on my end. Do you want to do a PR to make that change? There can be a kwarg dist_params defaulting to uniform distributions that takes an array of distributions |
Sometimes it is convenient to provide a distribution instead of an uniform input range. See e.g. this example from GlobalSensitivityAnalysis.jl:
In particular, see https://github.com/lrennels/GlobalSensitivityAnalysis.jl/blob/01da54f81407120d2c91f28f6637ddffa350f146/src/utils.jl#L45 how map the
distribution
s to samples with thequantile
function.The text was updated successfully, but these errors were encountered: