Skip to content

pl.cs (Column Selectors) ​

Namespace: Polars.FSharp

Column selectors.

Module Functions ​

pl.cs.all ​

Select all columns.

fsharp
pl.cs.all : unit -> Selector

pl.cs.alpha ​

Select all columns with alphabetic names.

fsharp
pl.cs.alpha : asciiOnly: bool -> ignoreSpaces: bool -> Selector

Parameters

NameTypeDescription
asciiOnlybool-
ignoreSpacesbool-

pl.cs.alphanumeric ​

Select all columns with alphanumeric names.

fsharp
pl.cs.alphanumeric : asciiOnly: bool -> ignoreSpaces: bool -> Selector

Parameters

NameTypeDescription
asciiOnlybool-
ignoreSpacesbool-

pl.cs.array ​

Select array columns. Optionally filter by inner data type and fixed width. Example: pl.cs.array (Some(pl.cs.numeric())) (Some 3L)

fsharp
pl.cs.array : inner: Selector option -> width: int64 option -> Selector

Parameters

NameTypeDescription
innerSelector option-
widthint64 option-

pl.cs.arrayAll ​

Select all array columns.

fsharp
pl.cs.arrayAll : unit -> Selector

pl.cs.binary ​

Select binary columns.

fsharp
pl.cs.binary : unit -> Selector

pl.cs.boolean ​

Select boolean columns.

fsharp
pl.cs.boolean : unit -> Selector

pl.cs.byIndex ​

Select columns by their index with.

fsharp
pl.cs.byIndex : indices: ReadOnlySpan<int64> -> Selector

Parameters

NameTypeDescription
indicesReadOnlySpan<int64>-

pl.cs.byIndexStrict ​

Select columns by their index. Usage: cs.byIndex(0L, 2L, 4L)

fsharp
pl.cs.byIndexStrict : indices: ReadOnlySpan<int64> -> Selector

Parameters

NameTypeDescription
indicesReadOnlySpan<int64>-

pl.cs.byName ​

Select a single column by name.

fsharp
pl.cs.byName : names: seq<string> -> Selector

Parameters

NameTypeDescription
namesseq<string>-

pl.cs.byNetType ​

Select columns by Generic Type. Usage: pl.cs.byType<int option>() or pl.cs.byType<DateTime>()

fsharp
pl.cs.byNetType : unit -> Selector

pl.cs.byType ​

Select columns by DataType.

fsharp
pl.cs.byType : dt: DataType -> Selector

Parameters

NameTypeDescription
dtDataType-

pl.cs.cjkCols ​

[EN] Select columns whose names consist of CJK scripts, Unicode digits (\p{N}), and optionally ASCII/full-width Latin letters.

[ZH] 选择列名由中日韩字符、数字(\p{N},含全/半角)以及可选英文字母(全/半角)组成的列。

[JA] 列名がCJK文字・数字(\p{N}、全角/半角)および英字(全角/半角)で構成される列を選択します。

[KO] 열 이름이 CJK 문자, 숫자(\p{N}, 전각/반각) 및 영문자(전각/반각)로 구성된 열을 선택합니다.

fsharp
pl.cs.cjkCols : opts: CjkColumnOptions -> Selector

Parameters

NameTypeDescription
optsCjkColumnOptions-

pl.cs.contains ​

Select columns containing a pattern.

fsharp
pl.cs.contains : pattern: string -> Selector

Parameters

NameTypeDescription
patternstring-

pl.cs.date ​

Select date columns.

fsharp
pl.cs.date : unit -> Selector

pl.cs.datetime ​

Select all datetime columns (both with and without timezones).

fsharp
pl.cs.datetime : timeUnit: TimeUnit -> Selector

Parameters

NameTypeDescription
timeUnitTimeUnit-

pl.cs.datetimeAware ​

Select ONLY timezone-aware datetime columns (any timezone).

fsharp
pl.cs.datetimeAware : timeUnit: TimeUnit -> Selector

Parameters

NameTypeDescription
timeUnitTimeUnit-

pl.cs.datetimeExact ​

Select datetime columns matching a specific timezone (e.g., "UTC", "Asia/Shanghai").

