Awesome
<!-- README.md is generated from README.Rmd. Please edit that file -->ggseqplot: ggplotify sequence data plots <img src="man/figures/logo.png" align="right" height="139"/>
<!-- badges: start --> <!-- badges: end -->The main goal of {ggseqplot}
is to provide functions that reproduce the sequence plots from
<a href="http://traminer.unige.ch"
target="_blank"><code>{TraMineR}</code></a>’s seqplot
using
<a href="https://ggplot2.tidyverse.org/"
target="_blank"><code>{ggplot2}</code></a>. These plots are produced on
the basis of state sequence objects defined with TraMineR::seqdef
. The
package automates the reshaping and plotting of sequence data. This
library literally builds on the excellent work of the
<a href="http://traminer.unige.ch"
target="_blank"><code>{TraMineR}</code></a> and
<a href="https://ggplot2.tidyverse.org/"
target="_blank"><code>{ggplot2}</code></a> developers and uses several
of the their functions to produce ggplot2-flavored figures.
Note, that this library was not written because I personally dislike the
plots produced by <a href="http://traminer.unige.ch"
target="_blank"><code>{TraMineR}</code></a>, but rather because I am
normally using <a href="https://ggplot2.tidyverse.org/"
target="_blank"><code>{ggplot2}</code></a> instead of base R’s plot
environment for visualizing data. <a href="http://traminer.unige.ch"
target="_blank"><code>{TraMineR}</code></a> was developed before
<a href="https://ggplot2.tidyverse.org/"
target="_blank"><code>{ggplot2}</code></a> was as popular as it is today
and back then many users were more familiar with coding base R plots. To
date, however, many researchers and students are more accustomed to
using <a href="https://ggplot2.tidyverse.org/"
target="_blank"><code>{ggplot2}</code></a> and prefer to draw on the
related skills and experiences instead of learning how to refine base R
plots just for the single purpose of visualizing sequence data.
{ggseqplot}
contains the
following functions:
ggseqdplot
(equivalent toTraMineR::seqdplot
)ggseqeplot
(equivalent toTraMineRextras::seqplot.tentrop
)ggseqmsplot
(equivalent toTraMineR::seqmsplot
)ggseqmtplot
(equivalent toTraMineR::seqmtplot
)ggstrqeplot
(based on transitions rates computed withTraMineR::seqtrate
)ggseqiplot
(equivalent toTraMineR::seqIplot
)ggseqfplot
(equivalent toTraMineR::seqfplot
)ggseqrplot
(equivalent toTraMineR::seqrplot
)ggseqrfplot
(equivalent toTraMineRextras::seqplot.rf
)
If you have change requests or find errors, create an issue on github or send me an email.
A complementing
vignette
outlines how {ggseqplot}
reshapes sequence data generated with <a href="http://traminer.unige.ch"
target="_blank"><code>{TraMineR}</code></a> functions to visualize them
using <a href="https://ggplot2.tidyverse.org/"
target="_blank"><code>{ggplot2}</code></a>. Moreover, it illustrates how
to adjust the baseline output using familiar
<a href="https://ggplot2.tidyverse.org/"
target="_blank"><code>{ggplot2}</code></a> functions (and add-ons).
Installation
You can install the CRAN version of
{ggseqplot}
by typing:
install.packages("ggseqplot")
The development version can be installed with:
devtools::install_github("maraab23/ggseqplot")
Acknowledgements
I would like to thank Gilbert Ritschard, Tim Liao, and Emanuela Struffolino for their comments on earlier versions of this library.