Re: 答复: 答复: RDD usage

2014-03-29 Thread Chieh-Yen
this because >> it will effect all the rdds generate by this changed rdd , make the whole >> process inconsistent and unstable. >> >> Some rough opinions on the immutable feature of rdd, full discuss can >> make it more clear. Any ideas? >> -------

Re: 答复: 答复: RDD usage

2014-03-25 Thread hequn cheng
he immutable feature of rdd, full discuss can make > it more clear. Any ideas? > -- > 发件人: hequn cheng > 发送时间: 2014/3/25 10:40 > 收件人: user@spark.apache.org > 主题: Re: 答复: RDD usage > > First question: > If you save your modified RDD like this:

答复: 答复: RDD usage

2014-03-24 Thread 林武康
ure of rdd, full discuss can make it more clear. Any ideas? -原始邮件- 发件人: "hequn cheng" 发送时间: ‎2014/‎3/‎25 10:40 收件人: "user@spark.apache.org" 主题: Re: 答复: RDD usage First question: If you save your modified RDD like this: points.foreach(p=>p.y = another_value).co

Re: 答复: RDD usage

2014-03-24 Thread hequn cheng
job running, is that right? > -- > 发件人: hequn cheng > 发送时间: 2014/3/25 9:35 > 收件人: user@spark.apache.org > 主题: Re: RDD usage > > points.foreach(p=>p.y = another_value) will return a new modified RDD. > > > 2014-03-24 18:13 GMT+08:00 Chie

Re: RDD usage

2014-03-24 Thread Mark Hamstra
No, it won't. The type of RDD#foreach is Unit, so it doesn't return an RDD. The utility of foreach is purely for the side effects it generates, not for its return value -- and modifying an RDD in place via foreach is generally not a very good idea. On Mon, Mar 24, 2014 at 6:35 PM, hequn cheng

答复: RDD usage

2014-03-24 Thread 林武康
apache.org" 主题: Re: RDD usage points.foreach(p=>p.y = another_value) will return a new modified RDD. 2014-03-24 18:13 GMT+08:00 Chieh-Yen : Dear all, I have a question about the usage of RDD. I implemented a class called AppDataPoint, it looks like: case class AppDataPoint(in

Re: RDD usage

2014-03-24 Thread hequn cheng
points.foreach(p=>p.y = another_value) will return a new modified RDD. 2014-03-24 18:13 GMT+08:00 Chieh-Yen : > Dear all, > > I have a question about the usage of RDD. > I implemented a class called AppDataPoint, it looks like: > > case class AppDataPoint(input_y : Double, input_x : Array[Double

RDD usage

2014-03-24 Thread Chieh-Yen
Dear all, I have a question about the usage of RDD. I implemented a class called AppDataPoint, it looks like: case class AppDataPoint(input_y : Double, input_x : Array[Double]) extends Serializable { var y : Double = input_y var x : Array[Double] = input_x .. } Furthermore, I created th