fsharp
pl.cs.datetimeExact : timeZone: string -> timeUnit: TimeUnit -> Selector

Parameters

NameTypeDescription
timeZonestring-
timeUnitTimeUnit-

pl.cs.datetimeNaive ​

Select ONLY timezone-naive datetime columns (no timezone set).

fsharp
pl.cs.datetimeNaive : timeUnit: TimeUnit -> Selector

Parameters

NameTypeDescription
timeUnitTimeUnit-

pl.cs.decimal ​

Select decimal columns.

fsharp
pl.cs.decimal : unit -> Selector

pl.cs.duration ​

Select all duration columns. Optionally match a specific TimeUnit.

fsharp
pl.cs.duration : timeUnit: TimeUnit -> Selector

Parameters

NameTypeDescription
timeUnitTimeUnit-

pl.cs.empty ​

Select empty columns.

fsharp
pl.cs.empty : unit -> Selector

pl.cs.endsWith ​

Select columns ending with a pattern.

fsharp
pl.cs.endsWith : pattern: string -> Selector

Parameters

NameTypeDescription
patternstring-

pl.cs.enum ​

Select enum columns.

fsharp
pl.cs.enum : unit -> Selector

pl.cs.exclude ​

Select all columns EXCEPT the specified Selectors.

fsharp
pl.cs.exclude : selectors: seq<Selector> -> Selector

Parameters

NameTypeDescription
selectorsseq<Selector>-

pl.cs.excludeDataType ​

Select all columns EXCEPT the specified Data Types.

fsharp
pl.cs.excludeDataType : dtypes: seq<DataType> -> Selector

Parameters

NameTypeDescription
dtypesseq<DataType>-

pl.cs.expandDf ​

Expand a Selector against a DataFrame to get the matched column names.

fsharp
pl.cs.expandDf : selector: IColumnExpr -> target: DataFrame -> string[]

Parameters

NameTypeDescription
selectorIColumnExpr-
targetDataFrame-

pl.cs.expandLf ​

Expand a Selector against a LazyFrame to get the matched column names.

fsharp
pl.cs.expandLf : selector: IColumnExpr -> target: LazyFrame -> string[]

Parameters

NameTypeDescription
selectorIColumnExpr-
targetLazyFrame-

pl.cs.first ​

Select the first column.

fsharp
pl.cs.first : unit -> Selector

pl.cs.float ​

Select float columns.

fsharp
pl.cs.float : unit -> Selector

pl.cs.integer ​

Select integer columns.

fsharp
pl.cs.integer : unit -> Selector

pl.cs.last ​

Select the last column.

fsharp
pl.cs.last : unit -> Selector

pl.cs.list ​

Select list columns. Optionally filter by the inner data type. Example: pl.cs.list(Some(pl.cs.numeric()))

fsharp
pl.cs.list : inner: Selector option -> Selector

Parameters

NameTypeDescription
innerSelector option-

pl.cs.listAll ​

Select all list columns.

fsharp
pl.cs.listAll : unit -> Selector

pl.cs.matches ​

Select columns matching a regex pattern.

fsharp
pl.cs.matches : regex: string -> Selector

Parameters

NameTypeDescription
regexstring-

pl.cs.nested ​

Select nested columns.

fsharp
pl.cs.nested : unit -> Selector

pl.cs.numeric ​

Select numeric columns (Int, Float, Decimal).

fsharp
pl.cs.numeric : unit -> Selector

pl.cs.signedInteger ​

Select signed integer columns.

fsharp
pl.cs.signedInteger : unit -> Selector

pl.cs.startsWith ​

Select columns starting with a pattern.

fsharp
pl.cs.startsWith : pattern: string -> Selector

Parameters

NameTypeDescription
patternstring-

pl.cs.string ​

Select string columns.

fsharp
pl.cs.string : unit -> Selector

pl.cs.structType ​

Select struct columns.

fsharp
pl.cs.structType : unit -> Selector

pl.cs.temporal ​

Select temporal columns.

fsharp
pl.cs.temporal : unit -> Selector

pl.cs.unsignedInteger ​

Select unsigned integer columns.

fsharp
pl.cs.unsignedInteger : unit -> Selector

Released under the MIT License. Powered by the Polars Rust core & Apache Arrow.