use of org.baderlab.csplugins.enrichmentmap.style.charts.Rotation in project EnrichmentMapApp by BaderLab.
the class RadialHeatMapChart method getLayers.
@Override
public List<RadialHeatMapLayer> getLayers(final CyNetworkView networkView, final View<? extends CyIdentifiable> view) {
final CyNetwork network = networkView.getModel();
final CyIdentifiable model = view.getModel();
final double startAngle = get(START_ANGLE, Double.class, 0.0);
final Rotation rotation = get(ROTATION, Rotation.class, Rotation.ANTICLOCKWISE);
final List<String> labels = getItemLabels(network, model);
final Map<String, List<Double>> data = getData(network, model);
final List<Color> colors = getColors(data);
final double size = 32;
final Rectangle2D bounds = new Rectangle2D.Double(-size / 2, -size / 2, size, size);
final boolean showLabels = get(SHOW_ITEM_LABELS, Boolean.class, false);
final float itemFontSize = convertFontSize(get(ITEM_LABEL_FONT_SIZE, Integer.class, 1));
final float borderWidth = get(BORDER_WIDTH, Float.class, 0.25f);
final Color borderColor = get(BORDER_COLOR, Color.class, Color.DARK_GRAY);
final boolean global = get(GLOBAL_RANGE, Boolean.class, true);
final List<Double> range = global ? getList(RANGE, Double.class) : null;
final RadialHeatMapLayer layer = new RadialHeatMapLayer(data, labels, showLabels, itemFontSize, colors, borderWidth, borderColor, startAngle, rotation, range, bounds);
return Collections.singletonList(layer);
}
Aggregations