Package ucar.ma2

Examples of ucar.ma2.Array.nextFloat()


    // make sure that scaling is applied
    VariableDS vs = (VariableDS) ncfile.findVariable("hs");
    Array data = vs.read("0,1,:,:)");
    while (data.hasNext()) {
      float val = data.nextFloat();
      if (!vs.isMissing(val))
        assert (val < 10.0) : val;
      //System.out.printf("%f %n",val);
    }
View Full Code Here


    // make sure that scaling is applied
    VariableDS vs = (VariableDS) ncfile.findVariable("hs");
    Array data = vs.read("0,1,:,:)");
    while (data.hasNext()) {
      float val = data.nextFloat();
      if (!vs.isMissing(val))
        assert (val < 10.0) : val;
      //System.out.printf("%f %n",val);
    }
View Full Code Here

    assert v.getDataType() == DataType.FLOAT;

    boolean hasSigned = false;
    Array data = v.read();
    while (data.hasNext()) {
      float b = data.nextFloat();
      if (b < 0) hasSigned = true;
    }
    assert !hasSigned;

    ncfile.close();
View Full Code Here

    assert v.getDataType() == DataType.FLOAT;

    boolean hasSigned = false;
    Array data = v.read();
    while (data.hasNext()) {
      float b = data.nextFloat();
      if (b < 0) hasSigned = true;
    }
    assert !hasSigned;

    ncd.close();
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.