Experimental

Adds a new attribute field with an optional default value.

vector schema attributes

## Parameters

Name | Description | Required | Default
--- | --- | --- | ---
`input` | Input vector layer. | Required | `input.shp`
`field` | New field name. | Required | `NEW_FIELD`
`field_type` | Field type: integer, float, text, boolean. | Required | `float`
`default` | Optional default value. | Optional | —
`output` | Output vector path. | Required | —

## Examples

Adds a typed field to the layer schema.

    wbe.add_field(default=0.0, field='NEW_FIELD', field_type='float', input='input.shp', output='add_field.shp')

## Project Links

WbW Homepage User Manual Support WbW