Package prefuse.data

Examples of prefuse.data.Table.addColumn()


    t.addColumn("int1", int.class);
    t.addColumn("int2", Integer[].class);
    t.addColumn("float1", float.class);
    t.addColumn("number1", Number.class);
    t.addColumn("date1", Date.class);
    t.addColumn("boolean1", boolean.class);
   
    String[] stringColumns = TableUtilities.getValidStringColumnNamesInTable(t);
    assertTrue(Arrays.asList(stringColumns).containsAll(Arrays.asList(new String[]{"S1", "S2"})));
    assertFalse(Arrays.asList(stringColumns).contains("int1"));
    assertFalse(Arrays.asList(stringColumns).contains("int2"));
View Full Code Here


  public static Table createTableUsingSchema(Schema tableSchema) {
    final int numTableColumns = tableSchema.getColumnCount();
    Table table = new Table();
   
    for (int ii = 0; ii < numTableColumns; ii++) {
      table.addColumn(tableSchema.getColumnName(ii), tableSchema.getColumnType(ii));
    }
   
    return table;
  }
View Full Code Here

      // check for columns that need updating here
      String newHeader = headerMap.get(colHead);
      if (newHeader != null)
        colHead = newHeader;
     
      returnTable.addColumn(colHead, oldSchema.getColumnType(i));
    }
   
    // add existing rows to return table
    returnTable.addRows(numTableRows);
    for (int i = 0; i < numTableRows; i++) {
View Full Code Here

    /* package */ GraphBuilder()
    {
        graph = new Graph( true );

        Table nodeTable = graph.getNodeTable();
        nodeTable.addColumn( GraphDisplay.NAME_LABEL, String.class );
        nodeTable.addColumn( GraphDisplay.USER_OBJECT, Object.class );

        Table edgeTable = graph.getEdgeTable();
        edgeTable.addColumn( GraphDisplay.USES_EDGES, boolean.class, false );

View Full Code Here

    {
        graph = new Graph( true );

        Table nodeTable = graph.getNodeTable();
        nodeTable.addColumn( GraphDisplay.NAME_LABEL, String.class );
        nodeTable.addColumn( GraphDisplay.USER_OBJECT, Object.class );

        Table edgeTable = graph.getEdgeTable();
        edgeTable.addColumn( GraphDisplay.USES_EDGES, boolean.class, false );

        childList = new ArrayList();
View Full Code Here

        Table nodeTable = graph.getNodeTable();
        nodeTable.addColumn( GraphDisplay.NAME_LABEL, String.class );
        nodeTable.addColumn( GraphDisplay.USER_OBJECT, Object.class );

        Table edgeTable = graph.getEdgeTable();
        edgeTable.addColumn( GraphDisplay.USES_EDGES, boolean.class, false );

        childList = new ArrayList();
    }

    private Graph buildApplicationNode( ApplicationDetailDescriptor descriptor )
View Full Code Here

    this.viz.run("gridlayout");
  }
 
  protected void addHostLabels(HeatmapData hd) {
    Table legend_labels_table = new Table();
    legend_labels_table.addColumn("label",String.class);
    legend_labels_table.addRows(hd.hostnames.length);
    for (int i = 0; i < hd.hostnames.length; i++) {
      legend_labels_table.setString(i,"label",hd.hostnames[i]);
    }
    float start_x = LEGEND_X_OFFSET;
View Full Code Here

    }
  }
 
  protected void addAddlInfo(HeatmapData hd) {
    Table legend_labels_table = new Table();
    legend_labels_table.addColumn("label",String.class);
    legend_labels_table.addRows(3);
   
    String hostnumstring = "Number of hosts: " + hd.num_hosts;
    if (sort_nodes) {
      hostnumstring += " (nodes sorted)";
View Full Code Here

      permute = hClust(stats);
      stats = doPermute(stats,permute);
    }
   
    Table agg_tab = new Table();
    agg_tab.addColumn("stat", long.class);
    min = Long.MAX_VALUE;
    max = Long.MIN_VALUE;
    agg_tab.addRows(num_hosts*num_hosts);
   
    // row-wise placement (row1, followed by row2, etc.)
View Full Code Here

     
    ColumnMetadata dstcol = newtable.getMetadata(dstFieldName + "_fulltime");
    long mintime = newtable.getLong(dstcol.getMinimumRow(), dstFieldName + "_fulltime");
   
    if (timeOffset == 0) {
      newtable.addColumn(dstFieldName, "ROUND((["+dstFieldName+"_fulltime] - " + mintime +"L) / 1000L)");
    } else {
      newtable.addColumn(dstFieldName, "ROUND((["+dstFieldName+"_fulltime] - " + timeOffset +"L) / 1000L)");     
    }
   
    return newtable;
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.