Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Column ¶
type Column interface { // Name returns the current name of this column Name() string // contains filtered or unexported methods }
type DataFrame ¶
type DataFrame struct {
// contains filtered or unexported fields
}
func DataFrameFromCSV ¶
func (*DataFrame) Builder ¶
func (d *DataFrame) Builder() DataFrameBuilder
func (*DataFrame) Col ¶
func (d *DataFrame) Col(colName string) *ExistingCol
type DataFrameBuilder ¶
type DataFrameBuilder struct {
// contains filtered or unexported fields
}
DataFrameBuilder is an error-safe construct to connect a series of DataFrame transformations together. Create one of these from an existing DataFrame by calling its Builder() method.
func (DataFrameBuilder) Collect ¶
func (d DataFrameBuilder) Collect(ctx context.Context) ([]*Row, error)
Collect is a convenience function for roughly the following:
df, err := d.Execute(ctx) if err != nil { return nil, fmt.Errorf("collecting: %w", err) } return df.Collect(ctx)
func (DataFrameBuilder) Execute ¶
func (d DataFrameBuilder) Execute(ctx context.Context) (*DataFrame, error)
Execute executes all transforms in d and returns the resulting DataFrame. If any transform fails, execution is immediately halted and the error is returned.
func (DataFrameBuilder) Select ¶
func (d DataFrameBuilder) Select(cols ...Column) DataFrameBuilder
Select appends a call to df.Select(ctx, cols) to the end of the set of transforms.
type ExistingCol ¶
type ExistingCol struct {
// contains filtered or unexported fields
}
ExistingCol is a Column implementation that simply references a column that already exists in a DataFrame.
Call either the Col or DataFrame.Col functions to create one of these.
func Col ¶
func Col(name string) *ExistingCol
func (*ExistingCol) Name ¶
func (e *ExistingCol) Name() string