mig.trajectories.plot {bayesMig} | R Documentation |

The functions plot/tabulate the posterior distribution of trajectories of net migration rates for a given location, or for all locations, including their median and given probability intervals.

```
mig.trajectories.plot(
mig.pred,
country,
pi = c(80, 95),
nr.traj = 50,
mark.estimation.points = FALSE,
xlim = NULL,
ylim = NULL,
type = "b",
xlab = "Year",
ylab = "Migration rate",
main = NULL,
lwd = c(2, 2, 2, 2, 1),
col = c("black", "green", "red", "red", "#00000020"),
show.legend = TRUE,
add = FALSE,
scale = FALSE,
...
)
mig.trajectories.plot.all(
mig.pred,
output.dir = NULL,
output.type = "png",
verbose = FALSE,
...
)
mig.trajectories.table(mig.pred, country, pi = c(80, 95), ...)
```

`mig.pred` |
Prediction object of class |

`country` |
Name or numerical code of a location. If it is a country, it can also be given as ISO-2 or ISO-3 characters. |

`pi` |
Probability interval (as percentage) to be included in the output. It can be a single number or a vector. |

`nr.traj` |
Number of trajectories to be plotted. If |

`mark.estimation.points` |
Logical. If |

`xlim` , `ylim` , `type` , `xlab` , `ylab` |
Graphical parameters passed to the |

`main` |
Main title for the plot(s). In |

`lwd` , `col` |
Vector of five elements giving the line width and color for: 1. observed data, 2. imputed values, 3. median, 4. quantiles, 5. trajectories. |

`show.legend` |
Logical controlling whether a legend should be drawn. |

`add` |
Logical controlling whether the trajectories should be plotted into a new graphic
device ( |

`scale` |
Logical. If |

`...` |
Additional graphical parameters. In addition, for |

`output.dir` |
Directory into which resulting plots are written. By default, the plots are saved into directory sim.dir/predictions/migTrajectories. |

`output.type` |
Type of the resulting plot files. Can be "png", "pdf", "jpeg", "bmp", "tiff", or "postscript". |

`verbose` |
Logical value. Switches log messages on and off. |

`mig.trajectories.plot`

plots posterior distribution of trajectories of net migration
rates for a given location. `mig.trajectories.table`

gives the same output as a table.
`mig.trajectories.plot.all`

creates a set of graphs (one per location) that are stored in
`output.dir`

.

The median and given probability intervals are computed using all available trajectories.
Thus, `nr.traj`

does not influence those values - it is used only to control the number
of trajectories in the graphs.

No return value.

`mig.predict`

, `summary.bayesMig.prediction`

```
# See example in ?mig.predict
```

[Package *bayesMig* version 0.4-6 Index]