Chandra X-Ray Observatory
Skip to the navigation links
Last modified: 20 October 2015


Bugs: delete_model_component


The command fails with a KeyError.

There is a bug in delete_model_component in Sherpa which causes it to fail with a KeyError: dataset_id

sherpa> set_source(xsphabs.abs1*
sherpa> delete_model_component("pl") 
KeyError: 1

While an error is thrown, the model component is successfully deleted.

sherpa> set_source(xsphabs.abs1*powlaw1d.p1)
sherpa> list_model_components()
          ['abs1', 'p1']
sherpa> delete_model_component("p1")
KeyError: 1
sherpa> list_model_components()

Last modified: 20 October 2015
Smithsonian Institute Smithsonian Institute

The Chandra X-Ray Center (CXC) is operated for NASA by the Smithsonian Astrophysical Observatory. 60 Garden Street, Cambridge, MA 02138 USA.   Email: Smithsonian Institution, Copyright © 1998-2017. All rights reserved.