Description Usage Arguments Details Value Author(s) References See Also Examples
Plots results of postcp, plots observed data (if included in postcp output) and posterior probabilities.
1 2 3 4 5 |
x |
Results of postCP, use as input for plot.postcp. |
y |
y coordinates for the default plot function. Defaults to NULL |
xlab |
Label for x-axis (see par). |
ylab |
Label for y-axis (see par). |
main |
Main title of plot (see par). |
p.col |
Colour of scatterplot of data (see par). |
pch |
Type of character of scatterplot (see par). |
p.cex |
cex parameter of scatterplot (see par). |
m.col |
Graphical option for colour of mean line (see par). |
m.lty |
Graphical option for type of mean line (see par). |
m.lwd |
Graphical option for width of mean line (see par). |
l.col |
Graphical option for colours of posterior probability lines, of length 1 for same colour for all lines or 1 for each line (see par). |
l.lty |
Graphical option for types of posterior probability lines, of length 1 for same colour for all lines or 1 for each line (see par). |
l.lwd |
Graphical option for widths of posterior probability lines, of length 1 for same colour for all lines or 1 for each line (see par). |
... |
Additional arguments. |
Package: | postCP |
Type: | Package |
Version: | 1.8.0 |
Date: | 2016-09-07 |
License: | GPL (>= 2) |
LazyLoad: | yes |
out |
List with limits of x and y-axis. May be useful for labelling. |
Gregory Nuel, The Minh Luong and Malith Jayaweera
Maintainer: Who to complain to malithgsoc2016@gmail.com
Luong, T.M., Rozenholc, Y. & Nuel, G. (2012). Fast estimation of posterior probabilities in change-point models through a constrained hidden Markov model. http://arxiv.org/pdf/1203.4394
1 2 3 4 5 6 7 8 9 10 11 12 | require(postCP)
#prepare data
sigma=1.3
#Change point estimates
bp=c(7,10)
#Obtain data from longley dataset
data = longley
#Apply postcp function
res = postcp(Employed ~ GNP + Armed.Forces,family=gaussian(),data=data,bp=c(7,10),sigma)
#Plot the results
plot.postcp(res,main="Posterior Change Point Probability Distribution")
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.