ch.moralsRmLearningEffect: A function to remove a learning function from data

ch.moralsRmLearningEffectR Documentation

A function to remove a learning function from data

Description

This function attempts to fit a non-linear, decellerating function to the specifed data. Then it adds two columns to the dataframe: a column with the predicted datapoints based on the nls fit and a column with the residuals around that fit. The function also returns the nls fit object

Usage

ch.moralsRmLearningEffect(data, x, y, fitCol, resCol, ...)

Arguments

data

the dataframe containing the data..

x

a string the specifies the column name in "data" that contains the x variable.

y

a string the specifies the column name in "data" that contains the y variable.

fitCol

a string that specifies the name of the new column that will contain the predicted datapoints.

resCol

a string that specifies the name of the new column that will contain the residual datapoints.

Value

a list containing: data = original datafram with the new columns; nlsFit = the nls fit object.

Examples

ch.moralsRmLearningEffect (data=moralsData,"trial", "RT", "fitRT", "resRT")

ccpluncw/ccpl_R_chMorals documentation built on Feb. 4, 2024, 3:30 p.m.