Options
All
  • Public
  • Public/Protected
  • All
Menu

Class GroupByMultiple<T, R, IndexKey>

Type parameters

  • T: TypeMap

  • R: keyof T

  • IndexKey: string

Hierarchy

  • GroupByBase<T, R>
    • GroupByMultiple

Index

Constructors

constructor

Methods

argmax

  • argmax(memoryResource?: MemoryResource): DataFrame<{ [ P in string]: { [ P in string]: Struct<{ [ P in string | number | symbol]: Pick<{ [ P in string | number | symbol]: P extends R ? T[P] : Int32 }, R>[P] }> } & Omit<{ [ P in string | number | symbol]: P extends R ? T[P] : Int32 }, R>[P] }>
  • Compute the index of the maximum value in each group

    Parameters

    • Optional memoryResource: MemoryResource

      The optional MemoryResource used to allocate the result's device memory.

    Returns DataFrame<{ [ P in string]: { [ P in string]: Struct<{ [ P in string | number | symbol]: Pick<{ [ P in string | number | symbol]: P extends R ? T[P] : Int32 }, R>[P] }> } & Omit<{ [ P in string | number | symbol]: P extends R ? T[P] : Int32 }, R>[P] }>

argmin

  • argmin(memoryResource?: MemoryResource): DataFrame<{ [ P in string]: { [ P in string]: Struct<{ [ P in string | number | symbol]: Pick<{ [ P in string | number | symbol]: P extends R ? T[P] : Int32 }, R>[P] }> } & Omit<{ [ P in string | number | symbol]: P extends R ? T[P] : Int32 }, R>[P] }>
  • Compute the index of the minimum value in each group

    Parameters

    • Optional memoryResource: MemoryResource

      The optional MemoryResource used to allocate the result's device memory.

    Returns DataFrame<{ [ P in string]: { [ P in string]: Struct<{ [ P in string | number | symbol]: Pick<{ [ P in string | number | symbol]: P extends R ? T[P] : Int32 }, R>[P] }> } & Omit<{ [ P in string | number | symbol]: P extends R ? T[P] : Int32 }, R>[P] }>

collectList

  • collectList(include_nulls?: boolean, memoryResource?: MemoryResource): DataFrame<{ [ P in string]: { [ P in string]: Struct<{ [ P in string | number | symbol]: Pick<{ [ P in string | number | symbol]: P extends R ? T[P] : List<T[P]> }, R>[P] }> } & Omit<{ [ P in string | number | symbol]: P extends R ? T[P] : List<T[P]> }, R>[P] }>
  • Returns a list column of all included elements in the group.

    Parameters

    • include_nulls: boolean = true
    • Optional memoryResource: MemoryResource

      The optional MemoryResource used to allocate the result's device memory.

    Returns DataFrame<{ [ P in string]: { [ P in string]: Struct<{ [ P in string | number | symbol]: Pick<{ [ P in string | number | symbol]: P extends R ? T[P] : List<T[P]> }, R>[P] }> } & Omit<{ [ P in string | number | symbol]: P extends R ? T[P] : List<T[P]> }, R>[P] }>

collectSet

  • collectSet(include_nulls?: boolean, nulls_equal?: boolean, nans_equal?: boolean, memoryResource?: MemoryResource): DataFrame<{ [ P in string]: { [ P in string]: Struct<{ [ P in string | number | symbol]: Pick<{ [ P in string | number | symbol]: P extends R ? T[P] : List<T[P]> }, R>[P] }> } & Omit<{ [ P in string | number | symbol]: P extends R ? T[P] : List<T[P]> }, R>[P] }>
  • Returns a lists column of all included elements in the group/series. Within each list, the duplicated entries are dropped out such that each entry appears only once.

    Parameters

    • include_nulls: boolean = true
    • nulls_equal: boolean = true
    • nans_equal: boolean = false
    • Optional memoryResource: MemoryResource

      The optional MemoryResource used to allocate the result's device memory.

    Returns DataFrame<{ [ P in string]: { [ P in string]: Struct<{ [ P in string | number | symbol]: Pick<{ [ P in string | number | symbol]: P extends R ? T[P] : List<T[P]> }, R>[P] }> } & Omit<{ [ P in string | number | symbol]: P extends R ? T[P] : List<T[P]> }, R>[P] }>

