Venn Diagram in Qlikview using google chart api

    Hi All,

    QlikView has always had a great selection of chart objects to allow us to display data. There are various graphical charts and two table charts available to show case data.

     

    There has always been demand for new chart types but many of which would only be used in specific circumstances. The same situation i faced when in one of my requirement has Venn diagram.

     

    We all know that qlikview is a very flexible and dynamic tool.. and it proves its capability this time.

     

    So, how to create a venn diagram.??. i got the answere from google chart api.

     

    Yes, We can use google chart api in qlikview.!!

     

    So first discuss about google chart:

    The Google Chart API is a tool that lets web application developers create charts from some data and embed it in a web pages

    Many types of charts are supported, and by making the request into an image tag, people can simply include the chart in a web page.

     

    URL: http://chart.apis.google.com/chart?

     

    Venn Diagram Google Chart:  Detailed description about venn diagram is given in the below link

     

    Venn Charts - Image Charts (Deprecated) — Google Developers

     

    Scenario: i have a data set for which i need to make the venn diagram:

     

    i have persons list and the language details, they can speek. i need to show case the language in the venn diagram

     

    Person English Hindi Jermen
    AdilNNY
    AndreeNYN
    ErikYNY
    FrustukNNY
    JeremyYNN
    JonYNN
    ShreyaYYN

     

    Steps to implement Venn Diagram in Qlikview:

     

    Step 1: calculate the following variable to get the values for various langauge spoken by persons and the common values.

     

    so the variables would be

    1. vE =Count({<English={'Y'}>}Person)

    2. vH =Count({<Hindi={'Y'}>}Person)

    3. vJ =Count({<Jermen={'Y'}>}Person)

    4. vEH =Count({<Hindi={'Y'},English={'Y'}>}Person)

    5. vEJ =Count({<Jermen={'Y'},English={'Y'}>}Person)

    6. vHJ =Count({<Hindi={'Y'},Jermen={'Y'}>}Person)

    7. vEHJ =Count({<Hindi={'Y'},English={'Y'},Jermen={'Y'}>}Person)

     

    Step 2: Create a straight table and add the below expression:

     

    ='http://chart.apis.google.com/chart?cht=v&chs=330x220&chdl=English - '&$(vE)&'|Hindi - '&$(vH)&'|Jermen - '&$(vJ)&'&&chco=8DAACB,FC7362,BBD854&chd=t:'

    &$(vE)&','&$(vH)&','&$(vJ)&','&$(vEH)&','&$(vEJ)&','&$(vHJ)&','&$(vEHJ)

     

    in the above url

    cht=v define the chart type,

    chs define the size of chart

    chdl define dimension lable

    chco define chart color

    chd define the chart data.

     

    >> Make display option in expression tab as image

    >> Presentation tab check suppress header row

    >> Wrap cell text= 20 lines

     

     

    The output:

    venndiagram.JPG.jpg

    For more reference attached is the sample qvw file.

     

    HTH

    Sushil