Location: PHPKode > scripts > Bubble > bubble/BubbleChart.html
<HTML>
<HEAD>
<TITLE> BubbleChart Class </TITLE>
</HEAD>
<BODY> <HR color="NAVY">
<H1><FONT COLOR="RED" > BubbleChart Class </FONT></H1>
<HR color="NAVY">
<H2><FONT COLOR="NAVY">Description:</FONT> </H2>
<FONT COLOR="NAVY">This class displays bubble charts. It can be useful to show the positioning of subjects (such as companies, products, people, organizations, teams and so on) face to 2 qualities (classified according a semantic scale) at time. The width of the bubble allows to represent a third quality of the subject: this quality is relative to the other subjects. An interesting use of this class is to create Strategic Marketing Graphs in order to analyze  the positioning of a Company face to its competitors, taking two Critical Success Factors at time. </FONT>
<H2><FONT COLOR="NAVY">Methods:</FONT> </H2>
<TABLE BORDER="1">
<TR><TD>
<H3><FONT COLOR="NAVY"><PRE>DrawMatrix($facx,$facy)</FONT> </H3>
</TD><TD><FONT COLOR="NAVY"> This method starts the graph, defining a Matrix. The first parameter is the  name of the quality on the X axis,the second is  the  name of the quality on the Y axis.
</FONT>
</TD>
</TR>
<TR><TD>
<H3><FONT COLOR="NAVY"><PRE>AddBubble($name, $x,$y,$qm,$color)</FONT> </H3>
</TD><TD><FONT COLOR="NAVY"> This method add a bubble with the data of a subject (for example, a Company).The first parameter is the name of the subject (in the  example, the Company's name), the second and the third are the values for the 2 qualities (in the example, two Critical Success Factors such as Design and Safety)  on the X and on the Y axis: these values must be integers between 1 and 5. The fourth parameter is the third quality that determines the width of the Bubble( in the example, the  Market Share): it must be a positive integer and the sum of the values for this quality of all the subject (in the example, the sum of  all Market shares ) cannot be greater than 100. The last parameter is the color for the subject's bubble (in the example, the company's bubble): it must be an integer between 1 and 11. 
</FONT>
</TD>
</TR>
<TR><TD>
<H3><FONT COLOR="NAVY"><PRE>CheckQR()</FONT> </H3>
</TD><TD><FONT COLOR="NAVY"> This method returns the sum of the values for the third quality of all the subjects (in the example, of  all Market shares). 
</FONT>
</TD>
</TR>
<TR><TD>
<H3><FONT COLOR="NAVY"><PRE>MakeBubble($nameIMG)</FONT> </H3>
</TD><TD><FONT COLOR="NAVY"> This method creates the final graph. The parameter is the name (or the pathname) of the graph you want to create. It must have a .jpeg extension . If you do not provide a path, it will be create on your current directory  . ATTENTION:If the filename already exists in this directory, it will be DELETED to be sure that it will be displayed the new one. This method also call the CheckQR() method to check the third quality.
</FONT>
</TD>
</TR>

</TABLE>
<FONT COLOR="NAVY">
<PRE>

<H2>LEGENDA :</H2>
These are the meanings of the symbols on the axis of the matrix:
L=LOW (value 1)
ML=MEDIUM-LOW (value 2)
M=MEDIUM (value 3)
MH=MEDIUM-HIGH (value 4)
H=HIGH (value 5)
<PRE>
</FONT>
</BODY>
</HTML>
Return current item: Bubble