Step 3 - Loading and parsing input data

We load and get the transaction. Then we get the distribution:

val inputCSV = "data/creditcard.csv"val transactions = spark.read.format("com.databricks.spark.csv")        .option("header", "true")        .option("inferSchema", true)        .load(inputCSV)

Get Scala Machine Learning Projects now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.