<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=us-ascii">
<META NAME="Generator" CONTENT="MS Exchange Server version 6.5.7654.12">
<TITLE>Cross correlation using xcorr in ft_connectivityanalysis</TITLE>
</HEAD>
<BODY>
<!-- Converted from text/rtf format -->
<P><FONT SIZE=2 FACE="Courier New">Hi, </FONT>
</P>
<P><FONT SIZE=2 FACE="Courier New">I am a new user of Field Trip, and my Matlab knowledge is ok, but restricted. I am trying to calculate the cross correlation of two EMG signals, using ft_connectivity analysis, with </FONT><FONT COLOR="#000000" SIZE=2 FACE="Courier New">cfg.method =</FONT> <FONT COLOR="#A020F0" SIZE=2 FACE="Courier New">'xcorr'</FONT><FONT COLOR="#000000" SIZE=2 FACE="Courier New">; Unfortunately I receive this error:</FONT></P>
<P><FONT COLOR="#000000" SIZE=2 FACE="Courier New">??? Undefined function or variable "inparam".</FONT>
</P>
<P><FONT COLOR="#000000" SIZE=2 FACE="Courier New">Error in ==> ft_connectivityanalysis at 196</FONT>
<BR><FONT COLOR="#000000" SIZE=2 FACE="Courier New">if any(~isfield(data, inparam)) || (isfield(data, 'crsspctrm') && (ischar(inparam) && strcmp(inparam,</FONT>
<BR><FONT COLOR="#000000" SIZE=2 FACE="Courier New">'crsspctrm'))),</FONT>
</P>
<P><FONT COLOR="#000000" SIZE=2 FACE="Courier New">Indeed when looking in the ft_connectivityanalysis.m, inparam is not specified for xcorr and corr:</FONT>
</P>
<P><FONT COLOR="#0000FF" SIZE=2 FACE="Courier New">case</FONT><FONT COLOR="#000000" SIZE=2 FACE="Courier New"> {</FONT><FONT COLOR="#A020F0" SIZE=2 FACE="Courier New">'corr'</FONT><FONT COLOR="#000000" SIZE=2 FACE="Courier New"></FONT> <FONT COLOR="#A020F0" SIZE=2 FACE="Courier New">'xcorr'</FONT><FONT COLOR="#000000" SIZE=2 FACE="Courier New">}</FONT>
<BR><FONT COLOR="#000000" SIZE=2 FACE="Courier New"> data = ft_checkdata(data,</FONT> <FONT COLOR="#A020F0" SIZE=2 FACE="Courier New">'datatype'</FONT><FONT COLOR="#000000" SIZE=2 FACE="Courier New">,</FONT> <FONT COLOR="#A020F0" SIZE=2 FACE="Courier New">'raw'</FONT><FONT COLOR="#000000" SIZE=2 FACE="Courier New">);</FONT>
</P>
<P><FONT SIZE=2 FACE="Courier New">Could anybody help with this problem?</FONT>
</P>
<P><FONT SIZE=2 FACE="Courier New">Thanks in advance,</FONT>
</P>
<P><FONT SIZE=2 FACE="Courier New">Stan Verwer</FONT>
<BR><FONT SIZE=2 FACE="Courier New">University of Twente</FONT>
</P>
</BODY>
</HTML>