    Describe a model expression.

get_model_type(model)
model - str or a sherpa.models.model.Model object
>>> create_model_component("powlaw1d", "pl") >>> get_model_type("pl") 'powlaw1d'

For expressions containing more than one component, the result is likely to be 'binaryopmodel'

>>> get_model_type(const1d.norm * (polynom1d.poly + gauss1d.gline)) 'binaryopmodel'

For sources with some form of an instrument model - such as a PSF convolution for an image or a PHA file with response information from the ARF and RMF - the response can depend on whether the expression contains this extra information or not:

>>> get_model_type(get_source('spec')) 'binaryopmodel' >>> get_model_type(get_model('spec')) 'rspmodelpha'

PARAMETERS

The parameter for this function is:

Parameter
Definition
model

The return value from this function is:

type -- The name of the model expression.

See the bugs pages on the Sherpa website for an up-to-date listing of known bugs.

December 2023