---
title: ColumnSelector
framework: createmlcomponents
role: symbol
role_heading: Structure
path: createmlcomponents/columnselector
---

# ColumnSelector

An operation that applies an estimator to a selection of columns.

## Declaration

```swift
struct ColumnSelector<Estimator, UnwrappedInput> where Estimator : Estimator, Estimator.Transformer.Input == UnwrappedInput?
```

## Overview

Overview This estimator applies a non-tabular estimator to a selection of columns. Here’s an example of normalizing numeric values within each column using a StandardScaler: let numericalScaling = ColumnSelector(     columns: ["volume", "price"],     estimator: NumericImputer<Float>(.mean)         .appending(StandardScaler<Float>()) ) In most cases, an inputer must handle missing values.

## Topics

### Creating the selection

- [init(columns:estimator:)](createmlcomponents/columnselector/init(columns:estimator:).md)
- [init(_:estimator:)](createmlcomponents/columnselector/init(_:estimator:).md)
- [init(_:transformer:)](createmlcomponents/columnselector/init(_:transformer:).md)

### Getting the properties

- [columnSelection](createmlcomponents/columnselector/columnselection.md)
- [estimator](createmlcomponents/columnselector/estimator.md)

### Encoding and decoding

- [encode(_:to:)](createmlcomponents/columnselector/encode(_:to:).md)
- [decode(from:)](createmlcomponents/columnselector/decode(from:).md)

### Fitting a transformer

- [fitted(to:eventHandler:)](createmlcomponents/columnselector/fitted(to:eventhandler:).md)
- [ColumnSelector.Input](createmlcomponents/columnselector/input.md)
- [ColumnSelector.Output](createmlcomponents/columnselector/output.md)
- [Transformer](createmlcomponents/transformer.md)

### Default Implementations

- [UpdatableTabularEstimator Implementations](createmlcomponents/columnselector/updatabletabularestimator-implementations.md)

## Relationships

### Conforms To

- [Copyable](swift/copyable.md)
- [Escapable](swift/escapable.md)
- [Sendable](swift/sendable.md)
- [SendableMetatype](swift/sendablemetatype.md)
- [TabularEstimator](createmlcomponents/tabularestimator.md)
- [UpdatableTabularEstimator](createmlcomponents/updatabletabularestimator.md)

## See Also

### Tabular components

- [TabularTransformer](createmlcomponents/tabulartransformer.md)
- [TabularEstimator](createmlcomponents/tabularestimator.md)
- [SupervisedTabularEstimator](createmlcomponents/supervisedtabularestimator.md)
- [ColumnSelectorTransformer](createmlcomponents/columnselectortransformer.md)
- [ColumnSelection](createmlcomponents/columnselection.md)
- [ColumnConcatenator](createmlcomponents/columnconcatenator.md)
- [PreprocessingSupervisedTabularEstimator](createmlcomponents/preprocessingsupervisedtabularestimator.md)
- [PreprocessingTabularEstimator](createmlcomponents/preprocessingtabularestimator.md)
- [PreprocessingUpdatableSupervisedTabularEstimator](createmlcomponents/preprocessingupdatablesupervisedtabularestimator.md)
- [PreprocessingUpdatableTabularEstimator](createmlcomponents/preprocessingupdatabletabularestimator.md)
