Learn R Programming

coexist (version 1.0)

make.parcomb: make the parameter combination index matrix

Description

make the parameter combination index matrix, this matrix is the index matrix that can be used in the read.data() function or batch.read() functions to

Usage

make.parcomb(prange, parnum, path = NULL)

Arguments

prange
sampling points' vector for the parameter space interval[0~1], for example c(0.1,.3,.6,.9)
parnum
number of parameters in the model
path
local filen/path to save the parameter combination matrix

References

Chen YH (2012) coexist: an R package for performing species coexistence modeling and analysis under asymmetric dispersal and fluctuating source-sink dynamics. http://code.google.com/p/coexist.

See Also

read.data, batch.read, read.patchdata

Examples

Run this code
##---- Should be DIRECTLY executable !! ----
##-- ==>  Define data, use random,
##--	or do  help(data=index)  for the standard data sets.

## The function is currently defined as
function (prange, parnum, path = NULL) 
{
    if (!is.list(prange)) {
        parcomb <- comblist(prange, parnum)
    }
    if (is.list(prange)) {
        parcomb <- comblist2(prange)
    }
    if (length(path) != 0) {
        path = filename.check(path)
        write.table(parcomb, path, sep = "\t")
    }
    return(parcomb)
  }

Run the code above in your browser using DataLab