% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/fitGradient.R
\name{fitGradient}
\alias{fitGradient}
\title{Test for presence of gradient in a hyperframe of point patterns}
\usage{
fitGradient(
  hypFrame,
  fixedForm,
  randomForm,
  fixedFormSimple,
  returnModel = FALSE,
  silent,
  ...
)
}
\arguments{
\item{hypFrame}{the hyperframe}

\item{fixedForm, randomForm, fixedFormSimple}{Formulae for fixed effects,
random effects and fixed effects without slopes respectively}

\item{returnModel}{A boolean, should the entire model be returned?
Otherwise the p-value and coefficient vector are returned}

\item{silent}{A boolean, should error messages from spatstat.model::mppm be printed?}

\item{...}{passed onto spatstat.model::mppm}
}
\value{
A list contraining
\item{pVal}{The p-value for existence of gradients}
\item{coef}{The model coefficients}
or a mppm model when returnModel is true
}
\description{
A Poisson process is fitted to the data assuming exponential relationship wit intensity of
the interaction between x and y variables and image identifier. This is
compared to a model without this interaction to test for the significance of the gradient.
}
\seealso{
\link{estGradients}
}
