parameters: (workspace, spectrum_number)
return_statement: return extract_alg.getProperty("OutputWorkspace").value
docstring: The extracts a single spectrum from the input workspace.
  
      We are only interested in the incident monitor here.
      :param workspace: The workspace to extract from
      :param spectrum_number: the spectrum number of the incident beam monitor.
      :return: a workspace which only contains the incident beam spectrum.
docstring_summary: The extracts a single spectrum from the input workspace.
docstring_tokens: The extracts a single spectrum from the input workspace .
function: def _extract_monitor(workspace, spectrum_number):
      """
      The extracts a single spectrum from the input workspace.
  
      We are only interested in the incident monitor here.
      :param workspace: The workspace to extract from
      :param spectrum_number: the spectrum number of the incident beam monitor.
      :return: a workspace which only contains the incident beam spectrum.
      """
      workspace_index = workspace.getIndexFromSpectrumNumber(spectrum_number)
      extract_name = "ExtractSingleSpectrum"
      extract_options = {"InputWorkspace": workspace,
                         "OutputWorkspace": EMPTY_NAME,
                         "WorkspaceIndex": workspace_index}
      extract_alg = create_unmanaged_algorithm(extract_name, **extract_options)
      extract_alg.execute()
      return extract_alg.getProperty("OutputWorkspace").value
function_tokens: def _extract_monitor ( workspace , spectrum_number ) : workspace_index = workspace . getIndexFromSpectrumNumber ( spectrum_number ) extract_name = "ExtractSingleSpectrum" extract_options = { "InputWorkspace" : workspace , "OutputWorkspace" : EMPTY_NAME , "WorkspaceIndex" : workspace_index } extract_alg = create_unmanaged_algorithm ( extract_name , * * extract_options ) extract_alg . execute ( ) return extract_alg . getProperty ( "OutputWorkspace" ) . value