% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/environment-confounds-and-ipfm.R
\name{correct_gazepoint_eda_temperature}
\alias{correct_gazepoint_eda_temperature}
\title{Correct EDA for ambient or body temperature}
\usage{
correct_gazepoint_eda_temperature(
  dat,
  eda_col = "GSR_US",
  temperature_cols,
  group_cols = NULL,
  time_col = NULL,
  output_col = "eda_temperature_adjusted",
  fitted_col = "eda_temperature_fitted",
  model_by_group = TRUE,
  add_intercept_mean = TRUE
)
}
\arguments{
\item{dat}{A data frame.}

\item{eda_col}{Numeric EDA/conductance column.}

\item{temperature_cols}{One or more numeric temperature columns.}

\item{group_cols}{Optional grouping columns.}

\item{time_col}{Optional time column retained in summaries.}

\item{output_col}{Output residual-adjusted EDA column.}

\item{fitted_col}{Output fitted temperature component column.}

\item{model_by_group}{Logical. If \code{TRUE}, fit one model per group.}

\item{add_intercept_mean}{Logical. If \code{TRUE}, add the group mean EDA back to
residuals so the adjusted signal remains on the original scale.}
}
\value{
A data frame with adjusted EDA columns and model-summary attributes.
}
\description{
Regresses an EDA/conductance signal on one or more continuous temperature
covariates and returns a temperature-adjusted residual series. The adjusted
signal is temperature-adjusted EDA, not "pure" cognitive or emotional EDA.
}
