The Analysis object provides factory methods to analyze tables from various sources.
Example usage:
// Analyze a CSV-sourced RawTable
val stats: ColumnStatistics = Analysis(rawTable)
// Analyze a CSV file by Path
implicit val parser: RawTableParser = RawTableParser()
val stats: ColumnStatistics = Analysis.forCsv(Path.of("data.csv"))
// Analyze a Parquet file (requires parquet module in scope)
val stats: ColumnStatistics = Analysis.forParquet[YellowTaxiTrip](Path.of("data.parquet"))
Analyze a single Parquet file by Path. Fails if path is a directory; use forParquetDataset for dataset directories. Requires the parquet module to be in scope: import com.phasmidsoftware.tableparser.parquet._
Analyze a single Parquet file by Path. Fails if path is a directory; use forParquetDataset for dataset directories. Requires the parquet module to be in scope: import com.phasmidsoftware.tableparser.parquet._
Type parameters
Row
the target case class type.
Value parameters
path
the path to a .parquet file.
singleFileFactory
implicit single-file analyzer factory from parquet module.
Analyze a Parquet dataset directory by Path. Fails if path is not a directory; use forParquet for single files. Requires the parquet module to be in scope: import com.phasmidsoftware.tableparser.parquet._
Analyze a Parquet dataset directory by Path. Fails if path is not a directory; use forParquet for single files. Requires the parquet module to be in scope: import com.phasmidsoftware.tableparser.parquet._
Type parameters
Row
the target case class type.
Value parameters
datasetFactory
implicit dataset analyzer factory from parquet module.
path
the path to a dataset directory containing part-*.parquet files.