% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/tools.R
\name{convert_shifts2regions}
\alias{convert_shifts2regions}
\title{Converts shift values to optimum values on the edges.}
\usage{
convert_shifts2regions(tree, shift.configuration, shift.values)
}
\arguments{
\item{tree}{ultrametric tree of class phylo with branch lengths.}

\item{shift.configuration}{vector of edge indices with shifts.}

\item{shift.values}{vector of shift values.}
}
\value{
vector of size number of edges with optimum value of the trait on the corresponding edge.
}
\description{
Converts a model indicated with shift values to a model with optimum values on the edges.
}
\examples{

data(lizard.tree, lizard.traits)

sc <- c(55, 98, 118, 74, 14, 77,  32, 164)
sv <- c(2 ,  3,   4,  4,  1,  2, 0.5,   1)

root.value <- -2

optimum.values <- convert_shifts2regions(lizard.tree, sc, sv) + root.value


}

