[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"doc-seo-657213-105":3,"detail-sidebar-cat-0-en-105":80,"doc-detail-657213-en":130},{"code":4,"msg":5,"data":6},0,"ok",{"site_id":7,"language":8,"slug":9,"title":10,"keywords":11,"description":12,"schema_data":13,"social_meta":73,"head_meta":75,"extra_data":77,"updated_unix":79},105,"en","alluvial-plots-in-ggplot2-alluvial-plots-in-ggplot2-package-ggalluvial","Alluvial Plots in 'ggplot2' - Alluvial Plots in ggplot2 - package ggalluvial","","R package ggalluvial provides statistical graphics for alluvial plots, using variable-width ribbons and stacked bar representations to show relationships in multi-dimensional or repeated-measures categorical/ordinal data. The package extends ggplot2’s layered grammar to generate alluvial plots from tidy data, uniquely determined by the dataset and a small set of parameters. It also offers helpers to structure and convert alluvial data formats, including checks for lodes/alluvia structure and transformations between lodes and alluvia representations.",{"@graph":14,"@context":72},[15,34,55],{"@type":16,"itemListElement":17},"BreadcrumbList",[18,23,27,31],{"item":19,"name":20,"@type":21,"position":22},"https://docshare.wps.com","Home","ListItem",1,{"item":24,"name":25,"@type":21,"position":26},"https://docshare.wps.com/document/","Document",2,{"item":28,"name":29,"@type":21,"position":30},"https://docshare.wps.com/document/technology/","Technology",3,{"item":32,"name":10,"@type":21,"position":33},"https://docshare.wps.com/document/alluvial-plots-in-ggplot2-alluvial-plots-in-ggplot2-package-ggalluvial/657213/",4,{"url":32,"name":10,"@type":35,"image":36,"author":41,"headline":10,"publisher":44,"fileFormat":47,"inLanguage":8,"description":12,"dateModified":48,"datePublished":49,"encodingFormat":47,"isAccessibleForFree":50,"interactionStatistic":51},"DigitalDocument",{"url":37,"@type":38,"width":39,"height":40},"https://docshare.wps.com/thumbnails/alluvial-plots-in-ggplot2-alluvial-plots-in-ggplot2-package-ggalluvial/657213.png","ImageObject",300,407,{"name":42,"@type":43},"Stanley","Person",{"url":19,"name":45,"@type":46},"DocShare","Organization","application/pdf","2026-10-29","2026-10-26",true,{"@type":52,"interactionType":53,"userInteractionCount":33},"InteractionCounter",{"@type":54},"ViewAction",{"@type":56,"mainEntity":57},"FAQPage",[58,64,68],{"name":59,"@type":60,"acceptedAnswer":61},"What kind of data can ggalluvial visualize with alluvial plots?","Question",{"text":62,"@type":63},"ggalluvial targets multi-dimensional or repeated-measures categorical/ordinal data, where relationships can be represented with flows between axis values. It supports tidy-data workflows for building these graphics.","Answer",{"name":65,"@type":60,"acceptedAnswer":66},"How does ggalluvial generate alluvial plots within ggplot2?",{"text":67,"@type":63},"The package extends ggplot2’s layered grammar of graphics so alluvial plots are constructed from tidy data. The resulting plots are determined by the input data and a small set of parameters.",{"name":69,"@type":60,"acceptedAnswer":70},"What is the purpose of alluvial-data utilities like is_lodes_form and to_lodes_form?",{"text":71,"@type":63},"These utilities check whether a data frame has lodes or alluvia structure and convert between formats. They identify axis, stratum/value, and alluvium/id variables and can optionally use weight and site fields.","https://schema.org",{"og:url":32,"og:type":74,"og:title":10,"og:site_name":45,"og:description":12},"article",{"robots":76,"canonical":32},"index,follow",{"doc_id":78,"site_id":7},657213,1793122569,{"code":4,"msg":81,"data":82},"success",[83,87,91,95,100,104,109,114,119,122,126],{"id":22,"doc_module":4,"doc_module_name":25,"category_name":84,"show_sort_weight":85,"slug":86},"Story & Novel",90,"story-novel",{"id":26,"doc_module":4,"doc_module_name":25,"category_name":88,"show_sort_weight":89,"slug":90},"Literature",80,"literature",{"id":33,"doc_module":4,"doc_module_name":25,"category_name":92,"show_sort_weight":93,"slug":94},"Exam",70,"exam",{"id":96,"doc_module":4,"doc_module_name":25,"category_name":97,"show_sort_weight":98,"slug":99},5,"Comic",60,"comic",{"id":101,"doc_module":4,"doc_module_name":25,"category_name":29,"show_sort_weight":102,"slug":103},6,50,"technology",{"id":105,"doc_module":4,"doc_module_name":25,"category_name":106,"show_sort_weight":107,"slug":108},7,"Healthcare",40,"healthcare",{"id":110,"doc_module":4,"doc_module_name":25,"category_name":111,"show_sort_weight":112,"slug":113},8,"Research & Report",30,"research-report",{"id":115,"doc_module":4,"doc_module_name":25,"category_name":116,"show_sort_weight":117,"slug":118},9,"Religion & Spirituality",20,"religion-spirituality",{"id":117,"doc_module":4,"doc_module_name":25,"category_name":120,"show_sort_weight":117,"slug":121},"World Cup","world-cup",{"id":123,"doc_module":4,"doc_module_name":25,"category_name":124,"show_sort_weight":123,"slug":125},10,"Lifestyle","lifestyle",{"id":127,"doc_module":4,"doc_module_name":25,"category_name":128,"show_sort_weight":96,"slug":129},19,"General","general",{"code":4,"msg":81,"data":131},{"doc_id":78,"user_id":132,"nickname":42,"user_avatar":133,"doc_module":4,"category_id":101,"category_name":29,"doc_title":10,"doc_description":12,"doc_content":134,"file_id":135,"file_url":136,"file_type":137,"file_size":138,"view_count":33,"is_deleted":4,"is_public":22,"is_downloadable":22,"audit_status":22,"page_count":139,"language":140,"language_code":8,"site_id":7,"html_lang":8,"table_of_contents":141,"faqs":142,"seo_title":143,"seo_description":12,"update_tm":144,"read_time":145},2336477405376,"https://ap-avatar.wpscdn.com/davatar_29158cc5080c5b710cf443261637dec0","Package ‘ggalluvial’  \nMay 8, 2026  \nType Package  \nTitle Alluvial Plots in 'ggplot2'Version 0.12.6  \nMaintainer Jason Cory Brunson \u003C[cornelioid@gmail.com](cornelioid@gmail.com)>  \nDescription Alluvial plots use variable-width ribbons and stacked bar plots to represent multi-dimensional or repeated-measures data with categorical or ordinal variables; see Riehmann, Hanfler, and Froehlich (2005)  \n\u003Cdoi:10.1109/INFVIS.2005.1532152> and Rosvall and Bergstrom (2010)\u003Cdoi:10.1371/journal.pone.0008694> .  \nAlluvial plots are statistical graphics in the sense of Wilkinson (2006)\u003Cdoi:10.1007/0-387-28695-0>; they share elements with Sankey diagrams and parallel sets plots but are uniquely determined from the data and a small set of parameters. This package extends Wickham's (2010)  \n\u003Cdoi:10.1198/jcgs.2009.07098> layered grammar of graphics to generate alluvial plots from tidy data.  \nDepends R (>= 3.6), ggplot2 (>= 2.2)  \nImports stats, dplyr (>= 0.7), tidyr (>= 0.7), lazyeval, rlang, tidyselect  \nSuggests grid, alluvial, testthat, knitr, rmarkdown, babynames, sessioninfo, ggrepel, shiny (>= [1.4.0.2](1.4.0.2)), htmltools, sp (>= 1.4-0), ggfittext (>= 0.6), vdiffr (>= 0.2)  \nLicense GPL-3 LazyData true  \nURL [http://corybrunson.github.io/ggalluvial/](http://corybrunson.github.io/ggalluvial/)  \nBugReports [https://github.com/corybrunson/ggalluvial/issues](https://github.com/corybrunson/ggalluvial/issues)  \nVignetteBuilder knitr RoxygenNote 7.2.3 Encoding UTF-8 NeedsCompilation no  \nAuthor Jason Cory Brunson [aut, cre],  \nQuentin D. Read [aut]  \n2 alluvial-data  \nRepository CRAN  \nDate/Publication 2026-02-22 12:30:02 UTC  \nContents  \nalluvial-data ......................................... 2  \ngeom_alluvium ....................................... 5  \ngeom_flow ......................................... 10  \ngeom_lode .......................................... 15  \ngeom_stratum ........................................ 17  \nlode-guidance-functions .................................. 19  \nmajors ............................................ 21  \nself-adjoin .......................................... 21  \nstat_alluvium ........................................ 22  \nstat_flow ........................................... 28  \nstat_stratum ......................................... 33  \nvaccinations ......................................... 38  \nIndex 40  \n\n| alluvial-data | Check for alluvial structure and convert between alluvial formats |\n| --- | --- |\n\nDescription  \nAlluvial plots consist of multiple horizontally-distributed columns (axes) representing factor variables, vertical divisions (strata) of these axes representing these variables’ values; and splines (alluvial flows) connecting vertical subdivisions (lodes) within strata of adjacent axes representing subsets or amounts of observations that take the corresponding values of the corresponding variables. This function checks a data frame for either of two types of alluvial structure:  \nUsage  \nis_lodes_form(  \ndata,  \nkey,  \nvalue,  \nid,  \nweight = NULL,  \nsite = NULL,  \nlogical = TRUE,  \nsilent = FALSE)  \nis_alluvia_form(  \ndata,  \n. . . ,  \nalluvial-data 3  \naxes = NULL,  \nweight = NULL,  \nlogical = TRUE,  \nsilent = FALSE)  \nto_lodes_form(  \ndata,  \n. . . ,  \naxes = NULL,  \nkey = \"x\",  \nvalue = \"stratum\",  \nid = \"alluvium\",  \ndiffuse = FALSE,  \ndiscern = FALSE)  \nto_alluvia_form(data, key, value, id, distill = FALSE)  \nArguments  \ndata A data frame.  \nkey, value, id In to_lodes_form, handled as in tidyr::gather() and used to name the new axis (key), stratum (value), and alluvium (identifying) variables. In to_alluvia_form, handled as in tidyr::spread() and used to identify the fields of data to be used as the axis (key), stratum (value), and alluvium (identifying) variables.  \nweight Optional field of data, handled using rlang::enquo(), to be used as heights or  \ndepths of the alluvia or lodes.  \nsite Optional vector of fields of data, handled using rlang::enquos(), to be used  \nto group row","cbCaifY7xML0YLsg","https://ap.wps.com/l/cbCaifY7xML0YLsg","pdf",233675,41,"English","# Overview\n## Alluvial plots concept\n## Relationship to Sankey and parallel sets\n## Layered grammar for ggplot2\n# Data structure utilities\n## alluvial-data overview\n## is_lodes_form\n## is_alluvia_form\n## to_lodes_form\n## to_alluvia_form","[{\"question\":\"What kind of data can ggalluvial visualize with alluvial plots?\",\"answer\":\"ggalluvial targets multi-dimensional or repeated-measures categorical/ordinal data, where relationships can be represented with flows between axis values. It supports tidy-data workflows for building these graphics.\"},{\"question\":\"How does ggalluvial generate alluvial plots within ggplot2?\",\"answer\":\"The package extends ggplot2’s layered grammar of graphics so alluvial plots are constructed from tidy data. The resulting plots are determined by the input data and a small set of parameters.\"},{\"question\":\"What is the purpose of alluvial-data utilities like is_lodes_form and to_lodes_form?\",\"answer\":\"These utilities check whether a data frame has lodes or alluvia structure and convert between formats. They identify axis, stratum/value, and alluvium/id variables and can optionally use weight and site fields.\"}]","Alluvial Plots in 'ggplot2' - Alluvial Plots in ggplot2 - package ggalluvial | PDF",1792975842,103]