openturns
openturns copied to clipboard
The doc of the BasisFactory class has no example.
In the doc of the BasisFactory
class:
http://openturns.github.io/openturns/master/user_manual/response_surface/_generated/openturns.BasisFactory.html
there is no example.
The context of this bug is the will to create a kriging algorithm with an arbitrary trend. It is easy to create a kriging with a constant, linear or quadratic basis, but, there is no example of how to create a kriging algorithm with a customized trend.
I think python/doc/examples/meta_modeling/kriging_metamodel/plot_kriging_beam_arbitrary_trend.py
a.k.a. "Configuring an arbitrary trend in Kriging" shows what you want. What do you think @mbaudin47 ?
Not in my sense. My message highlights the fact that the API help page has no example.
There are at least two different places for examples, each with a specific content.
- In my dreams, any API page has a minimal example showing the minimum number of lines of codes (the minimal working example) which creates the object and use its main methods. It focuses on the software and presents the input and output arguments of the class and its methods.
- On the other hand, examples in the "Examples" section shows how to combine several classes in order to create something meaningful in practice. This is a synthesis exercise. Such a page has interesting examples, which are relevant to the UQ methodology.
A related class is Basis
, which does provide not enough examples:
https://openturns.github.io/openturns/latest/user_manual/_generated/openturns.Basis.html
Two examples may be created :
- create a basis with several functions, based on Symbolic or Python functions,
- create a basis from the several outputs of a multivariate function.
Another example of a custom basis is provided at FunctionalChaosAlgorithm with your own orthonormal basis construction