normalize: Creates a dataframe of probabilities from abundances data set

Description Usage Arguments Details Value Author(s) See Also Examples

View source: R/normalize.R

Description

Creates a dataframe of probabilities from abundances data set by dividing each datapoint by the sum of observations

Usage

1
normalize(data, Interpolate = FALSE, CheckData = TRUE)

Arguments

data

data.frame; abundance data, with one column of date objects and one with numeric values.

Interpolate

logical; will be passed to CheckData function

CheckData

logical; if TRUE CheckData function will check format of input data.frame

Details

Takes abundance data as dataframes as input. Will cause an exception if there is not at least one datapoint for each full-day in the range of time given by the maximum and minimum value in the dates column of the input dataframe.

Value

returns a list with the levels: $data = dataframe which has the same dates as the input dataframe in one column but has probabilitis instead of observations. those are created by dividing the number of observations for each date through the sum of all observations in the datasets. $estimationmethod = 'normalization', $startpoint = minimum of dates column in input dataframe, $endpoint = maximum of dates column in input dataframe.

Author(s)

Florian Berger <florian_berger@ymail.com>

See Also

scale

Examples

1
2
3
4
5
a     <- c(1:10)
dates <- as.Date(a, origin = '2017-01-01')
count <- c(1,1,3,4,6,9,5,4,2,1)
dat   <- data.frame(dates, count)
normalize(dat)

biometry/phenologicalOverlap documentation built on May 21, 2019, 2:31 a.m.