Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • A collection of Stata dataviz packages

    Dear all,

    I am starting this thread to post updates about my various dataviz packages.

    I also regularly post updates on Twitter and blog once in a while at The Stata Guide at Medium.

    These package are listed below. All of them have been submitted to SSC and (eventually) one should be able to install them as "ssc install <package name>, replace". If they are not yet on SSC, then follow the instructions on the GitHub repositories linked below. These repositories also contain the documentation, data, examples, and other info. The GitHub repos might also contain more recent releases not yet sent to SSC. So please do check there for updates, bug fixes etc.

    If you do find errors and/or have suggestions for improvement, open an issue in repository of the respective package. You can also find a summary of the packages on my landing page.

    And if you make some nice visualizations, then please share them!

    Thank you,

    Asjad


    1) schemepack: A large collection of ready-to-use Stata schemes

    Has a large collection of ready-to-use Stata schemes

    2) joyplot: A Stata package for classic ridgeline plots

    A Stata package for classic ridgeline plots

    3) streamplot: A Stata package for centered area graphs

    A #Stata package for centered area graphs

    4) bimap: A Stata package for bivariate maps

    A Stata package for bi-variate #maps

    5) marimekko: A Stata package for Marimekko graphs

    A #Stata package for #Marimekko bar graphs

    Last edited by Asjad Naqvi; 10 Sep 2022, 07:58.

  • #2
    and 5 more (and I somehow cannot resize the images...):

    6) clipgeo: A Stata package for clipping polygons and polylines



    7) arcplot: A Stata package for plotting network data as arcs.



    8) delaunay: A Stata package for plotting Delaunay triangles, convex hull, and Voronoi tessellations



    9) circlepack: A Stata package for circle packing heirarchical data



    10) treemap: A Stata package for plotting heirarchical data as tree maps

    Last edited by Asjad Naqvi; 10 Sep 2022, 08:03.

    Comment


    • #3
      All packages are up on SSC .

      And reposting the last 5 packages since their card previews were missing...


      6) clipgeo v2: A Stata package for clipping polygons and polylines

      clipgeo

      7) arcplot: A Stata package for plotting network data as arcs


      arcplot

      8) delaunay: A Stata package for plotting Delaunay triangles, convex hull, and Voronoi tessellations

      delaunay

      9) circlepack: A Stata package for circle packing heirarchical data

      circlepack

      10) treemap: A Stata package for plotting heirarchical data as tree maps

      treemap

      Comment


      • #4
        11) spider: A Stata package for spider plots

        spider-1.png

        Features include:

        - smoothing parameter
        - custom colors
        - graph rotation
        - axes & spike customizations

        The package is still beta. Next version will be sent to SSC, so install from GitHub for now.

        Comment


        • #5
          Thanks, Asjad Naqvi

          Please, consider adding Venn / Euler Diagrams on your future releases.

          Comment


          • #6
            Dear Luis Pecht,
            Yes certainly! I have your request also noted down from earlier exchange. I have code for 3x3 interactions but beyond this it gets complicated. So let me know please if you have some specific application or examples in mind.

            Comment


            • #7
              Interested readers may find some -ssc describe- commands helpful.

              Code:
              // Display info about Asjad Naqvi's "dataviz" packages
              ssc describe schemepack
              ssc describe joyplot
              ssc describe streamplot
              ssc describe bimap
              ssc describe marimekko
              ssc describe clipgeo
              ssc describe arcplot
              ssc describe delaunay
              ssc describe circlepack
              ssc describe treemap
              * -spider- is not yet available via ssc.
              * For now, it must be installed via GitHub.
              *ssc describe spider
              --
              Bruce Weaver
              Email: [email protected]
              Version: Stata/MP 18.5 (Windows)

              Comment


              • #8
                Yes, Venn Diagrams are very useful and can get very complicated. Do not to re-invent the wheel, a wrapper around some python package will be a great addition, despite prior Stata 16 limitation (sfi).
                Consider, https://github.com/mandalsubhajit/venndata

                Comment


                • #9
                  Thanks Luis Pecht will have a look!

                  Also thank Bruce Weaver for listing the SSC describe . I never gave the package description much thought, so I should fix these to be more comprehensive. Another task for the next batch update.

                  Comment


                  • #10
                    Thanks to Kit Baum, the following updates are now available on SSC:

                    spider v1.0
                    schemepack v1.4
                    streamplot v1.4
                    joyplot v1.6
                    arcplot v1.1
                    bimap v1.5



                    Just ssc install <packagename>, replace. See the links for updates.

                    As always, a big thanks to the community for helping improve the functionality of dataviz packages in Stata. More coming soon...


                    Comment


                    • #11
                      #8 showed a Venn diagram with 5 intersecting sets. In principle it would show a lot of information if annotated suitably. In practice many people find such Venn diagrams more or less useless unless the focus is on reading off individual subsets.

                      https://www.statalist.org/forums/for...mptoms-graphic is a thread started by Andrew Musau in which the structure of intersecting sets is shown differently.
                      Last edited by Nick Cox; 12 Nov 2022, 18:00.

                      Comment


                      • #12
                        Dropping two new packages today. Both are in beta and not currently on SSC. Install from GitHub and test them out. Instructions in the links below.

                        12) sankey: A Stata package for Sankey diagrams
                        sankey-1.png













                        13) alluvial: A Stata package for Alluvial charts
                        alluvial-1.png

                        Comment


                        • #13
                          The final three packages in the hierarchy series are out:


                          14) circlebar: A Stata package for circular bar graphs

                          circlebar-1.png

                          15) sunburst: A Stata package for sunburst plots

                          sunburst-1.png


                          16) treecluster: A Stata package for clustered tree plots


                          Click image for larger version

