I am new in scala and spark-graphx. This is a method that I've written to extract the vertex that has min score value
def getMinScoreVertex(graph: Graph[(Int,Float,Float,Float,String),Float]):Float={
var minValue:Float=Float.PositiveInfinity
var LowestScoreValue=graph.vertices.filter { case (id,(_,_,_,Score,_)) => Score < minValue}
return LowestScoreValue }
I get the following error:
Error:(15, 62) constructor cannot be instantiated to expected type;
found : (T1, T2, T3, T4, T5)
required: (org.apache.spark.graphx.VertexId, (Int, Float, Float, Float, String))
(which expands to) (Long, (Int, Float, Float, Float, String))
var LowestScoreValue=graph.vertices.filter { case (_,_,_,Score,_) => Score < minValue}
Error:(15, 69) not found: value Score
var LowestScoreValue=graph.vertices.filter { case (_,_,_,Score,_) => Score < minValue}
Error:(15, 82) not found: value Score
var LowestScoreValue=graph.vertices.filter { case (_,_,_,Score,_) => Score < minValue}
Any ideas?? Thanks