count

  • count(memoryResource?: MemoryResource): DataFrame<{ [ P in string]: { [ P in string]: Struct<{ [ P in string | number | symbol]: Pick<{ [ P in string | number | symbol]: P extends R ? T[P] : Int32 }, R>[P] }> } & Omit<{ [ P in string | number | symbol]: P extends R ? T[P] : Int32 }, R>[P] }>
  • Compute the size of each group

    Parameters

    • Optional memoryResource: MemoryResource

      The optional MemoryResource used to allocate the result's device memory.

    Returns DataFrame<{ [ P in string]: { [ P in string]: Struct<{ [ P in string | number | symbol]: Pick<{ [ P in string | number | symbol]: P extends R ? T[P] : Int32 }, R>[P] }> } & Omit<{ [ P in string | number | symbol]: P extends R ? T[P] : Int32 }, R>[P] }>

getGroups

  • getGroups(memoryResource?: MemoryResource): Groups<Pick<T, R>, Omit<T, R>>
  • Return the Groups for this GroupBy

    Parameters

    • Optional memoryResource: MemoryResource

      The optional MemoryResource used to allocate the result's device memory.

    Returns Groups<Pick<T, R>, Omit<T, R>>

max

  • max(memoryResource?: MemoryResource): DataFrame<{ [ P in string]: { [ P in string]: Struct<{ [ P in string | number | symbol]: Pick<T, R>[P] }> } & Omit<T, R>[P] }>
  • Compute the maximum value in each group

    Parameters

    • Optional memoryResource: MemoryResource

      The optional MemoryResource used to allocate the result's device memory.

    Returns DataFrame<{ [ P in string]: { [ P in string]: Struct<{ [ P in string | number | symbol]: Pick<T, R>[P] }> } & Omit<T, R>[P] }>

mean

  • mean(memoryResource?: MemoryResource): DataFrame<{ [ P in string]: { [ P in string]: Struct<{ [ P in string | number | symbol]: Pick<T, R>[P] }> } & Omit<T, R>[P] }>
  • Compute the average value each group

    Parameters

    • Optional memoryResource: MemoryResource

      The optional MemoryResource used to allocate the result's device memory.

    Returns DataFrame<{ [ P in string]: { [ P in string]: Struct<{ [ P in string | number | symbol]: Pick<T, R>[P] }> } & Omit<T, R>[P] }>

median

  • median(memoryResource?: MemoryResource): DataFrame<{ [ P in string]: { [ P in string]: Struct<{ [ P in string | number | symbol]: Pick<T, R>[P] }> } & Omit<T, R>[P] }>
  • Compute the median value in each group

    Parameters

    • Optional memoryResource: MemoryResource

      The optional MemoryResource used to allocate the result's device memory.

    Returns DataFrame<{ [ P in string]: { [ P in string]: Struct<{ [ P in string | number | symbol]: Pick<T, R>[P] }> } & Omit<T, R>[P] }>

min

  • min(memoryResource?: MemoryResource): DataFrame<{ [ P in string]: { [ P in string]: Struct<{ [ P in string | number | symbol]: Pick<T, R>[P] }> } & Omit<T, R>[P] }>
  • Compute the minimum value in each group

    Parameters

    • Optional memoryResource: MemoryResource

      The optional MemoryResource used to allocate the result's device memory.

    Returns DataFrame<{ [ P in string]: { [ P in string]: Struct<{ [ P in string | number | symbol]: Pick<T, R>[P] }> } & Omit<T, R>[P] }>

