loess_smoothing_KDE {ontophylo}R Documentation

Get loess smoothing for the unnormalized Markov KDE

Description

Calculates loess smoothing for the unnormalized Markov KDE obtained from the 'estimate_edge_KDE_Markov_kernel_unnorm' function.

Usage

loess_smoothing_KDE(tree.discr, Edge.KDE)

Arguments

tree.discr

simmap or phylo object. A discretized tree using the 'discr_Simmap' function.

Edge.KDE

list. A list with the estimated unnormalized KDEs ($Maps.mean) for each edge.

Value

A list with the loess smoothing calculated for each edge.

Author(s)

Sergei Tarasov

Examples

data("hym_kde", "hym_tree")
# Get reference tree.
tree_discr <- discr_Simmap(hym_tree, res = 200)
# Get non-normalized and normalized edge KDE data.
Edge_KDE <- hym_kde$head
# Calculate smoothing of edge KDE data.
Edge_KDE$Maps.mean.loess <- suppressWarnings(loess_smoothing_KDE(tree_discr, Edge_KDE))
# Check smoothing of KDE data for normalized mean rates from an arbitrary branch.
Edge_KDE$Maps.mean.loess.norm[[5]]
# Check smoothing of KDE data for non-normalized mean rates from an arbitrary branch.
Edge_KDE$Maps.mean.loess[[5]]


[Package ontophylo version 1.1.3 Index]