Package ucar.nc2.dataset

Examples of ucar.nc2.dataset.VariableDS.addAttribute()


        Variable aziVar = new Variable(ncfile, null, null, aziCoordName);
        aziVar.setDataType(DataType.FLOAT);
        aziVar.setDimensions(dim2);
        ncfile.addVariable(null, aziVar);

        aziVar.addAttribute( new Attribute("units", "degrees"));
        aziVar.addAttribute( new Attribute("long_name", "azimuth angle in degrees: 0 = true north, 90 = east"));
        aziVar.addAttribute( new Attribute("missing_value", firstRay.getMissingData()));
        aziVar.addAttribute( new Attribute(_Coordinate.AxisType, AxisType.RadialAzimuth.toString()));

        // add gate coordinate variable
View Full Code Here


        aziVar.setDataType(DataType.FLOAT);
        aziVar.setDimensions(dim2);
        ncfile.addVariable(null, aziVar);

        aziVar.addAttribute( new Attribute("units", "degrees"));
        aziVar.addAttribute( new Attribute("long_name", "azimuth angle in degrees: 0 = true north, 90 = east"));
        aziVar.addAttribute( new Attribute("missing_value", firstRay.getMissingData()));
        aziVar.addAttribute( new Attribute(_Coordinate.AxisType, AxisType.RadialAzimuth.toString()));

        // add gate coordinate variable
        String gateCoordName = "distance"+abbrev;
View Full Code Here

        aziVar.setDimensions(dim2);
        ncfile.addVariable(null, aziVar);

        aziVar.addAttribute( new Attribute("units", "degrees"));
        aziVar.addAttribute( new Attribute("long_name", "azimuth angle in degrees: 0 = true north, 90 = east"));
        aziVar.addAttribute( new Attribute("missing_value", firstRay.getMissingData()));
        aziVar.addAttribute( new Attribute(_Coordinate.AxisType, AxisType.RadialAzimuth.toString()));

        // add gate coordinate variable
        String gateCoordName = "distance"+abbrev;
        Variable gateVar = new Variable(ncfile, null, null, gateCoordName);
View Full Code Here

        ncfile.addVariable(null, aziVar);

        aziVar.addAttribute( new Attribute("units", "degrees"));
        aziVar.addAttribute( new Attribute("long_name", "azimuth angle in degrees: 0 = true north, 90 = east"));
        aziVar.addAttribute( new Attribute("missing_value", firstRay.getMissingData()));
        aziVar.addAttribute( new Attribute(_Coordinate.AxisType, AxisType.RadialAzimuth.toString()));

        // add gate coordinate variable
        String gateCoordName = "distance"+abbrev;
        Variable gateVar = new Variable(ncfile, null, null, gateCoordName);
        gateVar.setDataType(DataType.FLOAT);
View Full Code Here

            (double) firstRay.getGateStart(abbrev), (double) firstRay.getGateSize(abbrev));
        gateVar.setCachedData( data, false);
        ncfile.addVariable(null, gateVar);
  //      radarRadius = firstRay.getGateStart(datatype) + ngates * firstRay.getGateSize(datatype);

        gateVar.addAttribute( new Attribute("units", "m"));
        gateVar.addAttribute( new Attribute("long_name", "radial distance to start of gate"));
        gateVar.addAttribute( new Attribute(_Coordinate.AxisType, AxisType.RadialDistance.toString()));

        // add number of radials variable
        String nradialsName = "numRadials"+abbrev;
View Full Code Here

        gateVar.setCachedData( data, false);
        ncfile.addVariable(null, gateVar);
  //      radarRadius = firstRay.getGateStart(datatype) + ngates * firstRay.getGateSize(datatype);

        gateVar.addAttribute( new Attribute("units", "m"));
        gateVar.addAttribute( new Attribute("long_name", "radial distance to start of gate"));
        gateVar.addAttribute( new Attribute(_Coordinate.AxisType, AxisType.RadialDistance.toString()));

        // add number of radials variable
        String nradialsName = "numRadials"+abbrev;
        Variable nradialsVar = new Variable(ncfile, null, null, nradialsName);
View Full Code Here

        ncfile.addVariable(null, gateVar);
  //      radarRadius = firstRay.getGateStart(datatype) + ngates * firstRay.getGateSize(datatype);

        gateVar.addAttribute( new Attribute("units", "m"));
        gateVar.addAttribute( new Attribute("long_name", "radial distance to start of gate"));
        gateVar.addAttribute( new Attribute(_Coordinate.AxisType, AxisType.RadialDistance.toString()));

        // add number of radials variable
        String nradialsName = "numRadials"+abbrev;
        Variable nradialsVar = new Variable(ncfile, null, null, nradialsName);
        nradialsVar.setDataType(DataType.INT);
View Full Code Here

        // add number of radials variable
        String nradialsName = "numRadials"+abbrev;
        Variable nradialsVar = new Variable(ncfile, null, null, nradialsName);
        nradialsVar.setDataType(DataType.INT);
        nradialsVar.setDimensions(scanDim.getName());
        nradialsVar.addAttribute( new Attribute("long_name", "number of valid radials in this scan"));
        ncfile.addVariable(null, nradialsVar);

        // add number of gates variable
        String ngateName = "numGates"+abbrev;
        Variable ngateVar = new Variable(ncfile, null, null, ngateName);
View Full Code Here

        // add number of gates variable
        String ngateName = "numGates"+abbrev;
        Variable ngateVar = new Variable(ncfile, null, null, ngateName);
        ngateVar.setDataType(DataType.INT);
        ngateVar.setDimensions(scanDim.getName());
        ngateVar.addAttribute( new Attribute("long_name", "number of valid gates in this scan"));
        ncfile.addVariable(null, ngateVar);

        makeCoordinateDataWithMissing(abbrev, timeVar, elevVar, aziVar, nradialsVar, ngateVar, groups);

        // back to the data variable
View Full Code Here

        String   timeCoordName = "time";
        Variable taxis         = new Variable(ncfile, null, null, timeCoordName);

        taxis.setDataType(DataType.DOUBLE);
        taxis.setDimensions("time");
        taxis.addAttribute(new Attribute("long_name", "time since base date"));
        taxis.addAttribute(new Attribute(_Coordinate.AxisType, AxisType.Time.toString()));

        double[] tdata = new double[1];

        tdata[0] = dd.getTime();
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.