Description Usage Arguments Details Author(s) References Examples
Plot the predicted probability of each state in a sequence
1 2 3 4 |
object |
a probabilistic suffix tree, i.e., an object of class |
data |
a sequence object, i.e., an object of class |
cdata |
Not implemented yet. |
L |
integer. Maximal context length for sequence prediction. This is the same as pruning the PST by removing all nodes of depth<L before prediction. |
stcol |
character. Color to use to plot the prediction qualities. |
plotseq |
logical. If TRUE, the sequence is displayed separately, and the prediction plot is plotted above. |
ptype |
character. Type of plot, either |
cex.plot |
numeric. Expansion factor for setting the size of the font for the axis labels and names. The default value is 1. Values lesser than 1 will reduce the size of the font, values greater than 1 will increase the size. |
space |
numeric. Space separating each state in the plot. |
measure |
character. Measure used for prediction quality. Either |
pqmax |
numeric. Maximum coordinate for the prediction quality plot, i.e. the max of the y axis. |
seqscale |
numeric. If |
... |
optional graphical parameters to be passed to the plot function. |
The pqplot()
function displays either the predicted probabilities or the log-loss for each position of a single sequence as a series of barplots. For more details, see Gabadinho 2016.
Alexis Gabadinho
Gabadinho, A. & Ritschard, G. (2016) Analyzing State Sequences with Probabilistic Suffix Trees: The PST R Package. Journal of Statistical Software, 72(3), 1-39.
1 2 3 4 5 6 7 |
Loading required package: TraMineR
TraMineR stable version 2.0-7 (Built: "Sat,)
Website: http://traminer.unige.ch
Please type 'citation("TraMineR")' for citation information.
Loading required package: RColorBrewer
PST version 0.94 (Built: 2017-09-22)
Website: http://r-forge.r-project.org/projects/pst
[>] 2 distinct states appear in the data:
1 = a
2 = b
[>] state coding:
[alphabet] [label] [long label]
1 a a a
2 b b b
[>] 1 sequences in the data set
[>] min/max sequence length: 27/27
[>] 1 sequence(s) - min/max length: 27/27
[>] max. depth L=3, nmin=1
[L] [nodes]
0 1
1 2
2 4
3 8
[>] computing sequence(s) likelihood ... (0.01 secs)
[>] total time: 0.285 secs
[>] 2 distinct states appear in the data:
1 = a
2 = b
[>] state coding:
[alphabet] [label] [long label]
1 a a a
2 b b b
[>] 1 sequences in the data set
[>] min/max sequence length: 5/5
[>] computing prob., max. length=3
[>] computing prob., max. length=3
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.