public void addSeries ( String seriesName , double [ ] x , double [ ] y ) { XYSeries series = new XYSeries ( seriesName ) ; for ( int i = 0 ; i < x . length ; i ++ ) { series . add ( x [ i ] , y [ i ] ) ; } dataset . addSeries ( series ) ; }
Add a new series by name and data .