Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

After playing around with the Model Builder and looking at the python scripts of what I make, I noticed some syntax which I can't find the definition anywhere. Here is a snippet of the python script from a model:

outputs_13=processing.runalg("qgis:fieldcalculator", outputs_12['SAVENAME'], ID, 1, 10, 0, True, $rownum , None)
outputs_14=processing.runalg("qgis:deletecolumn", outputs_13['OUTPUT_LAYER'], longitude, None)
outputs_15=processing.runalg("qgis:deletecolumn", outputs_14['SAVENAME'], latitude, savename_alg15)
outputs_16=processing.runalg("qgis:clip", outputs_15['SAVENAME'], vectorlayer_layer1, None)
outputs_17=processing.runalg("qgis:fieldcalculator", outputs_16['OUTPUT'], Score, 0, 10, 0, True, 2, output_layer_alg17)

Can someone please explain the purpose of ['SAVENAME'], ['OUTPUT'] and ['OUTPUT_LAYER']?

I am trying to develop a script but keep getting errors linked to these terms and I am unsure as to how they are used.

share|improve this question
up vote 2 down vote accepted

Look at Using processing algorithms from the console

import processing 
 ALGORITHM: Field calculator
  INPUT_LAYER <ParameterVector>
  FIELD_NAME <ParameterString>
  FIELD_TYPE <ParameterSelection>
  FIELD_LENGTH <ParameterNumber>
  FIELD_PRECISION <ParameterNumber>
  NEW_FIELD <ParameterBoolean>
  FORMULA <ParameterString>
  OUTPUT_LAYER <OutputVector>

      FIELD_TYPE(Field type)
     0 - Float
     1 - Integer
     2 - String
     3 - Date
ALGORITHM: Delete column
LAYERNAME <ParameterVector>
COLUMN <ParameterTableField from LAYERNAME>
SAVENAME <OutputVector>
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.