databricks / LearningSparkV2

This is the github repo for Learning Spark: Lightning-Fast Data Analytics [2nd Edition]
https://learning.oreilly.com/library/view/learning-spark-2nd/9781492050032/
Apache License 2.0
1.2k stars 728 forks source link

Error p 309. Chapter 10 - Decision trees code example #59

Closed raybellwaves closed 4 years ago

raybellwaves commented 4 years ago

In the following code example I couldn't see where indexOutputCols is defined

IMG_5162

brookewenig commented 4 years ago

Excellent point! We defined indexOutputCols earlier when we built a model using linear regression, and omitted it here, along with the StringIndexer, to reduce repetitive code. You can see it's defined on pg 299