Project [CASE WHEN ((fractile#94260774 = NA) OR (fractile#94260774 = null)) THEN null ELSE cast(fractile#94260774 as int) END AS fractile#94260822, CASE WHEN (cap#94260775 = null) THEN null ELSE cap#94260775 END AS cap#94260823, CASE WHEN ((size#94260776 = NA) OR (size#94260776 = null)) THEN null ELSE cast(size#94260776 as float) END AS size#94260824, CASE WHEN ((value#94260777 = NA) OR (value#94260777 = null)) THEN null ELSE cast(value#94260777 as float) END AS value#94260825, CASE WHEN ((growth#94260778 = NA) OR (growth#94260778 = null)) THEN null ELSE cast(growth#94260778 as float) END AS growth#94260826, CASE WHEN ((leverage#94260779 = NA) OR (leverage#94260779 = null)) THEN null ELSE cast(leverage#94260779 as float) END AS leverage#94260827, CASE WHEN ((volatility#94260780 = NA) OR (volatility#94260780 = null)) THEN null ELSE cast(volatility#94260780 as float) END AS volatility#94260828, CASE WHEN ((momentum#94260781 = NA) OR (momentum#94260781 = null)) THEN null ELSE cast(momentum#94260781 as float) END AS momentum#94260829, CASE WHEN ((yield#94260782 = NA) OR (yield#94260782 = null)) THEN null ELSE cast(yield#94260782 as float) END AS yield#94260830, CASE WHEN ((##94260783 = NA) OR (##94260783 = null)) THEN null ELSE cast(##94260783 as float) END AS ##94260831, CASE WHEN (min_date#94260784 = null) THEN null ELSE cast(min_date#94260784 as date) END AS min_date#94260832, CASE WHEN (max_date#94260785 = null) THEN null ELSE cast(max_date#94260785 as date) END AS max_date#94260833]
Project [CASE WHEN ((cap#94160377 = NA) OR (cap#94160377 = null)) THEN null ELSE cast(cap#94160377 as int) END AS cap#94160394, CASE WHEN (sort#94160378 = null) THEN null ELSE sort#94160378 END AS sort#94160395, CASE WHEN (description#94160379 = null) THEN null ELSE description#94160379 END AS description#94160396, CASE WHEN ((universe#94160380 = NA) OR (universe#94160380 = null)) THEN null ELSE cast(universe#94160380 as int) END AS universe#94160397]
== Physical Plan ==
CollectLimit (20)
+- InMemoryTableScan (1)
+- InMemoryRelation (2)
+- * Sort (19)
+- Exchange (18)
+- * Project (17)
+- * BroadcastHashJoin Inner BuildRight (16)
:- * Project (8)
: +- * Filter (7)
: +- InMemoryTableScan (3)
: +- InMemoryRelation (4)
: +- * Project (6)
: +- Scan csv (5)
+- BroadcastExchange (15)
+- * Project (14)
+- * Filter (13)
+- InMemoryTableScan (9)
+- InMemoryRelation (10)
+- * Project (12)
+- Scan csv (11)
(1) InMemoryTableScan
Output [11]: [fractile#94260822, size#94260824, value#94260825, growth#94260826, leverage#94260827, volatility#94260828, momentum#94260829, yield#94260830, ##94260831, min_date#94260832, max_date#94260833]
Arguments: [fractile#94260822, size#94260824, value#94260825, growth#94260826, leverage#94260827, volatility#94260828, momentum#94260829, yield#94260830, ##94260831, min_date#94260832, max_date#94260833]
(2) InMemoryRelation
Arguments: [fractile#94260822, size#94260824, value#94260825, growth#94260826, leverage#94260827, volatility#94260828, momentum#94260829, yield#94260830, ##94260831, min_date#94260832, max_date#94260833], CachedRDDBuilder(org.apache.spark.sql.execution.columnar.DefaultCachedBatchSerializer@208e3fd9,StorageLevel(disk, memory, deserialized, 1 replicas),*(3) Sort [fractile#94260822 ASC NULLS FIRST], true, 0
+- Exchange rangepartitioning(fractile#94260822 ASC NULLS FIRST, 200), ENSURE_REQUIREMENTS, [id=#7525913]
+- *(2) Project [fractile#94260822, size#94260824, value#94260825, growth#94260826, leverage#94260827, volatility#94260828, momentum#94260829, yield#94260830, ##94260831, min_date#94260832, max_date#94260833]
+- *(2) BroadcastHashJoin [cap_description#94260846], [description#94160396], Inner, BuildRight, false
:- *(2) Project [fractile#94260822, cap#94260823 AS cap_description#94260846, size#94260824, value#94260825, growth#94260826, leverage#94260827, volatility#94260828, momentum#94260829, yield#94260830, ##94260831, min_date#94260832, max_date#94260833]
: +- *(2) Filter ((isnotnull(fractile#94260822) AND NOT (fractile#94260822 = -1)) AND isnotnull(cap#94260823))
: +- InMemoryTableScan [##94260831, cap#94260823, fractile#94260822, growth#94260826, leverage#94260827, max_date#94260833, min_date#94260832, momentum#94260829, size#94260824, value#94260825, volatility#94260828, yield#94260830], [isnotnull(fractile#94260822), NOT (fractile#94260822 = -1), isnotnull(cap#94260823)]
: +- InMemoryRelation [fractile#94260822, cap#94260823, size#94260824, value#94260825, growth#94260826, leverage#94260827, volatility#94260828, momentum#94260829, yield#94260830, ##94260831, min_date#94260832, max_date#94260833], StorageLevel(disk, memory, deserialized, 1 replicas)
: +- *(1) Project [CASE WHEN ((fractile#94260774 = NA) OR (fractile#94260774 = null)) THEN null ELSE cast(fractile#94260774 as int) END AS fractile#94260822, CASE WHEN (cap#94260775 = null) THEN null ELSE cap#94260775 END AS cap#94260823, CASE WHEN ((size#94260776 = NA) OR (size#94260776 = null)) THEN null ELSE cast(size#94260776 as float) END AS size#94260824, CASE WHEN ((value#94260777 = NA) OR (value#94260777 = null)) THEN null ELSE cast(value#94260777 as float) END AS value#94260825, CASE WHEN ((growth#94260778 = NA) OR (growth#94260778 = null)) THEN null ELSE cast(growth#94260778 as float) END AS growth#94260826, CASE WHEN ((leverage#94260779 = NA) OR (leverage#94260779 = null)) THEN null ELSE cast(leverage#94260779 as float) END AS leverage#94260827, CASE WHEN ((volatility#94260780 = NA) OR (volatility#94260780 = null)) THEN null ELSE cast(volatility#94260780 as float) END AS volatility#94260828, CASE WHEN ((momentum#94260781 = NA) OR (momentum#94260781 = null)) THEN null ELSE cast(momentum#94260781 as float) END AS momentum#94260829, CASE WHEN ((yield#94260782 = NA) OR (yield#94260782 = null)) THEN null ELSE cast(yield#94260782 as float) END AS yield#94260830, CASE WHEN ((##94260783 = NA) OR (##94260783 = null)) THEN null ELSE cast(##94260783 as float) END AS ##94260831, CASE WHEN (min_date#94260784 = null) THEN null ELSE cast(min_date#94260784 as date) END AS min_date#94260832, CASE WHEN (max_date#94260785 = null) THEN null ELSE cast(max_date#94260785 as date) END AS max_date#94260833]
: +- FileScan csv [fractile#94260774,cap#94260775,size#94260776,value#94260777,growth#94260778,leverage#94260779,volatility#94260780,momentum#94260781,yield#94260782,##94260783,min_date#94260784,max_date#94260785] Batched: false, DataFilters: [], Format: CSV, Location: InMemoryFileIndex(1 paths)[file:/srv/plusamp/data/default/ea-market/output/cam1/cam1_score/REPORT..., PartitionFilters: [], PushedFilters: [], ReadSchema: struct<fractile:string,cap:string,size:string,value:string,growth:string,leverage:string,volatili...
+- BroadcastExchange HashedRelationBroadcastMode(List(input[0, string, true]),false), [id=#7525908]
+- *(1) Project [description#94160396]
+- *(1) Filter ((isnotnull(cap#94160394) AND (cap#94160394 = 0)) AND isnotnull(description#94160396))
+- InMemoryTableScan [cap#94160394, description#94160396], [isnotnull(cap#94160394), (cap#94160394 = 0), isnotnull(description#94160396)]
+- InMemoryRelation [cap#94160394, sort#94160395, description#94160396, universe#94160397], StorageLevel(disk, memory, deserialized, 1 replicas)
+- *(1) Project [CASE WHEN ((cap#94160377 = NA) OR (cap#94160377 = null)) THEN null ELSE cast(cap#94160377 as int) END AS cap#94160394, CASE WHEN (sort#94160378 = null) THEN null ELSE sort#94160378 END AS sort#94160395, CASE WHEN (description#94160379 = null) THEN null ELSE description#94160379 END AS description#94160396, CASE WHEN ((universe#94160380 = NA) OR (universe#94160380 = null)) THEN null ELSE cast(universe#94160380 as int) END AS universe#94160397]
+- FileScan csv [cap#94160377,sort#94160378,description#94160379,universe#94160380] Batched: false, DataFilters: [], Format: CSV, Location: InMemoryFileIndex(1 paths)[file:/srv/plusamp/data/default/ea-market/curate/curate_cap.csv], PartitionFilters: [], PushedFilters: [], ReadSchema: struct<cap:string,sort:string,description:string,universe:string>
,None), [fractile#94260822 ASC NULLS FIRST]
(3) InMemoryTableScan
Output [12]: [##94260831, cap#94260823, fractile#94260822, growth#94260826, leverage#94260827, max_date#94260833, min_date#94260832, momentum#94260829, size#94260824, value#94260825, volatility#94260828, yield#94260830]
Arguments: [##94260831, cap#94260823, fractile#94260822, growth#94260826, leverage#94260827, max_date#94260833, min_date#94260832, momentum#94260829, size#94260824, value#94260825, volatility#94260828, yield#94260830], [isnotnull(fractile#94260822), NOT (fractile#94260822 = -1), isnotnull(cap#94260823)]
(4) InMemoryRelation
Arguments: [fractile#94260822, cap#94260823, size#94260824, value#94260825, growth#94260826, leverage#94260827, volatility#94260828, momentum#94260829, yield#94260830, ##94260831, min_date#94260832, max_date#94260833], CachedRDDBuilder(org.apache.spark.sql.execution.columnar.DefaultCachedBatchSerializer@208e3fd9,StorageLevel(disk, memory, deserialized, 1 replicas),*(1) Project [CASE WHEN ((fractile#94260774 = NA) OR (fractile#94260774 = null)) THEN null ELSE cast(fractile#94260774 as int) END AS fractile#94260822, CASE WHEN (cap#94260775 = null) THEN null ELSE cap#94260775 END AS cap#94260823, CASE WHEN ((size#94260776 = NA) OR (size#94260776 = null)) THEN null ELSE cast(size#94260776 as float) END AS size#94260824, CASE WHEN ((value#94260777 = NA) OR (value#94260777 = null)) THEN null ELSE cast(value#94260777 as float) END AS value#94260825, CASE WHEN ((growth#94260778 = NA) OR (growth#94260778 = null)) THEN null ELSE cast(growth#94260778 as float) END AS growth#94260826, CASE WHEN ((leverage#94260779 = NA) OR (leverage#94260779 = null)) THEN null ELSE cast(leverage#94260779 as float) END AS leverage#94260827, CASE WHEN ((volatility#94260780 = NA) OR (volatility#94260780 = null)) THEN null ELSE cast(volatility#94260780 as float) END AS volatility#94260828, CASE WHEN ((momentum#94260781 = NA) OR (momentum#94260781 = null)) THEN null ELSE cast(momentum#94260781 as float) END AS momentum#94260829, CASE WHEN ((yield#94260782 = NA) OR (yield#94260782 = null)) THEN null ELSE cast(yield#94260782 as float) END AS yield#94260830, CASE WHEN ((##94260783 = NA) OR (##94260783 = null)) THEN null ELSE cast(##94260783 as float) END AS ##94260831, CASE WHEN (min_date#94260784 = null) THEN null ELSE cast(min_date#94260784 as date) END AS min_date#94260832, CASE WHEN (max_date#94260785 = null) THEN null ELSE cast(max_date#94260785 as date) END AS max_date#94260833]
+- FileScan csv [fractile#94260774,cap#94260775,size#94260776,value#94260777,growth#94260778,leverage#94260779,volatility#94260780,momentum#94260781,yield#94260782,##94260783,min_date#94260784,max_date#94260785] Batched: false, DataFilters: [], Format: CSV, Location: InMemoryFileIndex(1 paths)[file:/srv/plusamp/data/default/ea-market/output/cam1/cam1_score/REPORT..., PartitionFilters: [], PushedFilters: [], ReadSchema: struct<fractile:string,cap:string,size:string,value:string,growth:string,leverage:string,volatili...
,None)
(5) Scan csv
Output [12]: [fractile#94260774, cap#94260775, size#94260776, value#94260777, growth#94260778, leverage#94260779, volatility#94260780, momentum#94260781, yield#94260782, ##94260783, min_date#94260784, max_date#94260785]
Batched: false
Location: InMemoryFileIndex [file:/srv/plusamp/data/default/ea-market/output/cam1/cam1_score/REPORT_exposures.csv]
ReadSchema: struct<fractile:string,cap:string,size:string,value:string,growth:string,leverage:string,volatility:string,momentum:string,yield:string,#:string,min_date:string,max_date:string>
(6) Project [codegen id : 1]
Output [12]: [CASE WHEN ((fractile#94260774 = NA) OR (fractile#94260774 = null)) THEN null ELSE cast(fractile#94260774 as int) END AS fractile#94260822, CASE WHEN (cap#94260775 = null) THEN null ELSE cap#94260775 END AS cap#94260823, CASE WHEN ((size#94260776 = NA) OR (size#94260776 = null)) THEN null ELSE cast(size#94260776 as float) END AS size#94260824, CASE WHEN ((value#94260777 = NA) OR (value#94260777 = null)) THEN null ELSE cast(value#94260777 as float) END AS value#94260825, CASE WHEN ((growth#94260778 = NA) OR (growth#94260778 = null)) THEN null ELSE cast(growth#94260778 as float) END AS growth#94260826, CASE WHEN ((leverage#94260779 = NA) OR (leverage#94260779 = null)) THEN null ELSE cast(leverage#94260779 as float) END AS leverage#94260827, CASE WHEN ((volatility#94260780 = NA) OR (volatility#94260780 = null)) THEN null ELSE cast(volatility#94260780 as float) END AS volatility#94260828, CASE WHEN ((momentum#94260781 = NA) OR (momentum#94260781 = null)) THEN null ELSE cast(momentum#94260781 as float) END AS momentum#94260829, CASE WHEN ((yield#94260782 = NA) OR (yield#94260782 = null)) THEN null ELSE cast(yield#94260782 as float) END AS yield#94260830, CASE WHEN ((##94260783 = NA) OR (##94260783 = null)) THEN null ELSE cast(##94260783 as float) END AS ##94260831, CASE WHEN (min_date#94260784 = null) THEN null ELSE cast(min_date#94260784 as date) END AS min_date#94260832, CASE WHEN (max_date#94260785 = null) THEN null ELSE cast(max_date#94260785 as date) END AS max_date#94260833]
Input [12]: [fractile#94260774, cap#94260775, size#94260776, value#94260777, growth#94260778, leverage#94260779, volatility#94260780, momentum#94260781, yield#94260782, ##94260783, min_date#94260784, max_date#94260785]
(7) Filter [codegen id : 2]
Input [12]: [##94260831, cap#94260823, fractile#94260822, growth#94260826, leverage#94260827, max_date#94260833, min_date#94260832, momentum#94260829, size#94260824, value#94260825, volatility#94260828, yield#94260830]
Condition : ((isnotnull(fractile#94260822) AND NOT (fractile#94260822 = -1)) AND isnotnull(cap#94260823))
(8) Project [codegen id : 2]
Output [12]: [fractile#94260822, cap#94260823 AS cap_description#94260846, size#94260824, value#94260825, growth#94260826, leverage#94260827, volatility#94260828, momentum#94260829, yield#94260830, ##94260831, min_date#94260832, max_date#94260833]
Input [12]: [##94260831, cap#94260823, fractile#94260822, growth#94260826, leverage#94260827, max_date#94260833, min_date#94260832, momentum#94260829, size#94260824, value#94260825, volatility#94260828, yield#94260830]
(9) InMemoryTableScan
Output [2]: [cap#94160394, description#94160396]
Arguments: [cap#94160394, description#94160396], [isnotnull(cap#94160394), (cap#94160394 = 0), isnotnull(description#94160396)]
(10) InMemoryRelation
Arguments: [cap#94160394, sort#94160395, description#94160396, universe#94160397], CachedRDDBuilder(org.apache.spark.sql.execution.columnar.DefaultCachedBatchSerializer@208e3fd9,StorageLevel(disk, memory, deserialized, 1 replicas),*(1) Project [CASE WHEN ((cap#94160377 = NA) OR (cap#94160377 = null)) THEN null ELSE cast(cap#94160377 as int) END AS cap#94160394, CASE WHEN (sort#94160378 = null) THEN null ELSE sort#94160378 END AS sort#94160395, CASE WHEN (description#94160379 = null) THEN null ELSE description#94160379 END AS description#94160396, CASE WHEN ((universe#94160380 = NA) OR (universe#94160380 = null)) THEN null ELSE cast(universe#94160380 as int) END AS universe#94160397]
+- FileScan csv [cap#94160377,sort#94160378,description#94160379,universe#94160380] Batched: false, DataFilters: [], Format: CSV, Location: InMemoryFileIndex(1 paths)[file:/srv/plusamp/data/default/ea-market/curate/curate_cap.csv], PartitionFilters: [], PushedFilters: [], ReadSchema: struct<cap:string,sort:string,description:string,universe:string>
,None)
(11) Scan csv
Output [4]: [cap#94160377, sort#94160378, description#94160379, universe#94160380]
Batched: false
Location: InMemoryFileIndex [file:/srv/plusamp/data/default/ea-market/curate/curate_cap.csv]
ReadSchema: struct<cap:string,sort:string,description:string,universe:string>
(12) Project [codegen id : 1]
Output [4]: [CASE WHEN ((cap#94160377 = NA) OR (cap#94160377 = null)) THEN null ELSE cast(cap#94160377 as int) END AS cap#94160394, CASE WHEN (sort#94160378 = null) THEN null ELSE sort#94160378 END AS sort#94160395, CASE WHEN (description#94160379 = null) THEN null ELSE description#94160379 END AS description#94160396, CASE WHEN ((universe#94160380 = NA) OR (universe#94160380 = null)) THEN null ELSE cast(universe#94160380 as int) END AS universe#94160397]
Input [4]: [cap#94160377, sort#94160378, description#94160379, universe#94160380]
(13) Filter [codegen id : 1]
Input [2]: [cap#94160394, description#94160396]
Condition : ((isnotnull(cap#94160394) AND (cap#94160394 = 0)) AND isnotnull(description#94160396))
(14) Project [codegen id : 1]
Output [1]: [description#94160396]
Input [2]: [cap#94160394, description#94160396]
(15) BroadcastExchange
Input [1]: [description#94160396]
Arguments: HashedRelationBroadcastMode(List(input[0, string, true]),false), [id=#7525908]
(16) BroadcastHashJoin [codegen id : 2]
Left keys [1]: [cap_description#94260846]
Right keys [1]: [description#94160396]
Join condition: None
(17) Project [codegen id : 2]
Output [11]: [fractile#94260822, size#94260824, value#94260825, growth#94260826, leverage#94260827, volatility#94260828, momentum#94260829, yield#94260830, ##94260831, min_date#94260832, max_date#94260833]
Input [13]: [fractile#94260822, cap_description#94260846, size#94260824, value#94260825, growth#94260826, leverage#94260827, volatility#94260828, momentum#94260829, yield#94260830, ##94260831, min_date#94260832, max_date#94260833, description#94160396]
(18) Exchange
Input [11]: [fractile#94260822, size#94260824, value#94260825, growth#94260826, leverage#94260827, volatility#94260828, momentum#94260829, yield#94260830, ##94260831, min_date#94260832, max_date#94260833]
Arguments: rangepartitioning(fractile#94260822 ASC NULLS FIRST, 200), ENSURE_REQUIREMENTS, [id=#7525913]
(19) Sort [codegen id : 3]
Input [11]: [fractile#94260822, size#94260824, value#94260825, growth#94260826, leverage#94260827, volatility#94260828, momentum#94260829, yield#94260830, ##94260831, min_date#94260832, max_date#94260833]
Arguments: [fractile#94260822 ASC NULLS FIRST], true, 0
(20) CollectLimit
Input [11]: [fractile#94260822, size#94260824, value#94260825, growth#94260826, leverage#94260827, volatility#94260828, momentum#94260829, yield#94260830, ##94260831, min_date#94260832, max_date#94260833]
Arguments: 1000000