nth

  • nth(n: number, include_nulls?: boolean, memoryResource?: MemoryResource): DataFrame<{ [ P in string]: { [ P in string]: Struct<{ [ P in string | number | symbol]: Pick<T, R>[P] }> } & Omit<T, R>[P] }>
  • Return the nth value from each group

    Parameters

    • n: number

      the index of the element to return

    • include_nulls: boolean = true
    • Optional memoryResource: MemoryResource

      The optional MemoryResource used to allocate the result's device memory.

    Returns DataFrame<{ [ P in string]: { [ P in string]: Struct<{ [ P in string | number | symbol]: Pick<T, R>[P] }> } & Omit<T, R>[P] }>

nunique

  • nunique(include_nulls?: boolean, memoryResource?: MemoryResource): DataFrame<{ [ P in string]: { [ P in string]: Struct<{ [ P in string | number | symbol]: Pick<{ [ P in string | number | symbol]: P extends R ? T[P] : Int32 }, R>[P] }> } & Omit<{ [ P in string | number | symbol]: P extends R ? T[P] : Int32 }, R>[P] }>
  • Compute the number of unique values in each group

    Parameters

    • include_nulls: boolean = false
    • Optional memoryResource: MemoryResource

      The optional MemoryResource used to allocate the result's device memory.

    Returns DataFrame<{ [ P in string]: { [ P in string]: Struct<{ [ P in string | number | symbol]: Pick<{ [ P in string | number | symbol]: P extends R ? T[P] : Int32 }, R>[P] }> } & Omit<{ [ P in string | number | symbol]: P extends R ? T[P] : Int32 }, R>[P] }>

quantile

  • quantile(q?: number, interpolation?: "linear" | "lower" | "higher" | "midpoint" | "nearest", memoryResource?: MemoryResource): DataFrame<{ [ P in string]: { [ P in string]: Struct<{ [ P in string | number | symbol]: Pick<T, R>[P] }> } & Omit<T, R>[P] }>
  • Return values at the given quantile.

    Parameters

    • q: number = 0.5

      the quantile to compute, 0 <= q <= 1

    • interpolation: "linear" | "lower" | "higher" | "midpoint" | "nearest" = 'linear'

      This optional parameter specifies the interpolation method to use, when the desired quantile lies between two data points i and j.

    • Optional memoryResource: MemoryResource

      The optional MemoryResource used to allocate the result's device memory.

    Returns DataFrame<{ [ P in string]: { [ P in string]: Struct<{ [ P in string | number | symbol]: Pick<T, R>[P] }> } & Omit<T, R>[P] }>

std

  • std(ddof?: number, memoryResource?: MemoryResource): DataFrame<{ [ P in string]: { [ P in string]: Struct<{ [ P in string | number | symbol]: Pick<T, R>[P] }> } & Omit<T, R>[P] }>
  • Compute the standard deviation for each group

    Parameters

    • ddof: number = 1
    • Optional memoryResource: MemoryResource

      The optional MemoryResource used to allocate the result's device memory.

    Returns DataFrame<{ [ P in string]: { [ P in string]: Struct<{ [ P in string | number | symbol]: Pick<T, R>[P] }> } & Omit<T, R>[P] }>

sum

  • sum(memoryResource?: MemoryResource): DataFrame<{ [ P in string]: { [ P in string]: Struct<{ [ P in string | number | symbol]: Pick<T, R>[P] }> } & Omit<T, R>[P] }>
  • Compute the sum of values in each group

    Parameters

    • Optional memoryResource: MemoryResource

      The optional MemoryResource used to allocate the result's device memory.

    Returns DataFrame<{ [ P in string]: { [ P in string]: Struct<{ [ P in string | number | symbol]: Pick<T, R>[P] }> } & Omit<T, R>[P] }>

var

  • var(ddof?: number, memoryResource?: MemoryResource): DataFrame<{ [ P in string]: { [ P in string]: Struct<{ [ P in string | number | symbol]: Pick<T, R>[P] }> } & Omit<T, R>[P] }>
  • Compute the variance for each group

    Parameters

    • ddof: number = 1
    • Optional memoryResource: MemoryResource

      The optional MemoryResource used to allocate the result's device memory.

    Returns DataFrame<{ [ P in string]: { [ P in string]: Struct<{ [ P in string | number | symbol]: Pick<T, R>[P] }> } & Omit<T, R>[P] }>