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.
I've got a request to show a vertical percent bar graph and display the legend of X axis. But with the code, the values of the legends can not display correctly. Example the value of MAINT is 40 and the value of NO-MAINT is 60,so the percent of MAINT = MAINT/(MAINT+NO-MAINT)*100 and the percent of NO-MAINT = NO-MAINT/(MAINT+NO-MAINT)*100; The stacked bar would show 40% MAINT and 60% NO-MAINT with different yellow and blue colour. So the yellow legend should display NO-MAINT, and blue legend should display MAINT. But with my code, the yellow or blue legend will always display MAINT.
Looking for forward to your suggestion. Thanks in advance!This message has been edited. Last edited by: Tamra,
WebFOCUS 8105 Windows, All Outputs
Posts: 26 | Location: Hefei,China | Registered: March 27, 2016
Having your code may help us to help you but without that, here what I would do instead.
I understand that it may not be exactly what you've been requested, but in your case I will do the following (especially to display percentage as of a bar graph) :
DEFINE FILE CAR
REGION /A10V = DECODE COUNTRY ('FRANCE' 'EAST' 'ENGLAND' 'EAST' 'ITALY' 'EAST' ELSE 'WEST');
END
ENGINE INT CACHE SET ON
-DEFAULTH &WF_STYLE_UNITS='PIXELS';
-DEFAULTH &WF_STYLE_HEIGHT='405.0';
-DEFAULTH &WF_STYLE_WIDTH='770.0';
-DEFAULTH &WF_TITLE='WebFOCUS Report';
GRAPH FILE CAR
SUM COMPUTE RETPCT/P8.2%=RETAIL_COST/( RETAIL_COST + DEALER_COST ) * 100 ;
COMPUTE DELPCT/P8.2%=DEALER_COST/( RETAIL_COST + DEALER_COST ) * 100 ;
BY CAR.ORIGIN.REGION
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 0
ON GRAPH SET GRXAXIS 1
ON GRAPH SET LOOKGRAPH VBRSTKPC
ON GRAPH SET AUTOFIT ON
ON GRAPH SET STYLE *
*GRAPH_SCRIPT
setPieDepth(0);
setPieTilt(0);
setDepthRadius(0);
setCurveFitEquationDisplay(false);
setPlace(true);
*END
INCLUDE=IBFS:/FILE/IBI_HTML_DIR/javaassist/intl/EN/ENIADefault_combine.sty,$
TYPE=REPORT, TITLETEXT=&WF_TITLE.QUOTEDSTRING, $
*GRAPH_SCRIPT
setReportParsingErrors(false);
setSelectionEnableMove(false);
*END
ENDSTYLE
END
-RUN
The thing is that in fact, the way that you present it, your MAINT and NO-MAINT are two different measures but it seems that they are displayed as only one. My above sample have two measures displayed in one bar but where each keeps their own label.
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