table

io.github.quafadas.table
object table

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any
Self type
table.type

Members list

Type members

Classlikes

Options for handling headers in tabular data.

Options for handling headers in tabular data.

This enum provides different strategies for obtaining column headers when reading data from sources like CSV files or Excel spreadsheets.

Attributes

Companion
object
Supertypes
trait Enum
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all
object HeaderOptions

Attributes

Companion
enum
Supertypes
trait Sum
trait Mirror
class Object
trait Matchable
class Any
Self type
enum ReadAs

Specifies how to read CSV data.

Specifies how to read CSV data.

  • Rows: Returns CsvIterator[K, V] - lazy row-by-row iteration
  • Columns: Returns NamedTuple[K, (Array[T1], Array[T2], ...)] - eager column arrays
  • ArrayDenseColMajor[T]: Returns a single dense array in column-major order
  • ArrayDenseRowMajor[T]: Returns a single dense array in row-major order

Attributes

Companion
object
Supertypes
trait Enum
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all
object ReadAs

Attributes

Companion
enum
Supertypes
trait Sum
trait Mirror
class Object
trait Matchable
class Any
Self type
ReadAs.type

Enumeration of strategies for inferring column types when reading CSV files.

Enumeration of strategies for inferring column types when reading CSV files.

  • FirstRow: Infers types by inspecting only the first row of data.
  • FirstN: Infers types by inspecting the first n rows. Optionally, prefers Int over Boolean if both are possible.
  • FromAllRows: Infers types by inspecting all rows in the CSV.
  • StringType: Disables type inference; all columns are read as String.
  • FromTuple[T]: Uses a user-supplied tuple type T for decoding, allowing custom or manual type specification.

Attributes

Companion
object
Supertypes
trait Enum
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all
object TypeInferrer

Attributes

Companion
enum
Supertypes
trait Sum
trait Mirror
class Object
trait Matchable
class Any
Self type

Exports

Defined exports

Exported from scautable
final type BasisPoints = [N <: Int] =>> BasisPoints[N]
Exported from ColumnFormat$
final val CSV: CSV
Exported from scautable
final val CellFormat: CellFormat
Exported from scautable
final type CellFormat = CellFormat
Exported from scautable
final type CsvIterator = [K <: Tuple, V <: Tuple] =>> CsvIterator[K, V]
Exported from scautable
final val CsvOpts: CsvOpts
Exported from scautable
final type CsvOpts = CsvOpts
Exported from scautable
final type Currency = [Sym <: String, N <: Int] =>> Currency[Sym, N]
Exported from ColumnFormat$
final type Decimals = [N <: Int] =>> Decimals[N]
Exported from ColumnFormat$
final val Excel: Excel
Exported from scautable
final type ExcelIterator = [K <: Tuple, V <: Tuple] =>> ExcelIterator[K, V]
Exported from scautable
final val ExcelOpts: ExcelOpts
Exported from scautable
final type ExcelOpts = ExcelOpts
Exported from scautable
Exported from scautable
final type InBillions = [N <: Int] =>> InBillions[N]
Exported from ColumnFormat$
final type InMillions = [N <: Int] =>> InMillions[N]
Exported from ColumnFormat$
final type InThousands = [N <: Int] =>> InThousands[N]
Exported from ColumnFormat$
final type IntThousands = IntThousands
Exported from ColumnFormat$
final val JsonTable: JsonTable
Exported from json
Exported from ColumnFormat$
final type Percent = [N <: Int] =>> Percent[N]
Exported from ColumnFormat$
final type SigFigs = [N <: Int] =>> SigFigs[N]
Exported from ColumnFormat$
final type StatsContext = StatsContext
Exported from Stats$
final type Thousands = Thousands
Exported from ColumnFormat$
transparent inline def absolutePath[K](inline filePath: String, inline sheetName: String, inline opts: ExcelOpts): ExcelIterator[_ <: Tuple, _ <: Tuple]
Exported from Excel

Read Excel file from an absolute path, configured with an ExcelOpts.

Read Excel file from an absolute path, configured with an ExcelOpts.

Use this when you need an option the positional overloads do not expose, such as skipFooter.

Attributes

transparent inline def absolutePath[K](filePath: String, sheetName: String, range: String = ..., inline typeInferrer: TypeInferrer = ...): ExcelIterator[_ <: Tuple, _ <: Tuple]
Exported from Excel

Read Excel file from an absolute path with compile-time type inference

Read Excel file from an absolute path with compile-time type inference

Value parameters

filePath

Absolute path to the Excel file

range

Optional cell range, empty string reads entire sheet. Either fully specified ("A1:C10"), or a top left anchor whose open edges are discovered at compile time the way ctrl-right and ctrl-down discover them in Excel - "A1" infers both edges, "A1:C" pins the columns, "A1:10" pins the rows

sheetName

Name of the Excel sheet to read

typeInferrer

Type inference strategy (StringType or FromTuple supported)

Attributes

Returns

ExcelIterator with inferred types

export basisPoints: [N <: Int] => ValueOf[N]
Exported from CellFormat
export currency: [Sym <: String, N <: Int] => (ValueOf[Sym], ValueOf[N])
Exported from CellFormat
export decimals: [N <: Int] => ValueOf[N]
Exported from CellFormat
Exported from ExcelDecoders
export inBillions: [N <: Int] => ValueOf[N]
Exported from CellFormat
export inMillions: [N <: Int] => ValueOf[N]
Exported from CellFormat
export inThousands: [N <: Int] => ValueOf[N]
Exported from CellFormat
export intThousands
Exported from CellFormat
export longThousands
Exported from CellFormat
export option: [A] => CellFormat[A]
Exported from CellFormat

