---
title: "update(_:with:eventHandler:)"
framework: createmlcomponents
role: symbol
role_heading: Instance Method
path: "createmlcomponents/updatableestimatortosupervisedadaptor/update(_:with:eventhandler:)"
---

# update(_:with:eventHandler:)

Updates a transformer with a new sequence of examples.

## Declaration

```swift
func update<InputSequence>(_ transformer: inout Estimator.Transformer, with input: InputSequence, eventHandler: EventHandler? = nil) async throws where InputSequence : Sequence, InputSequence.Element == AnnotatedFeature<Estimator.Transformer.Input, Annotation>
```

## Parameters

- `transformer`: A transformer to update.
- `input`: A sequence of examples.
- `eventHandler`: An event handler.

## See Also

### Fitting and Updating

- [fitted(to:eventHandler:)](createmlcomponents/updatableestimatortosupervisedadaptor/fitted(to:eventhandler:).md)
- [fitted(to:validateOn:eventHandler:)](createmlcomponents/updatableestimatortosupervisedadaptor/fitted(to:validateon:eventhandler:).md)
- [makeTransformer()](createmlcomponents/updatableestimatortosupervisedadaptor/maketransformer().md)
- [update(_:with:validateOn:eventHandler:)](createmlcomponents/updatableestimatortosupervisedadaptor/update(_:with:validateon:eventhandler:).md)
- [Transformer](createmlcomponents/transformer.md)