Name:	treecluster-1.png
Views:	1
Size:	704.8 KB
ID:	1695376

                          Comment


                          • #14
                            There is an interesting story about the origin of name of joyplot. The author said that someone in Tweet proposed this name in order to honor Joy Division which is a famous Post Punk music band. However, if we trace back to the origin of the name 'joy division', they were actually 'groups of Jewish women in Nazi concentration camps kept for the sexual pleasure of soldiers'. Thus, Claus O. Wilke, the author, said that
                            as joyful as the name “joyplot” sounds to the uninformed, its history is rather dark, and we would do better using a different name. For this reason, I have decided to now call these plots “ridgeline plots”.
                            The whole article is here:https://clauswilke.com/blog/2017/09/...dbye-joyplots/

                            Click image for larger version

Name:	joydivision.jpg
Views:	1
Size:	239.2 KB
ID:	1695505

                            Comment


                            • #15
                              Originally posted by Asjad Naqvi View Post
                              The final three packages in the hierarchy series are out:


                              14) circlebar: A Stata package for circular bar graphs

                              [ATTACH=CONFIG]n1695374[/ATTACH]

                              15) sunburst: A Stata package for sunburst plots

                              [ATTACH=CONFIG]n1695375[/ATTACH]


                              16) treecluster: A Stata package for clustered tree plots


                              [ATTACH=CONFIG]n1695376[/ATTACH]
                              Thank you for the nice packages. I just tried a few but unfortunately got errrors for all:

                              Code:
                              . sankey value, from(source) to(destination) by(layer)
                              invalid syntax
                              r(198);
                              
                              
                              
                              . circlebar deathspm, by(month) 
                              option - not allowed
                              r(198);
                              
                              
                              . sunburst value, by(continent)
                              invalid syntax
                              r(198);
                              
                              
                              . alluvial race married collgrad smsa union
                              race has more than 20 categories. The variable might be continuous.
                              Please simplify or drop the variable.
                              married has more than 20 categories. The variable might be continuous.
                              Please simplify or drop the variable.
                              collgrad has more than 20 categories. The variable might be continuous.
                              Please simplify or drop the variable.
                              smsa has more than 20 categories. The variable might be continuous.
                              Please simplify or drop the variable.
                              union has more than 20 categories. The variable might be continuous.
                              Please simplify or drop the variable.

                              Comment

                              Working...
                              X