As of December 1, 2020, Focal Point is retired and repurposed as a reference repository. We value the wealth of knowledge that's been shared here over the years. You'll continue to have access to this treasure trove of knowledge, for search purposes only.
Join the TIBCO Community TIBCO Community is a collaborative space for users to share knowledge and support one another in making the best use of TIBCO products and services. There are several TIBCO WebFOCUS resources in the community.
From the Home page, select Predict: WebFOCUS to view articles, questions, and trending articles.
Select Products from the top navigation bar, scroll, and then select the TIBCO WebFOCUS product page to view product overview, articles, and discussions.
Request access to the private WebFOCUS User Group (login required) to network with fellow members.
Former myibi community members should have received an email on 8/3/22 to activate their user accounts to join the community. Check your Spam folder for the email. Please get in touch with us at community@tibco.com for further assistance. Reference the community FAQ to learn more about the community.
ENGINE INT CACHE SET ON
-DEFAULTH &WF_STYLE_UNITS='PIXELS';
-DEFAULTH &WF_STYLE_HEIGHT='405.0';
-DEFAULTH &WF_STYLE_WIDTH='770.0';
GRAPH FILE CAR
-* Created by Info Assist for Graph
SUM COMPUTE CALC/D12.3 = WHEELBASE / 10;
BY MODEL
ON GRAPH PCHOLD FORMAT JSCHART
ON GRAPH SET VZERO OFF
ON GRAPH SET HTMLENCODE ON
ON GRAPH SET GRAPHDEFAULT OFF
ON GRAPH SET UNITS &WF_STYLE_UNITS
ON GRAPH SET HAXIS &WF_STYLE_WIDTH
ON GRAPH SET VAXIS &WF_STYLE_HEIGHT
ON GRAPH SET GRMERGE ADVANCED
ON GRAPH SET GRMULTIGRAPH 0
ON GRAPH SET GRLEGEND 1
ON GRAPH SET GRXAXIS 0
ON GRAPH SET LOOKGRAPH PIEMULTI
ON GRAPH SET AUTOFIT ON
ON GRAPH SET STYLE *
*GRAPH_SCRIPT
setPieDepth(0);
setPieTilt(0);
setDepthRadius(0);
setCurveFitEquationDisplay(false);
setPlace(true);
setLegendPosition(1);
setBorderColor(getChartBackground(),new Color(255,255,255));
setReportParsingErrors(false);
setSelectionEnableMove(false);
setPieFeelerTextDisplay(0);
setFillColor(getChartBackground(),new Color(255,255,255,0));
setFillColor(getSeries(0),new Color(113,110,45));
setFillColor(getSeries(1),new Color(140,132,116));
setFillColor(getSeries(2),new Color(6,140,191));
setFillColor(getSeries(3),new Color(202,31,64));
setFillColor(getSeries(4),new Color(17,87,114));
setFillColor(getSeries(5),new Color(5,121,165));
setFillColor(getSeries(6),new Color(9,149,209));
setFillColor(getSeries(7),new Color(6,140,191));
setFillColor(getSeries(8),new Color(1,46,62));
setFillColor(getSeries(9),new Color(7,93,127));
setFillColor(getSeries(10),new Color(64,186,144));
setFillColor(getSeries(11),new Color(68,193,201));
setFillColor(getSeries(12),new Color(6,140,191));
setFillColor(getSeries(13),new Color(52,101,176));
setFillColor(getSeries(15),new Color(8,103,140));
setFillColor(getSeries(16),new Color(21,52,62));
setFillColor(getSeries(17),new Color(6,140,191));
setFillColor(getSeries(18),new Color(68,164,201));
setFillColor(getSeries(19),new Color(1,46,62));
setFillColor(getSeries(20),new Color(239,76,82));
setFillColor(getSeries(21),new Color(198,139,130));
setFillColor(getSeries(22),new Color(78,191,171));
setFillColor(getSeries(23),new Color(72,83,89));
setFillColor(getSeries(24),new Color(87,178,228));
setFillColor(getSeries(14), new Color(52,74,156,255));
setTextFormatPattern(getPieSliceLabel(),"##.#%");
*END
-RUN
ENDSTYLE
END
Intent is to show only CALC value in percentage as the tooltip on pie slice. Currently it shows the decimal value and percentage of pie slice it covers.This message has been edited. Last edited by: Kartik Katyal,
TABLE FILE CAR
SUM COMPUTE CALC /D12.3 = WHEELBASE / 10;
BY MODEL
ON TABLE HOLD AS DETDATA
END
-RUN
DEFINE FILE DETDATA
DUMMY /A1 = 'X';
END
TABLE FILE DETDATA
SUM COMPUTE CALC_TOT /D12.3 = CALC;
BY DUMMY
ON TABLE HOLD AS TOTCALC
END
-RUN
-READFILE TOTCALC
-RUN
-DEFAULTH &CALC_TOT = 0
-TYPE &CALC_TOT
TABLE FILE DETDATA
SUM COMPUTE CALC_TOT /D12.3 = &CALC_TOT;
CALC
COMPUTE PCT /P10.2C = IF CALC_TOT NE 0 THEN CALC / CALC_TOT * 100 ELSE 0;
BY MODEL
ON TABLE HOLD AS GRAPHDATA
END
-RUN
ENGINE INT CACHE SET ON
-DEFAULTH &WF_STYLE_UNITS='PIXELS';
-DEFAULTH &WF_STYLE_HEIGHT='405.0';
-DEFAULTH &WF_STYLE_WIDTH='770.0';
GRAPH FILE GRAPHDATA
SUM CALC
COMPUTE DIMX /A30V = MODEL;
COMPUTE PCTX /A20V = LJUST(12, FPRINT(PCT, 'P10.2C', 'A12V'), 'A12V') || ' %';
BY MODEL
ON GRAPH PCHOLD FORMAT JSCHART
ON GRAPH SET VZERO OFF
ON GRAPH SET HTMLENCODE ON
ON GRAPH SET GRAPHDEFAULT OFF
ON GRAPH SET UNITS &WF_STYLE_UNITS
ON GRAPH SET HAXIS &WF_STYLE_WIDTH
ON GRAPH SET VAXIS &WF_STYLE_HEIGHT
ON GRAPH SET GRMERGE ADVANCED
ON GRAPH SET GRMULTIGRAPH 0
ON GRAPH SET GRLEGEND 1
ON GRAPH SET GRXAXIS 0
ON GRAPH SET LOOKGRAPH PIE
ON GRAPH SET AUTOFIT ON
ON GRAPH SET STYLE *
*GRAPH_SCRIPT
setPieDepth(0);
setPieTilt(0);
setDepthRadius(0);
setCurveFitEquationDisplay(false);
setPlace(true);
setLegendPosition(1);
setBorderColor(getChartBackground(),new Color(255,255,255));
setReportParsingErrors(false);
setSelectionEnableMove(false);
setPieFeelerTextDisplay(0);
setFillColor(getChartBackground(),new Color(255,255,255,0));
setFillColor(getSeries(0),new Color(113,110,45));
setFillColor(getSeries(1),new Color(140,132,116));
setFillColor(getSeries(2),new Color(6,140,191));
setFillColor(getSeries(3),new Color(202,31,64));
setFillColor(getSeries(4),new Color(17,87,114));
setFillColor(getSeries(5),new Color(5,121,165));
setFillColor(getSeries(6),new Color(9,149,209));
setFillColor(getSeries(7),new Color(6,140,191));
setFillColor(getSeries(8),new Color(1,46,62));
setFillColor(getSeries(9),new Color(7,93,127));
setFillColor(getSeries(10),new Color(64,186,144));
setFillColor(getSeries(11),new Color(68,193,201));
setFillColor(getSeries(12),new Color(6,140,191));
setFillColor(getSeries(13),new Color(52,101,176));
setFillColor(getSeries(15),new Color(8,103,140));
setFillColor(getSeries(16),new Color(21,52,62));
setFillColor(getSeries(17),new Color(6,140,191));
setFillColor(getSeries(18),new Color(68,164,201));
setFillColor(getSeries(19),new Color(1,46,62));
setFillColor(getSeries(20),new Color(239,76,82));
setFillColor(getSeries(21),new Color(198,139,130));
setFillColor(getSeries(22),new Color(78,191,171));
setFillColor(getSeries(23),new Color(72,83,89));
setFillColor(getSeries(24),new Color(87,178,228));
setFillColor(getSeries(14), new Color(52,74,156,255));
setTextFormatPattern(getPieSliceLabel(),"##.#%");
*END
TYPE=DATA, COLUMN=MODEL, BUCKET=color, $
TYPE=DATA, COLUMN=CALC, BUCKET=measure, $
TYPE=DATA, COLUMN=DIMX, BUCKET=tooltip, $
TYPE=DATA, COLUMN=PCTX, BUCKET=tooltip, $
*GRAPH_JS_FINAL
series: [ {"series": 'reset', "tooltip": '{{tooltip1}}<br>{{tooltip2}}'} ],
htmlToolTip: {enable: true, snap: false }
*END
ENDSTYLE
END
-RUN
WF versions : Prod 8.2.04M gen 33, Dev 8.2.04M gen 33, OS : Windows, DB : MSSQL, Outputs : HTML, Excel, PDF In Focus since 2007
Posts: 2409 | Location: Montreal Area, Qc, CA | Registered: September 25, 2013
One caveat is that I had to divide your COMPUTE by an additional 100 to format the tooltip correctly
ENGINE INT CACHE SET ON
-DEFAULTH &WF_STYLE_UNITS='PIXELS';
-DEFAULTH &WF_STYLE_HEIGHT='405.0';
-DEFAULTH &WF_STYLE_WIDTH='770.0';
GRAPH FILE CAR
-* Created by Info Assist for Graph
SUM COMPUTE CALC/D12.3 = WHEELBASE / 10 / 100;
BY MODEL
ON GRAPH PCHOLD FORMAT JSCHART
ON GRAPH SET VZERO OFF
ON GRAPH SET HTMLENCODE ON
ON GRAPH SET GRAPHDEFAULT OFF
ON GRAPH SET UNITS &WF_STYLE_UNITS
ON GRAPH SET HAXIS &WF_STYLE_WIDTH
ON GRAPH SET VAXIS &WF_STYLE_HEIGHT
ON GRAPH SET GRMERGE ADVANCED
ON GRAPH SET GRMULTIGRAPH 0
ON GRAPH SET GRLEGEND 1
ON GRAPH SET GRXAXIS 0
ON GRAPH SET LOOKGRAPH PIEMULTI
ON GRAPH SET AUTOFIT ON
ON GRAPH SET STYLE *
*GRAPH_SCRIPT
setPieDepth(0);
setPieTilt(0);
setDepthRadius(0);
setCurveFitEquationDisplay(false);
setPlace(true);
setLegendPosition(1);
setBorderColor(getChartBackground(),new Color(255,255,255));
setReportParsingErrors(false);
setSelectionEnableMove(false);
setPieFeelerTextDisplay(0);
setFillColor(getChartBackground(),new Color(255,255,255,0));
setFillColor(getSeries(0),new Color(113,110,45));
setFillColor(getSeries(1),new Color(140,132,116));
setFillColor(getSeries(2),new Color(6,140,191));
setFillColor(getSeries(3),new Color(202,31,64));
setFillColor(getSeries(4),new Color(17,87,114));
setFillColor(getSeries(5),new Color(5,121,165));
setFillColor(getSeries(6),new Color(9,149,209));
setFillColor(getSeries(7),new Color(6,140,191));
setFillColor(getSeries(8),new Color(1,46,62));
setFillColor(getSeries(9),new Color(7,93,127));
setFillColor(getSeries(10),new Color(64,186,144));
setFillColor(getSeries(11),new Color(68,193,201));
setFillColor(getSeries(12),new Color(6,140,191));
setFillColor(getSeries(13),new Color(52,101,176));
setFillColor(getSeries(15),new Color(8,103,140));
setFillColor(getSeries(16),new Color(21,52,62));
setFillColor(getSeries(17),new Color(6,140,191));
setFillColor(getSeries(18),new Color(68,164,201));
setFillColor(getSeries(19),new Color(1,46,62));
setFillColor(getSeries(20),new Color(239,76,82));
setFillColor(getSeries(21),new Color(198,139,130));
setFillColor(getSeries(22),new Color(78,191,171));
setFillColor(getSeries(23),new Color(72,83,89));
setFillColor(getSeries(24),new Color(87,178,228));
setFillColor(getSeries(14), new Color(52,74,156,255));
*GRAPH_JS_FINAL
"pieProperties": {
"holeSize": "0%"
},
"riserBevel": "none",
"agnosticSettings": {
"chartTypeFullName": "Pie_Multi"
},
"series": [{
"series": "reset",
"tooltip": "{{series_label}}: {{value | formatNumber('#.###%')}}"
}]
*END
ENDSTYLE
END
-RUN
This message has been edited. Last edited by: Hallway,
Hallway
Prod: 8202M1
Test: 8202M4
Repository:
OS:
Outputs:
Posts: 608 | Location: Salt Lake City, UT, USA | Registered: November 18, 2015