pwrs.core.remove_userfcn#

pwrs.core.remove_userfcn.remove_userfcn(mpc, stage, fcn)[source]#

Remove a user callback from a MATPOWER case struct.

Deletes the first matching callback registration for fcn at the given callback stage.

Parameters:
  • mpc (dict) – MATPOWER case struct.

  • stage (str) – Callback stage name.

  • fcn (callable or str) – Callback function or function name to remove.

Returns:

Updated MATPOWER case struct with the callback removed.

Return type:

dict