comparison artifacts/src/main/java/org/dive4elements/river/exports/StyledSeriesBuilder.java @ 6881:32af7e5cb00f

issue1378: Prepare StyledSeriesBuilder to get double[][] values to translate.
author Felix Wolfsteller <felix.wolfsteller@intevation.de>
date Wed, 21 Aug 2013 11:10:45 +0200
parents 590d420ed382
children e4606eae8ea5
comparison
equal deleted inserted replaced
6880:8a4e344b309a 6881:32af7e5cb00f
302 /** 302 /**
303 * Add points to series (q to 1st dim, w to 2nd dim), adding wTrans to the 303 * Add points to series (q to 1st dim, w to 2nd dim), adding wTrans to the
304 * W values and scaling it with wScale. 304 * W values and scaling it with wScale.
305 * 305 *
306 * @param series Series to add points to. 306 * @param series Series to add points to.
307 * @param qws to add to series.
308 * @param wAdd Value to add to each Q while adding to series.
309 * @param wScale multiply with
310 */
311 public static void addPointsQW(XYSeries series, double[][] qws, double wTrans, double wScale) {
312 if (qws == null || qws.length == 0) {
313 return;
314 }
315
316 double x[] = qws[0];
317 double y[] = qws[1];
318
319 for (int i = 0; i < x.length; i++) {
320 series.add(x[i], wScale * (y[i] + wTrans), false);
321 }
322 }
323 /**
324 * Add points to series (q to 1st dim, w to 2nd dim), adding wTrans to the
325 * W values and scaling it with wScale.
326 *
327 * @param series Series to add points to.
307 * @param wqkms WQKms to add to series. 328 * @param wqkms WQKms to add to series.
308 * @param wAdd Value to add to each Q while adding to series. 329 * @param wAdd Value to add to each Q while adding to series.
309 * @param wScale multiply with 330 * @param wScale multiply with
310 */ 331 */
311 public static void addPointsQW(XYSeries series, WQKms wqkms, double wTrans, double wScale) { 332 public static void addPointsQW(XYSeries series, WQKms wqkms, double wTrans, double wScale) {

http://dive4elements.wald.intevation.org