delete_if

delete_if(&block) Instance Public methods Removes any column or row for which the block returns true. In the default mixed mode or row mode, iteration is the standard row major walking of rows. In column mode, interation will yield two element tuples containing the column name and an Array of values for that column. This method returns the table for chaining.

delete

delete(index_or_header) Instance Public methods Removes and returns the indicated column or row. In the default mixed mode indices refer to rows and everything else is assumed to be a column header. Use #by_col!() or #by_row!() to force the lookup.

by_row!

by_row!() Instance Public methods Switches the mode of this table to row mode. All calls to indexing and iteration methods will work with rows until the mode is changed again. This method returns the table and is safe to chain.

by_row

by_row() Instance Public methods Returns a duplicate table object, in row mode. This is handy for chaining in a single call without changing the table mode, but be aware that this method can consume a fair amount of memory for bigger data sets. This method returns the duplicate table for chaining. Don't chain destructive methods (like []=()) this way though, since you are working with a duplicate.

by_col_or_row!

by_col_or_row!() Instance Public methods Switches the mode of this table to mixed mode. All calls to indexing and iteration methods will use the default intelligent indexing system until the mode is changed again. In mixed mode an index is assumed to be a row reference while anything else is assumed to be column access by headers. This method returns the table and is safe to chain.

by_col_or_row

by_col_or_row() Instance Public methods Returns a duplicate table object, in mixed mode. This is handy for chaining in a single call without changing the table mode, but be aware that this method can consume a fair amount of memory for bigger data sets. This method returns the duplicate table for chaining. Don't chain destructive methods (like []=()) this way though, since you are working with a duplicate.

by_col!

by_col!() Instance Public methods Switches the mode of this table to column mode. All calls to indexing and iteration methods will work with columns until the mode is changed again. This method returns the table and is safe to chain.

by_col

by_col() Instance Public methods Returns a duplicate table object, in column mode. This is handy for chaining in a single call without changing the table mode, but be aware that this method can consume a fair amount of memory for bigger data sets. This method returns the duplicate table for chaining. Don't chain destructive methods (like []=()) this way though, since you are working with a duplicate.

[]=

[]=(index_or_header, value) Instance Public methods In the default mixed mode, this method assigns rows for index access and columns for header access. You can force the index association by first calling #by_col!() or #by_row!(). Rows may be set to an Array of values (which will inherit the table's headers()) or a CSV::Row. Columns may be set to a single value, which is copied to each row of the column, or an Array of values. Arrays of values are assigned to rows top to bottom i

[]

[](index_or_header) Instance Public methods In the default mixed mode, this method returns rows for index access and columns for header access. You can force the index association by first calling #by_col!() or #by_row!(). Columns are returned as an Array of values. Altering that Array has no effect on the table.