Learn R Programming

LAD (version 0.1.0)

calcLAD: Calculate summary statistics from measured leaf inclination angles

Description

The function derives summary statistics from measured leaf inclination angles:.

  • Mean (MTA), standard deviation (SD) and frequency (NR) observations.

  • The two (mu, nu) Beta parameters derived from the formula provided by Goel and Strebel (1984) tools:::Rd_expr_doi("10.2134/agronj1984.00021962007600050021x").

  • The distribution type, comparing the distribution against the six theoretical LAD distributions provided by de Wit (1965).

Value

A dataframe with the grouping variable(s), and:

  • summary statistics (MTA, SD, N, mu, nu, distribution) in case of type="summary";

  • LAD (pdf) and G-function (G) in case of type="extended".

Arguments

data

Dataframe. The dataframe containing leaf inclination angle measurements.

angles

Numeric. The column containing leaf inclination angle measurements (in degrees).

type

Character. If set to "summary", it gives summary distributions. If set to "extended", it calculates LAD probability density (pdf) and G-function (G) for view or inclination angles (theta). Default set to "summary".

...

The column(s) indicating the grouping variables to be considered for calculating summary statistics.

Examples

Run this code
head(Chianucci)
# \donttest{
calcLAD(Chianucci,Angle_degree,type='summary',Genus,Species)
calcLAD(Chianucci,Angle_degree,type='extended',Genus,Species)
# }

Run the code above in your browser using DataLab