Description Usage Arguments Value Note References See Also Examples

Extract population size simulation results (mean, sd, min and max), including expected minimum abundance (EMA) and its standard deviation, from a RAMAS Metapop .mp file.

1 | ```
results(mp)
``` |

`mp` |
A character string containing the path to a RAMAS Metapop .mp file containing simulation results. Metapop .mp files are plain text files that store settings describing RAMAS metapopulation models, and the results of simulating population dynamics according to those models. |

A `list`

containing:

`version` |
The version of RAMAS Metapop
from which the file indicated by |

`results` |
An array containing simulation results
extracted from |

`iter_min` |
A sorted vector of minimum abundance, across time steps, for each iteration. |

`iter_max` |
A sorted vector of maximum abundance, across time steps, for each iteration. |

`iter_terminal` |
A sorted vector of terminal abundance for each iteration. |

`qe_thr` |
The quasi-extinction threshold. When the total
abundance is beneath |

`qe_prob` |
The probability and cumulative probability
of exceeding the quasi-extinction threshold ( |

`EMA` |
The mean minimum abundance (i.e. the mean, across iterations, of the minimum abundance for each simulation trajectory). |

`SDMA` |
The standard deviation of minimum abundance (i.e. the sd, across iterations, of the minimum abundance for each simulation trajectory). |

`timestamp` |
A POSIXlt object representing the date and time at which the simulation was completed. |

`n_pops` |
The number of populations in the simulation. |

`duration` |
The number of time steps in the simulation |

`n_iters` |
The number of iterations performed. |

`mptools`

has been tested with outputs generated by RAMAS Metapop
version 5, and may produce unexpected results for other versions. A warning
is issued if the user attempts to access files originating from other
versions of RAMAS Metapop.

Akcakaya, H. R., Burgman, M. A., Kindvall, O., Wood, C. C., Sjogren-Gulve, P., Hatfield, J. S., & McCarthy, M. A. (2004).

*Species Conservation and Management: Case Studies*. New York: Oxford University Press.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 | ```
mp <- system.file('example.mp', package='mptools')
res <- results(mp)
str(res)
# look at the simulation results for the first array slice (NB: this slice is
# all pops combined):
res$results[,, 1]
# equivalently, subset by name:
res$results[,, 'ALL']
res$results[,, 'Pop 190']
res$results[,, '240A24']
dimnames(res$results)[[3]] # population names
# return a matrix of mean population sizes, where columns represent
# populations and rows are time steps:
res$results[, 1, ] # or res$results[, 'mean', ]
# sd across iterations:
res$results[, 2, ] # or res$results[, 'sd', ]
# min pop sizes across iterations:
res$results[, 3, ] # or res$results[, 'min', ]
# max pop sizes across iterations:
res$results[, 4, ] # or res$results[, 'max', ]
``` |

mptools documentation built on May 29, 2017, 8:43 p.m.

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.