Hi, as far as I know only collect, print and execute actually trigger the
execution. What you're missing is env.execute() after the writeAsCsv call.
Hope this helps.

On Wed, Oct 7, 2015 at 9:35 PM, Lydia Ickler <ickle...@googlemail.com>
wrote:

> Hi,
>
> stupid question: Why is this not saved to file?
> I want to transform an array to a DataSet but the Graph stops at collect().
>
> //Transform Spectrum to DataSet
> List<Tuple2<String, String>> dataList = new LinkedList<Tuple2<String, 
> String>>();
> double[][] arr = filteredSpectrum.getAs2DDoubleArray();
> for (int i=0;i<arr[0].length;i++) {
>     dataList.add(new Tuple2( arr[0][i], arr[1][i]));
> }
> env.fromCollection(dataList).writeAsCsv(output);
>
> Best regards,
> Lydia
>
>


-- 
My GPG Key ID: 336E2680

Reply via email to