A tagged column read from a CSV with blanks arrives as Option[Tag]; render through the inner format. None stays "None" so untagged output is unchanged.

A tagged column read from a CSV with blanks arrives as Option[Tag]; render through the inner format. None stays "None" so untagged output is unchanged.

Attributes

export percent: [N <: Int] => ValueOf[N]
Exported from CellFormat
transparent inline def projectRoot[K](inline filePath: String, inline sheetName: String, inline opts: ExcelOpts): ExcelIterator[_ <: Tuple, _ <: Tuple]
Exported from Excel

Read an Excel file relative to the discovered project root, configured with an ExcelOpts.

Read an Excel file relative to the discovered project root, configured with an ExcelOpts.

Use this when you need an option the positional overloads do not expose, such as skipFooter.

Attributes

transparent inline def projectRoot[K](filePath: String, sheetName: String, inline typeInferrer: TypeInferrer): ExcelIterator[_ <: Tuple, _ <: Tuple]
Exported from Excel
transparent inline def projectRoot[K](filePath: String, sheetName: String, range: String = ..., inline typeInferrer: TypeInferrer = ...): ExcelIterator[_ <: Tuple, _ <: Tuple]
Exported from Excel

Read an Excel file at a path relative to the discovered project root, with compile-time type inference.

Read an Excel file at a path relative to the discovered project root, with compile-time type inference.

The root is the first ancestor of the calling source file holding a build marker (build.mill, build.sbt, .git, ...). In a notebook or REPL there is no source file on disk to search upwards from, so the root is discovered from the working directory instead and a compile time warning says so.

Value parameters

filePath

Path to the Excel file, relative to the project root

range

Optional cell range, empty string reads entire sheet. Either fully specified ("A1:C10"), or a top left anchor whose open edges are discovered at compile time the way ctrl-right and ctrl-down discover them in Excel - "A1" infers both edges, "A1:C" pins the columns, "A1:10" pins the rows

sheetName

Name of the Excel sheet to read

typeInferrer

Type inference strategy (StringType or FromTuple supported)

Attributes

Returns

ExcelIterator with inferred types

transparent inline def relativeToSource[K](inline filePath: String, inline sheetName: String, inline opts: ExcelOpts): ExcelIterator[_ <: Tuple, _ <: Tuple]
Exported from Excel

Read an Excel file relative to the calling source file, configured with an ExcelOpts.

Read an Excel file relative to the calling source file, configured with an ExcelOpts.

Use this when you need an option the positional overloads do not expose, such as skipFooter.

Attributes

transparent inline def relativeToSource[K](filePath: String, sheetName: String, inline typeInferrer: TypeInferrer): ExcelIterator[_ <: Tuple, _ <: Tuple]
Exported from Excel
transparent inline def relativeToSource[K](filePath: String, sheetName: String, range: String = ..., inline typeInferrer: TypeInferrer = ...): ExcelIterator[_ <: Tuple, _ <: Tuple]
Exported from Excel

Read an Excel file at a path relative to the source file this is called from, with compile-time type inference.

Read an Excel file at a path relative to the source file this is called from, with compile-time type inference.

The path is anchored to the calling source file rather than to the compiler's working directory, so it resolves the same way no matter where the build was invoked from. In a notebook or REPL there is no source file on disk, so the path resolves against the working directory instead and a compile time warning says so.

Value parameters

filePath

Path to the Excel file, relative to the calling source file

range

Optional cell range, empty string reads entire sheet. Either fully specified ("A1:C10"), or a top left anchor whose open edges are discovered at compile time the way ctrl-right and ctrl-down discover them in Excel - "A1" infers both edges, "A1:C" pins the columns, "A1:10" pins the rows

sheetName

Name of the Excel sheet to read

typeInferrer

Type inference strategy (StringType or FromTuple supported)

Attributes

Returns

ExcelIterator with inferred types

transparent inline def resource[K](inline filePath: String, inline sheetName: String, inline opts: ExcelOpts): ExcelIterator[_ <: Tuple, _ <: Tuple]
Exported from Excel

Read Excel file from the classpath, configured with an ExcelOpts.

Read Excel file from the classpath, configured with an ExcelOpts.

Use this when you need an option the positional overloads do not expose, such as skipFooter.

Value parameters

filePath

Path to the Excel file in the classpath

opts

Range, type inference and footer handling

sheetName

Name of the Excel sheet to read

Attributes

Returns

ExcelIterator with inferred types

transparent inline def resource[K](filePath: String, sheetName: String): ExcelIterator[_ <: Tuple, _ <: Tuple]
Exported from Excel
transparent inline def resource[K](filePath: String, sheetName: String, inline typeInferrer: TypeInferrer): ExcelIterator[_ <: Tuple, _ <: Tuple]
Exported from Excel
transparent inline def resource[K](filePath: String, sheetName: String, range: String = ..., inline typeInferrer: TypeInferrer = ...): ExcelIterator[_ <: Tuple, _ <: Tuple]
Exported from Excel

Read Excel file from the classpath with compile-time type inference

Read Excel file from the classpath with compile-time type inference

Value parameters

filePath

Path to the Excel file in the classpath

range

Optional cell range, empty string reads entire sheet. Either fully specified ("A1:C10"), or a top left anchor whose open edges are discovered at compile time the way ctrl-right and ctrl-down discover them in Excel - "A1" infers both edges, "A1:C" pins the columns, "A1:10" pins the rows

sheetName

Name of the Excel sheet to read

typeInferrer

Type inference strategy (StringType or FromTuple supported)

Attributes

Returns

ExcelIterator with inferred types

export sigFigsFormat: [N <: Int] => ValueOf[N]
Exported from CellFormat
export thousands
Exported from CellFormat