Re: spark dataframe rolling window for user define operation

2016-10-29 Thread ayan guha
").rowsBetween(-20, +20) > > var dfWithAlternate = df.withColumn( "alter",*XYZ*(df("c2")).over(wSpec1)) > > > > Where XYZ function can be - +,-,+,- alternatively > > > > > > PS : I have posted the same question at http://stackoverflow.com/ > questions/40318010/spark-dataframe-rolling-window-user-define-operation > > > > Regards, > > Kiran > -- Best Regards, Ayan Guha

spark dataframe rolling window for user define operation

2016-10-29 Thread Manjunath, Kiran
ndow.orderBy("c1").rowsBetween(-20, +20) var dfWithAlternate = df.withColumn( "alter",XYZ(df("c2")).over(wSpec1)) Where XYZ function can be - +,-,+,- alternatively PS : I have posted the same question at http://stackoverflow.com/questions/40318010/spark-dataframe-rolling-window-user-define-operation Regards, Kiran