approximate_polynomial_chaos¶
-
pyapprox.approximate.approximate_polynomial_chaos(train_samples, train_vals, verbosity=0, basis_type='expanding_basis', variable=None, options=None)[source]¶ Compute a Polynomial Chaos Expansion of a function from a fixed data set.
- Parameters
- train_samplesnp.ndarray (nvars,nsamples)
The inputs of the function used to train the approximation
- train_valsnp.ndarray (nvars,nsamples)
The values of the function at
train_samples- basis_typestring
Type of approximation. Should be one of
‘expanding_basis’ see
pyapprox.approximate.cross_validate_pce_degree()‘hyperbolic_cross’ see
pyapprox.approximate.expanding_basis_omp_pce()
- variablepya.IndependentMultivariateRandomVariable
Object containing information of the joint density of the inputs z. This is used to generate random samples from this join density
- verbosityinteger
Controls the amount of information printed to screen
- Returns
- result
pyapprox.approximate.ApproximateResult Result object. For more details see
- result