or_fun: P(A | B) = P(A) + P(B)

Description Usage Arguments Examples

View source: R/probability.R

Description

Using an object from the cRacle::dens_obj() function. Create a single density object (i.e., like that produced by cRacle::densform()) where the probability curves correspond to the probability density function of any one taxon/species from the original set occurring. This is not actually used in the implementation of finding the maximum joint likelihood in a CRACLE analysis, but is a good companion to the cRacle::and_fun() function.

Usage

1
or_fun(dens.oblist)

Arguments

dens.oblist

An object derived from the cRacle::dens_ob() function.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
## Not run: 
#distr <- read.table('test_mat.txt', head=T, sep ="\t");
#OR:
data(distr);
data(climondbioclim);
extr.raw = extraction(data=distr, clim= climondbioclim, schema='raw');
dens.list.raw <- dens_obj(extr.raw, clim = climondbioclim, bw = 'nrd0', n = 1024);
multiplot(dens.list.raw, names(climondbioclim[[1]]));
or <- or_fun(dens.list.raw);
addplot(or, names(climondbioclim[[1]]), col ='black');

## End(Not run)

rsh249/cRacle documentation built on Feb. 2, 2022, 2:01 p.m.